From 9ed845958afd4d4cb78a67e385d4e9c9ff138a2a Mon Sep 17 00:00:00 2001 From: Robert Jackson Date: Thu, 29 May 2025 20:00:37 -0400 Subject: [PATCH 1/2] feat!: Add code sample transformer for Python code samples This adds code sample transformer functionality (in general), and specifically adds the ability to transform python code samples from the `glean` namespace to the `glean.api_client` namespace. --- .github/workflows/generate-code-samples.yml | 7 +- .prettierignore | 1 + README.md | 19 +- package.json | 3 +- src/code-sample-transformer.js | 85 +++ src/index.js | 91 ++- tests/code-sample-transformer.test.js | 135 +++++ tests/fixtures/example-with-code-samples.yaml | 568 ++++++++++++++++++ 8 files changed, 886 insertions(+), 23 deletions(-) create mode 100644 src/code-sample-transformer.js create mode 100644 tests/code-sample-transformer.test.js create mode 100644 tests/fixtures/example-with-code-samples.yaml diff --git a/.github/workflows/generate-code-samples.yml b/.github/workflows/generate-code-samples.yml index 9650279..3cbdc7e 100644 --- a/.github/workflows/generate-code-samples.yml +++ b/.github/workflows/generate-code-samples.yml @@ -38,9 +38,12 @@ jobs: SPEAKEASY_API_KEY: ${{ secrets.SPEAKEASY_API_KEY }} - name: Running code sample transformers + run: pnpm transform:merged_code_samples_specs + + - name: Copy specs into final_specs run: | - cp -r ./merged_code_samples_specs/glean-client-merged-code-samples-spec.yaml ./final_specs/client_rest.yaml - cp -r ./merged_code_samples_specs/glean-index-merged-code-samples-spec.yaml ./final_specs/indexing.yaml + cp -r ./modified_code_samples_specs/client_rest.yaml ./final_specs/client_rest.yaml + cp -r ./modified_code_samples_specs/indexing.yaml ./final_specs/indexing.yaml - name: Commit changes uses: ./.github/actions/git-commit diff --git a/.prettierignore b/.prettierignore index c291e72..fb858ef 100644 --- a/.prettierignore +++ b/.prettierignore @@ -9,6 +9,7 @@ pnpm-lock.yaml /generated_specs/ /overlayed_specs/ /merged_code_samples_specs/ +/modified_code_samples_specs/ /final_specs/ # Speakeasy managed files diff --git a/README.md b/README.md index 4d31759..11bcf65 100644 --- a/README.md +++ b/README.md @@ -6,13 +6,14 @@ Preprocesses our OpenAPI specs to prepare them for generation via Speakeasy (our This repository manages several types of OpenAPI specifications in different directories: -| Directory | Purpose | -| ---------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `source_specs/` | Original OpenAPI specification files provided as input to the transformation process. These are the source of truth for our API definitions. | -| `generated_specs/` | Transformed OpenAPI specs with server URL subpaths moved to individual API paths. These files are consumed by Speakeasy to generate client libraries. | -| `overlayed_specs/` | Specs with various overlays applied (see Overlays section below). The overlays add additional metadata or modifications needed for specific purposes. | -| `merged_code_samples_specs/` | Specs with code samples merged from multiple sources. These enhanced specs provide examples for documentation and developer usage. | -| `final_specs/` | Final, fully proccessed OpenAPI specifications that combine code samples from multiple sources that have been post-processed for correctness. These files are consumed by the gh-pages site and ultimately make their way to developers.glean.com. | +| Directory | Purpose | +| ------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `source_specs/` | Original OpenAPI specification files provided as input to the transformation process. These are the source of truth for our API definitions. | +| `generated_specs/` | Transformed OpenAPI specs with server URL subpaths moved to individual API paths. These files are consumed by Speakeasy to generate client libraries. | +| `overlayed_specs/` | Specs with various overlays applied (see Overlays section below). The overlays add additional metadata or modifications needed for specific purposes. | +| `merged_code_samples_specs/` | Specs with code samples merged from multiple sources. These enhanced specs provide examples for documentation and developer usage. | +| `modified_code_samples_specs/` | Specs with code samples post processed (correcting issues with the generated code samples). | +| `final_specs/` | Final, fully proccessed OpenAPI specifications that combine code samples from multiple sources that have been post-processed for correctness. These files are consumed by the gh-pages site and ultimately make their way to developers.glean.com. | ## Overlays @@ -47,6 +48,10 @@ The `overlayed_specs` directory contains merged OpenAPI specifications that comb These merged specs are used for generating consistent client libraries across multiple APIs and provide a single source of documentation. +## Modified Code Samples Specs + +This takes the specs from `merged_code_samples_specs` and runs `pnpm transform:merged_code_samples_specs` to correct issues with the generated code samples. This is done in the `.github/workflows/generate-code-samples.yml` GHA workflow. + ## Final Specs The `final_specs` directory contains the end product of all of the processing being done. These specs are copied into the published GitHub Pages site (in the `docs/specs/final` directory), and then used by [gleanwork/glean-developer-site](https://github.com/gleanwork/glean-developer-site). diff --git a/package.json b/package.json index 6d0adaf..c321116 100644 --- a/package.json +++ b/package.json @@ -22,7 +22,8 @@ "test": "vitest run", "test:all": "pnpm test", "test:watch": "vitest", - "transform:source_specs": "node src/index.js --source_specs" + "transform:source_specs": "node src/index.js --source_specs", + "transform:merged_code_samples_specs": "node src/index.js --merged_code_samples_specs" }, "dependencies": { "js-yaml": "^4.1.0" diff --git a/src/code-sample-transformer.js b/src/code-sample-transformer.js new file mode 100644 index 0000000..4c72169 --- /dev/null +++ b/src/code-sample-transformer.js @@ -0,0 +1,85 @@ +import yaml from 'js-yaml'; + +/** + * Extracts code snippet for a specific language from pathSpec + * @param {Object} pathSpec The OpenAPI spec object for the specific path being processed + * @param {string} language The language to extract code snippets for + * @returns {string} The source code snippet for the specified language + */ +export function extractCodeSnippet(pathSpec, language) { + for (const [httpMethod, methodSpec] of Object.entries(pathSpec)) { + if (methodSpec && methodSpec['x-codeSamples']) { + const codeSamples = methodSpec['x-codeSamples']; + + const matchingSample = codeSamples.find( + (sample) => sample.lang === language, + ); + + return matchingSample; + } + } + + return undefined; +} + +/** + * Generator that iterates over all paths in an OpenAPI specification + * @param {Object} spec The OpenAPI specification object + * @yields {[string, Object]} A tuple containing the path key and path specification + */ +export function* path(spec) { + if (spec.paths) { + for (const [pathKey, pathSpec] of Object.entries(spec.paths)) { + yield [pathKey, pathSpec]; + } + } +} + +export function transformPythonCodeSamplesToPython(spec) { + for (const [apiPath, pathSpec] of path(spec)) { + let codeSample = extractCodeSnippet(pathSpec, 'python'); + if (!codeSample) { + continue; + } + + let codeSampleSource = codeSample.source; + + const transformations = [ + // from glean import X, Y, Z -> from glean.api_client import X, Y, Z + [ + /from glean(?!\.api_client) import\s+/g, + 'from glean.api_client import ', + ], + // from glean.something import ... -> from glean.api_client.something import ... + [/from glean\.(?!api_client)([^.\s]+)/g, 'from glean.api_client.$1'], + // import glean.something -> import glean.api_client.something + [/import glean\.(?!api_client)([^.\s]+)/g, 'import glean.api_client.$1'], + ]; + + for (const [pattern, replacement] of transformations) { + codeSampleSource = codeSampleSource.replace(pattern, replacement); + } + + codeSample.source = codeSampleSource; + } + + return spec; +} + +/** + * Transforms OpenAPI YAML by adjusting server URLs and paths + * @param {string} content The OpenAPI YAML content + * @param {string} filename The name of the file being processed + * @returns {string} Transformed YAML content + */ +export function transform(content, _filename) { + const spec = yaml.load(content); + + transformPythonCodeSamplesToPython(spec); + + return yaml.dump(spec, { + lineWidth: -1, // Preserve line breaks + noRefs: true, // Don't use anchors and aliases + quotingType: '"', // Use double quotes for strings + }); +} diff --git a/src/index.js b/src/index.js index c9adff0..6def3cb 100644 --- a/src/index.js +++ b/src/index.js @@ -1,13 +1,7 @@ import * as fs from 'fs'; import * as path from 'path'; -import { transform } from './source-spec-transformer.js'; - -// Source and output directories -const SOURCE_DIR = 'source_specs'; -const OUTPUT_DIR = 'generated_specs'; - -// Specification files -const SPEC_FILES = ['client_rest.yaml', 'indexing.yaml', 'admin_rest.yaml']; +import * as sourceSpecTransformer from './source-spec-transformer.js'; +import * as codeSamplesTransformer from './code-sample-transformer.js'; async function ensureDirectoryExists(directory) { if (!fs.existsSync(directory)) { @@ -25,19 +19,88 @@ export async function readYamlFromFile(filePath) { } } +function getYamlFiles(directory) { + try { + const files = fs.readdirSync(directory); + return files.filter( + (file) => file.endsWith('.yaml') || file.endsWith('.yml'), + ); + } catch (error) { + console.error(`Error reading directory ${directory}: ${error.message}`); + throw error; + } +} + export async function transformSourceSpecs() { + const sourceDir = 'source_specs'; + const outputDir = 'generated_specs'; + + try { + const specFiles = getYamlFiles(sourceDir); + + if (specFiles.length === 0) { + console.log(`No YAML files found in ${sourceDir}`); + return; + } + + await ensureDirectoryExists(outputDir); + + for (const specFile of specFiles) { + const sourceFilePath = path.join(sourceDir, specFile); + const outputFilePath = path.join(outputDir, specFile); + + console.log(`Processing ${sourceFilePath}`); + + const yamlContent = await readYamlFromFile(sourceFilePath); + + const transformedYaml = sourceSpecTransformer.transform( + yamlContent, + specFile, + ); + + fs.writeFileSync(outputFilePath, transformedYaml, 'utf8'); + + console.log(`Saved transformed YAML to ${outputFilePath}`); + } + + console.log('OpenAPI specs transformation completed'); + } catch (error) { + console.error(`Transformation failed: ${error.message}`); + process.exit(1); + } +} + +export async function transformMergedCodeSamplesSpecs() { + const sourceDir = 'merged_code_samples_specs'; + const outputDir = 'modified_code_samples_specs'; + try { - await ensureDirectoryExists(OUTPUT_DIR); + const specFiles = getYamlFiles(sourceDir); + + if (specFiles.length === 0) { + console.log(`No YAML files found in ${sourceDir}`); + return; + } + + await ensureDirectoryExists(outputDir); - for (const specFile of SPEC_FILES) { - const sourceFilePath = path.join(SOURCE_DIR, specFile); - const outputFilePath = path.join(OUTPUT_DIR, specFile); + for (const specFile of specFiles) { + const sourceFilePath = path.join(sourceDir, specFile); + const outputFileName = specFile.includes('client') + ? 'client_rest.yaml' + : specFile.includes('index') + ? 'indexing.yaml' + : path.join(outputDir, specFile); + const outputFilePath = path.join(outputDir, outputFileName); console.log(`Processing ${sourceFilePath}`); const yamlContent = await readYamlFromFile(sourceFilePath); - const transformedYaml = transform(yamlContent, specFile); + const transformedYaml = codeSamplesTransformer.transform( + yamlContent, + specFile, + ); fs.writeFileSync(outputFilePath, transformedYaml, 'utf8'); @@ -55,6 +118,8 @@ export async function run() { const args = process.argv.slice(2); if (args.includes('--source_specs')) { await transformSourceSpecs(); + } else if (args.includes('--merged_code_samples_specs')) { + await transformMergedCodeSamplesSpecs(); } } diff --git a/tests/code-sample-transformer.test.js b/tests/code-sample-transformer.test.js new file mode 100644 index 0000000..69b6682 --- /dev/null +++ b/tests/code-sample-transformer.test.js @@ -0,0 +1,135 @@ +import { beforeEach, describe, test, expect } from 'vitest'; +import * as path from 'node:path'; +import * as fs from 'node:fs'; +import yaml from 'js-yaml'; +import * as codeSampleTransformer from '../src/code-sample-transformer.js'; + +function readFixture(filename) { + const sourceFile = path.join(process.cwd(), 'tests', 'fixtures', filename); + return fs.readFileSync(sourceFile, 'utf8'); +} + +describe('Code Sample Transformer', () => { + let fixtureContent, fixtureFilename; + + beforeEach(() => { + fixtureFilename = 'example-with-code-samples.yaml'; + fixtureContent = readFixture(fixtureFilename); + }); + + describe('path', () => { + test('yields each path found in the spec', async () => { + const spec = yaml.load(` +openapi: 3.0.0 +paths: + /foo: + post: + /baz: + get: + `); + + const items = []; + for (let [path, pathSpec] of codeSampleTransformer.path(spec)) { + items.push({ path, pathSpec }); + } + + expect(items).toMatchInlineSnapshot(` + [ + { + "path": "/foo", + "pathSpec": { + "post": null, + }, + }, + { + "path": "/baz", + "pathSpec": { + "get": null, + }, + }, + ] + `); + }); + }); + + describe('extractCodeSnippet', () => { + test('returns code snippet for specified language', () => { + const pathSpec = yaml.load(` + post: + x-speakeasy-group: client.chat + x-speakeasy-name-override: create + x-speakeasy-usage-example: true + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + print("huzzah!") + - lang: typescript + label: Typescript (API Client) + source: |- + console.log("huzzah!") + `); + + expect( + codeSampleTransformer.extractCodeSnippet(pathSpec, 'python'), + ).toMatchInlineSnapshot( + ` + { + "label": "Python (API Client)", + "lang": "python", + "source": "print("huzzah!")", + } + `, + ); + expect( + codeSampleTransformer.extractCodeSnippet(pathSpec, 'typescript'), + ).toMatchInlineSnapshot( + ` + { + "label": "Typescript (API Client)", + "lang": "typescript", + "source": "console.log("huzzah!")", + } + `, + ); + }); + }); + + describe('transformPythonCodeSnippetsForNamespacing', () => { + test('updates chat code sample to use namespace', () => { + const spec = yaml.load(fixtureContent); + + const updatedSpec = + codeSampleTransformer.transformPythonCodeSamplesToPython(spec); + const chatSpec = updatedSpec.paths['/rest/api/v1/chat']; + + expect(codeSampleTransformer.extractCodeSnippet(chatSpec, 'python')) + .toMatchInlineSnapshot(` + { + "label": "Python (API Client)", + "lang": "python", + "source": "from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.chat.create(messages=[ + { + "fragments": [ + models.ChatMessageFragment( + text="What are the company holidays this year?", + ), + ], + }, + ], timeout_millis=30000) + + # Handle response + print(res)", + } + `); + }); + }); +}); diff --git a/tests/fixtures/example-with-code-samples.yaml b/tests/fixtures/example-with-code-samples.yaml new file mode 100644 index 0000000..a562877 --- /dev/null +++ b/tests/fixtures/example-with-code-samples.yaml @@ -0,0 +1,568 @@ +openapi: 3.0.0 +info: + version: 0.9.0 + title: Glean API + x-speakeasy-name: 'Glean API' +servers: + - url: https://{instance}-be.glean.com + variables: + instance: + default: instance-name + description: The instance name (typically the email domain without the TLD) that determines the deployment backend. +security: + - APIToken: [] +paths: + /rest/api/v1/chat: + post: + tags: + - Chat + summary: Chat + description: Have a conversation with Glean AI. + operationId: chat + x-visibility: Public + x-codegen-request-body-name: payload + parameters: + - $ref: '#/components/parameters/timezoneOffset' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ChatRequest' + examples: + defaultExample: + value: + messages: + - author: USER + messageType: CONTENT + fragments: + - text: What are the company holidays this year? + gptAgentExample: + value: + agentConfig: + agent: GPT + messages: + - author: USER + messageType: CONTENT + fragments: + - text: Who was the first person to land on the moon? + description: Includes chat history for Glean AI to respond to. + required: true + x-exportParamName: Request + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/ChatResponse' + examples: + defaultExample: + value: + messages: + - author: GLEAN_AI + messageType: CONTENT + hasMoreFragments: false + agentConfig: + agent: DEFAULT + mode: DEFAULT + fragments: + - text: There are no holidays! + streamingExample: + value: + messages: + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: true + fragments: null + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: true + fragments: null + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: true + fragments: + - text: e are + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: true + fragments: + - text: no hol + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: false + fragments: + - text: idays! + updateResponse: + value: + messages: + - author: GLEAN_AI + messageType: UPDATE + agentConfig: + agent: DEFAULT + mode: DEFAULT + fragments: + - text: '**Reading:**' + - structuredResults: + - document: + id: '123' + title: Company Handbook + citationResponse: + value: + messages: + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + citations: + - sourceDocument: + id: '123' + title: Company Handbook + referenceRanges: + - textRange: + startIndex: 0 + endIndex: 12 + type: CITATION + '400': + description: Invalid request + '401': + description: Not Authorized + '408': + description: Request Timeout + '429': + description: Too Many Requests + x-speakeasy-group: client.chat + x-speakeasy-name-override: create + x-speakeasy-usage-example: true + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.chat.create(messages=[ + { + "fragments": [ + models.ChatMessageFragment( + text="What are the company holidays this year?", + ), + ], + }, + ], timeout_millis=30000) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.chat.create({ + messages: [ + { + fragments: [ + { + text: "What are the company holidays this year?", + }, + ], + }, + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: |- + package main + + import( + "context" + "os" + apiclientgo "github.com/gleanwork/api-client-go" + "github.com/gleanwork/api-client-go/models/components" + "log" + ) + + func main() { + ctx := context.Background() + + s := apiclientgo.New( + apiclientgo.WithSecurity(os.Getenv("GLEAN_API_TOKEN")), + ) + + res, err := s.Client.Chat.Create(ctx, components.ChatRequest{ + Messages: []components.ChatMessage{ + components.ChatMessage{ + Fragments: []components.ChatMessageFragment{ + components.ChatMessageFragment{ + Text: apiclientgo.String("What are the company holidays this year?"), + }, + }, + }, + }, + }, nil) + if err != nil { + log.Fatal(err) + } + if res.ChatResponse != nil { + // handle response + } + } + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.ChatResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ChatResponse res = sdk.client().chat().create() + .chatRequest(ChatRequest.builder() + .messages(List.of( + ChatMessage.builder() + .fragments(List.of( + ChatMessageFragment.builder() + .text("What are the company holidays this year?") + .build())) + .build())) + .build()) + .call(); + + if (res.chatResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/search: + post: + tags: + - Search + summary: Search + description: Retrieve results from the index for the given query and filters. + operationId: search + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/SearchRequest' + description: Search request + required: true + x-exportParamName: Request + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/SearchResponse' + '400': + description: Invalid request + '401': + description: Not Authorized + '403': + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorInfo' + '408': + description: Request Timeout + '422': + description: Invalid Query + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorInfo' + '429': + description: Too Many Requests + x-speakeasy-group: client.search + x-speakeasy-name-override: query + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean import Glean, models + from glean.utils import parse_datetime + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.search.query(query="vacation policy", tracking_token="trackingToken", source_document=models.Document( + container_document=models.Document( + parent_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + ), page_size=10, max_snippet_size=400, input_details={ + "has_copy_paste": True, + }, request_options=models.SearchRequestOptions( + facet_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="article", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="document", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + models.FacetFilter( + field_name="department", + values=[ + models.FacetFilterValue( + value="engineering", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + facet_bucket_size=939520, + ), timeout_millis=5000, people=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.search.query({ + trackingToken: "trackingToken", + pageSize: 10, + query: "vacation policy", + requestOptions: { + facetFilters: [ + { + fieldName: "type", + values: [ + { + value: "article", + relationType: "EQUALS", + }, + { + value: "document", + relationType: "EQUALS", + }, + ], + }, + { + fieldName: "department", + values: [ + { + value: "engineering", + relationType: "EQUALS", + }, + ], + }, + ], + facetBucketSize: 939520, + }, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: |- + package main + + import( + "context" + "os" + apiclientgo "github.com/gleanwork/api-client-go" + "github.com/gleanwork/api-client-go/types" + "github.com/gleanwork/api-client-go/models/components" + "log" + ) + + func main() { + ctx := context.Background() + + s := apiclientgo.New( + apiclientgo.WithSecurity(os.Getenv("GLEAN_API_TOKEN")), + ) + + res, err := s.Client.Search.Query(ctx, components.SearchRequest{ + TrackingToken: apiclientgo.String("trackingToken"), + PageSize: apiclientgo.Int64(10), + Query: "vacation policy", + RequestOptions: &components.SearchRequestOptions{ + FacetFilters: []components.FacetFilter{ + components.FacetFilter{ + FieldName: apiclientgo.String("type"), + Values: []components.FacetFilterValue{ + components.FacetFilterValue{ + Value: apiclientgo.String("article"), + RelationType: components.RelationTypeEquals.ToPointer(), + }, + components.FacetFilterValue{ + Value: apiclientgo.String("document"), + RelationType: components.RelationTypeEquals.ToPointer(), + }, + }, + }, + components.FacetFilter{ + FieldName: apiclientgo.String("department"), + Values: []components.FacetFilterValue{ + components.FacetFilterValue{ + Value: apiclientgo.String("engineering"), + RelationType: components.RelationTypeEquals.ToPointer(), + }, + }, + }, + }, + FacetBucketSize: 939520, + }, + }) + if err != nil { + log.Fatal(err) + } + if res.SearchResponse != nil { + // handle response + } + } + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.errors.GleanDataError; + import com.glean.api_client.glean_api_client.models.operations.SearchResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws GleanDataError, Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + SearchRequest req = SearchRequest.builder() + .query("vacation policy") + .trackingToken("trackingToken") + .pageSize(10L) + .requestOptions(SearchRequestOptions.builder() + .facetBucketSize(939520L) + .facetFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("article") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("document") + .relationType(RelationType.EQUALS) + .build())) + .build(), + FacetFilter.builder() + .fieldName("department") + .values(List.of( + FacetFilterValue.builder() + .value("engineering") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build()) + .build(); + + SearchResponse res = sdk.client().search().query() + .request(req) + .call(); + + if (res.searchResponse().isPresent()) { + // handle response + } + } + } From 85f889a4b6bf4170d2ab09b0d10d5ed26cc7f674 Mon Sep 17 00:00:00 2001 From: Robert Jackson Date: Sat, 31 May 2025 09:46:33 -0400 Subject: [PATCH 2/2] chore: `pnpm transform:merged_code_samples_specs` --- modified_code_samples_specs/client_rest.yaml | 34872 +++++++++++++++++ modified_code_samples_specs/indexing.yaml | 5692 +++ 2 files changed, 40564 insertions(+) create mode 100644 modified_code_samples_specs/client_rest.yaml create mode 100644 modified_code_samples_specs/indexing.yaml diff --git a/modified_code_samples_specs/client_rest.yaml b/modified_code_samples_specs/client_rest.yaml new file mode 100644 index 0000000..22c46b0 --- /dev/null +++ b/modified_code_samples_specs/client_rest.yaml @@ -0,0 +1,34872 @@ +openapi: 3.0.0 +info: + version: 0.9.0 + title: Glean API + contact: + email: support@glean.com + description: | + # Introduction + In addition to the data sources that Glean has built-in support for, Glean also provides a REST API that enables customers to put arbitrary content in the search index. This is useful, for example, for doing permissions-aware search over content in internal tools that reside on-prem as well as for searching over applications that Glean does not currently support first class. In addition these APIs allow the customer to push organization data (people info, organization structure etc) into Glean. + + # Usage guidelines + This API is evolving fast. Glean will provide advance notice of any planned backwards incompatible changes along + with a 6-month sunset period for anything that requires developers to adopt the new versions. + + # API Clients + Official API clients for the Glean Indexing API are available in multiple languages: + + - [Python](https://github.com/gleanwork/api-client-python) + - [TypeScript](https://github.com/gleanwork/api-client-typescript) + - [Go](https://github.com/gleanwork/api-client-go) + - [Java](https://github.com/gleanwork/api-client-java) + + These API clients provide type-safe, idiomatic interfaces for working with Glean IndexingAPIs in your language of choice. + x-logo: + url: https://app.glean.com/images/glean-text2.svg + x-speakeasy-name: Glean API +servers: + - url: https://{instance}-be.glean.com + variables: + instance: + default: instance-name + description: The instance name (typically the email domain without the TLD) that determines the deployment backend. +security: + - APIToken: [] +paths: + /rest/api/v1/activity: + post: + tags: + - Activity + summary: Report document activity + description: Report user activity that occurs on indexed documents such as viewing or editing. This signal improves search quality. + operationId: activity + x-visibility: Public + x-codegen-request-body-name: payload + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/Activity" + required: true + x-exportParamName: Activity + responses: + "200": + description: OK + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: report + x-speakeasy-group: client.activity + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + from glean.api_client.utils import parse_datetime + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.client.activity.report(events=[ + { + "action": models.ActivityEventAction.HISTORICAL_VIEW, + "timestamp": parse_datetime("2000-01-23T04:56:07.000Z"), + "url": "https://example.com/", + }, + { + "action": models.ActivityEventAction.SEARCH, + "params": { + "query": "query", + }, + "timestamp": parse_datetime("2000-01-23T04:56:07.000Z"), + "url": "https://example.com/search?q=query", + }, + { + "action": models.ActivityEventAction.VIEW, + "params": { + "duration": 20, + "referrer": "https://example.com/document", + }, + "timestamp": parse_datetime("2000-01-23T04:56:07.000Z"), + "url": "https://example.com/", + }, + ]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.client.activity.report({ + events: [ + { + action: "HISTORICAL_VIEW", + timestamp: new Date("2000-01-23T04:56:07.000Z"), + url: "https://example.com/", + }, + { + action: "SEARCH", + params: { + query: "query", + }, + timestamp: new Date("2000-01-23T04:56:07.000Z"), + url: "https://example.com/search?q=query", + }, + { + action: "VIEW", + params: { + duration: 20, + referrer: "https://example.com/document", + }, + timestamp: new Date("2000-01-23T04:56:07.000Z"), + url: "https://example.com/", + }, + ], + }); + + + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"github.com/gleanwork/api-client-go/types\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Activity.Report(ctx, components.Activity{\n Events: []components.ActivityEvent{\n components.ActivityEvent{\n Action: components.ActivityEventActionHistoricalView,\n Timestamp: types.MustTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n URL: \"https://example.com/\",\n },\n components.ActivityEvent{\n Action: components.ActivityEventActionSearch,\n Params: &components.ActivityEventParams{\n Query: apiclientgo.String(\"query\"),\n },\n Timestamp: types.MustTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n URL: \"https://example.com/search?q=query\",\n },\n components.ActivityEvent{\n Action: components.ActivityEventActionView,\n Params: &components.ActivityEventParams{\n Duration: apiclientgo.Int64(20),\n Referrer: apiclientgo.String(\"https://example.com/document\"),\n },\n Timestamp: types.MustTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n URL: \"https://example.com/\",\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.ActivityResponse; + import java.lang.Exception; + import java.time.OffsetDateTime; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + Activity req = Activity.builder() + .events(List.of( + ActivityEvent.builder() + .action(ActivityEventAction.HISTORICAL_VIEW) + .timestamp(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .url("https://example.com/") + .build(), + ActivityEvent.builder() + .action(ActivityEventAction.SEARCH) + .timestamp(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .url("https://example.com/search?q=query") + .params(ActivityEventParams.builder() + .query("query") + .build()) + .build(), + ActivityEvent.builder() + .action(ActivityEventAction.VIEW) + .timestamp(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .url("https://example.com/") + .params(ActivityEventParams.builder() + .duration(20L) + .referrer("https://example.com/document") + .build()) + .build())) + .build(); + + ActivityResponse res = sdk.client().activity().report() + .request(req) + .call(); + + // handle response + } + } + /rest/api/v1/feedback: + post: + tags: + - Activity + summary: Report client activity + description: Report events that happen to results within a Glean client UI, such as search result views and clicks. This signal improves search quality. + operationId: feedback + x-visibility: Public + x-codegen-request-body-name: payload + parameters: + - name: feedback + in: query + description: A URL encoded versions of Feedback. This is useful for requests. + required: false + schema: + type: string + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/Feedback" + x-exportParamName: Feedback + responses: + "200": + description: OK + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-group: client.activity + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.client.activity.feedback(feedback1={ + "tracking_tokens": [ + "trackingTokens", + ], + "event": models.Event.VIEW, + }) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.client.activity.feedback({ + trackingTokens: [ + "trackingTokens", + ], + event: "VIEW", + }); + + + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Activity.Feedback(ctx, nil, &components.Feedback{\n TrackingTokens: []string{\n \"trackingTokens\",\n },\n Event: components.EventView,\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.Event; + import com.glean.api_client.glean_api_client.models.components.Feedback; + import com.glean.api_client.glean_api_client.models.operations.FeedbackResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + FeedbackResponse res = sdk.client().activity().feedback() + .feedback1(Feedback.builder() + .trackingTokens(List.of( + "trackingTokens")) + .event(Event.VIEW) + .build()) + .call(); + + // handle response + } + } + /rest/api/v1/createannouncement: + post: + tags: + - Announcements + summary: Create Announcement + description: Create a textual announcement visible to some set of users based on department and location. + operationId: createannouncement + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CreateAnnouncementRequest" + description: Announcement content + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/Announcement" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: create + x-speakeasy-group: client.announcements + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + from glean.api_client.utils import parse_datetime + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.announcements.create(start_time=parse_datetime("2023-05-01T12:02:10.816Z"), end_time=parse_datetime("2024-03-17T14:19:30.278Z"), title="", body={ + "text": "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + "structured_list": [ + models.StructuredTextItem( + link="https://en.wikipedia.org/wiki/Diffuse_sky_radiation", + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + text="Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.", + structured_result=models.StructuredResult( + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + customer=models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + poc=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ], + merged_customers=[ + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + ], + notes="CIO is interested in trying out the product.", + ), + team=models.Team( + id="", + name="", + members=[ + models.PersonToTeamRelationship( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.PersonToTeamRelationship( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + custom_fields=[ + models.CustomFieldData( + label="", + values=[ + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.CustomFieldData( + label="", + values=[ + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.CustomFieldData( + label="", + values=[ + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + ], + datasource_profiles=[ + models.DatasourceProfile( + datasource="github", + handle="", + ), + models.DatasourceProfile( + datasource="github", + handle="", + ), + models.DatasourceProfile( + datasource="github", + handle="", + ), + ], + ), + custom_entity=models.CustomEntity( + roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + ], + ), + answer=models.Answer( + id=3, + doc_id="ANSWERS_answer_3", + question="Why is the sky blue?", + body_text="From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + added_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + ], + removed_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VERIFIER, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VERIFIER, + ), + ], + likes=models.AnswerLikes( + liked_by=[ + models.AnswerLike( + user=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.AnswerLike( + user=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.AnswerLike( + user=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + liked_by_user=False, + num_likes=716571, + ), + author=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + verification=models.Verification( + state=models.State.UNVERIFIED, + metadata=models.VerificationMetadata( + last_verifier=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + reminders=[ + models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=852101, + ), + ], + last_reminder=models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=829206, + ), + candidate_verifiers=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ], + ), + ), + board=models.AnswerBoard( + name="", + description="pronoun whether likely likewise negative possession ape furthermore", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=856490, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + collections=[ + models.Collection( + name="", + description="tedious given quixotic", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=590805, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + items=[ + models.CollectionItem( + collection_id=913703, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.COLLECTION, + ), + ], + children=[ + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.Collection( + name="", + description="tedious given quixotic", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=590805, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + items=[ + models.CollectionItem( + collection_id=913703, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.COLLECTION, + ), + ], + children=[ + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.Collection( + name="", + description="tedious given quixotic", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=590805, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + items=[ + models.CollectionItem( + collection_id=913703, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.COLLECTION, + ), + ], + children=[ + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + ], + source_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + extracted_qn_a=models.ExtractedQnA( + question_result=models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ), + meeting=models.Meeting( + attendees=models.CalendarAttendees( + people=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + group_attendees=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + ], + ), + ), + collection=models.Collection( + name="", + description="fortunate ha gazebo", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=437915, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + answer_board=models.AnswerBoard( + name="", + description="grouper amidst pulse fowl swine that following adolescent yippee celsius", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=751446, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + code=models.Code( + repo_name="scio", + file_name="README.md", + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + query_suggestions=models.QuerySuggestionList( + suggestions=[ + models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + ], + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + related_documents=[ + models.RelatedDocuments( + query_suggestion=models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + results=[ + models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ], + ), + models.RelatedDocuments( + query_suggestion=models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + results=[ + models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ], + ), + models.RelatedDocuments( + query_suggestion=models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + results=[ + models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ], + ), + ], + related_question=models.RelatedQuestion( + ranges=[ + models.TextRange( + start_index=913402, + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + models.TextRange( + start_index=913402, + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + models.TextRange( + start_index=913402, + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + ], + ), + ), + ), + models.StructuredTextItem( + link="https://en.wikipedia.org/wiki/Diffuse_sky_radiation", + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + text="Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.", + structured_result=models.StructuredResult( + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + customer=models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + poc=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ], + merged_customers=[ + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + ], + notes="CIO is interested in trying out the product.", + ), + team=models.Team( + id="", + name="", + members=[ + models.PersonToTeamRelationship( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.PersonToTeamRelationship( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + custom_fields=[ + models.CustomFieldData( + label="", + values=[ + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.CustomFieldData( + label="", + values=[ + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.CustomFieldData( + label="", + values=[ + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CustomFieldValuePerson( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + ], + datasource_profiles=[ + models.DatasourceProfile( + datasource="github", + handle="", + ), + models.DatasourceProfile( + datasource="github", + handle="", + ), + models.DatasourceProfile( + datasource="github", + handle="", + ), + ], + ), + custom_entity=models.CustomEntity( + roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + ], + ), + answer=models.Answer( + id=3, + doc_id="ANSWERS_answer_3", + question="Why is the sky blue?", + body_text="From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + added_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + ], + removed_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VERIFIER, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VERIFIER, + ), + ], + likes=models.AnswerLikes( + liked_by=[ + models.AnswerLike( + user=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.AnswerLike( + user=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.AnswerLike( + user=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + liked_by_user=False, + num_likes=716571, + ), + author=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + verification=models.Verification( + state=models.State.UNVERIFIED, + metadata=models.VerificationMetadata( + last_verifier=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + reminders=[ + models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=852101, + ), + ], + last_reminder=models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=829206, + ), + candidate_verifiers=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ], + ), + ), + board=models.AnswerBoard( + name="", + description="pronoun whether likely likewise negative possession ape furthermore", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=856490, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + collections=[ + models.Collection( + name="", + description="tedious given quixotic", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=590805, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + items=[ + models.CollectionItem( + collection_id=913703, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.COLLECTION, + ), + ], + children=[ + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.Collection( + name="", + description="tedious given quixotic", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=590805, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + items=[ + models.CollectionItem( + collection_id=913703, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.COLLECTION, + ), + ], + children=[ + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.Collection( + name="", + description="tedious given quixotic", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=590805, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + items=[ + models.CollectionItem( + collection_id=913703, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.COLLECTION, + ), + ], + children=[ + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="whoever vice reassuringly boo fess", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=953002, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + ], + source_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + extracted_qn_a=models.ExtractedQnA( + question_result=models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ), + meeting=models.Meeting( + attendees=models.CalendarAttendees( + people=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + group_attendees=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + ], + ), + ), + collection=models.Collection( + name="", + description="fortunate ha gazebo", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=437915, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + answer_board=models.AnswerBoard( + name="", + description="grouper amidst pulse fowl swine that following adolescent yippee celsius", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=751446, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + code=models.Code( + repo_name="scio", + file_name="README.md", + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + query_suggestions=models.QuerySuggestionList( + suggestions=[ + models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + ], + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + related_documents=[ + models.RelatedDocuments( + query_suggestion=models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + results=[ + models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ], + ), + models.RelatedDocuments( + query_suggestion=models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + results=[ + models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ], + ), + models.RelatedDocuments( + query_suggestion=models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + results=[ + models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ], + ), + ], + related_question=models.RelatedQuestion( + ranges=[ + models.TextRange( + start_index=913402, + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + models.TextRange( + start_index=913402, + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + models.TextRange( + start_index=913402, + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + ], + ), + ), + ), + ], + }, audience_filters=[ + { + "field_name": "type", + "values": [ + { + "value": "Spreadsheet", + "relation_type": models.RelationType.EQUALS, + }, + { + "value": "Presentation", + "relation_type": models.RelationType.EQUALS, + }, + ], + }, + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.announcements.create({ + startTime: new Date("2023-05-01T12:02:10.816Z"), + endTime: new Date("2024-03-17T14:19:30.278Z"), + title: "", + body: { + text: "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + structuredList: [ + { + link: "https://en.wikipedia.org/wiki/Diffuse_sky_radiation", + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + text: "Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.", + structuredResult: { + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + customer: { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + poc: [ + { + name: "George Clooney", + obfuscatedId: "abc123", + }, + ], + mergedCustomers: [ + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + ], + notes: "CIO is interested in trying out the product.", + }, + team: { + id: "", + name: "", + members: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + customFields: [ + { + label: "", + values: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + label: "", + values: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + label: "", + values: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + ], + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + ], + }, + customEntity: { + roles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + ], + }, + answer: { + id: 3, + docId: "ANSWERS_answer_3", + question: "Why is the sky blue?", + bodyText: "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + addedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + ], + removedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VERIFIER", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VERIFIER", + }, + ], + likes: { + likedBy: [ + { + user: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + user: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + user: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + likedByUser: false, + numLikes: 716571, + }, + author: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + verification: { + state: "UNVERIFIED", + metadata: { + lastVerifier: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + reminders: [ + { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 852101, + }, + ], + lastReminder: { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 829206, + }, + candidateVerifiers: [ + { + name: "George Clooney", + obfuscatedId: "abc123", + }, + ], + }, + }, + board: { + name: "", + description: "pronoun whether likely likewise negative possession ape furthermore", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 856490, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + collections: [ + { + name: "", + description: "tedious given quixotic", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 590805, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + items: [ + { + collectionId: 913703, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "COLLECTION", + }, + ], + children: [ + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + name: "", + description: "tedious given quixotic", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 590805, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + items: [ + { + collectionId: 913703, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "COLLECTION", + }, + ], + children: [ + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + name: "", + description: "tedious given quixotic", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 590805, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + items: [ + { + collectionId: 913703, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "COLLECTION", + }, + ], + children: [ + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + ], + sourceDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + extractedQnA: { + questionResult: { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + }, + meeting: { + attendees: { + people: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + groupAttendees: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + ], + }, + }, + collection: { + name: "", + description: "fortunate ha gazebo", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 437915, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + answerBoard: { + name: "", + description: "grouper amidst pulse fowl swine that following adolescent yippee celsius", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 751446, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + code: { + repoName: "scio", + fileName: "README.md", + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + querySuggestions: { + suggestions: [ + { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + ], + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + relatedDocuments: [ + { + querySuggestion: { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + results: [ + { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + ], + }, + { + querySuggestion: { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + results: [ + { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + ], + }, + { + querySuggestion: { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + results: [ + { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + ], + }, + ], + relatedQuestion: { + ranges: [ + { + startIndex: 913402, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + { + startIndex: 913402, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + { + startIndex: 913402, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + ], + }, + }, + }, + { + link: "https://en.wikipedia.org/wiki/Diffuse_sky_radiation", + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + text: "Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.", + structuredResult: { + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + customer: { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + poc: [ + { + name: "George Clooney", + obfuscatedId: "abc123", + }, + ], + mergedCustomers: [ + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + ], + notes: "CIO is interested in trying out the product.", + }, + team: { + id: "", + name: "", + members: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + customFields: [ + { + label: "", + values: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + label: "", + values: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + label: "", + values: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + ], + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + ], + }, + customEntity: { + roles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + ], + }, + answer: { + id: 3, + docId: "ANSWERS_answer_3", + question: "Why is the sky blue?", + bodyText: "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + addedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + ], + removedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VERIFIER", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VERIFIER", + }, + ], + likes: { + likedBy: [ + { + user: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + user: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + user: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + likedByUser: false, + numLikes: 716571, + }, + author: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + verification: { + state: "UNVERIFIED", + metadata: { + lastVerifier: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + reminders: [ + { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 852101, + }, + ], + lastReminder: { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 829206, + }, + candidateVerifiers: [ + { + name: "George Clooney", + obfuscatedId: "abc123", + }, + ], + }, + }, + board: { + name: "", + description: "pronoun whether likely likewise negative possession ape furthermore", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 856490, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + collections: [ + { + name: "", + description: "tedious given quixotic", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 590805, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + items: [ + { + collectionId: 913703, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "COLLECTION", + }, + ], + children: [ + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + name: "", + description: "tedious given quixotic", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 590805, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + items: [ + { + collectionId: 913703, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "COLLECTION", + }, + ], + children: [ + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + name: "", + description: "tedious given quixotic", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 590805, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + items: [ + { + collectionId: 913703, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "COLLECTION", + }, + ], + children: [ + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "whoever vice reassuringly boo fess", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 953002, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + ], + sourceDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + extractedQnA: { + questionResult: { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + }, + meeting: { + attendees: { + people: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + groupAttendees: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + ], + }, + }, + collection: { + name: "", + description: "fortunate ha gazebo", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 437915, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + answerBoard: { + name: "", + description: "grouper amidst pulse fowl swine that following adolescent yippee celsius", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 751446, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + code: { + repoName: "scio", + fileName: "README.md", + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + querySuggestions: { + suggestions: [ + { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + ], + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + relatedDocuments: [ + { + querySuggestion: { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + results: [ + { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + ], + }, + { + querySuggestion: { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + results: [ + { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + ], + }, + { + querySuggestion: { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + results: [ + { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + ], + }, + ], + relatedQuestion: { + ranges: [ + { + startIndex: 913402, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + { + startIndex: 913402, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + { + startIndex: 913402, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + ], + }, + }, + }, + ], + }, + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/types\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Announcements.Create(ctx, components.CreateAnnouncementRequest{\n StartTime: types.MustTimeFromString(\"2023-05-01T12:02:10.816Z\"),\n EndTime: types.MustTimeFromString(\"2024-03-17T14:19:30.278Z\"),\n Title: \"\",\n Body: &components.StructuredText{\n Text: \"From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.\",\n StructuredList: []components.StructuredTextItem{\n components.StructuredTextItem{\n Link: apiclientgo.String(\"https://en.wikipedia.org/wiki/Diffuse_sky_radiation\"),\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Text: apiclientgo.String(\"Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.\"),\n StructuredResult: &components.StructuredResult{\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Customer: &components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Poc: []components.Person{\n components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n MergedCustomers: []components.Customer{\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n Team: &components.Team{\n ID: \"\",\n Name: \"\",\n Members: []components.PersonToTeamRelationship{\n components.PersonToTeamRelationship{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.PersonToTeamRelationship{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n CustomFields: []components.CustomFieldData{\n components.CustomFieldData{\n Label: \"\",\n Values: []components.CustomFieldValue{\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n },\n },\n components.CustomFieldData{\n Label: \"\",\n Values: []components.CustomFieldValue{\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n },\n },\n components.CustomFieldData{\n Label: \"\",\n Values: []components.CustomFieldValue{\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n },\n },\n },\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n },\n CustomEntity: &components.CustomEntity{\n Roles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n },\n },\n Answer: &components.Answer{\n ID: 3,\n DocID: apiclientgo.String(\"ANSWERS_answer_3\"),\n Question: apiclientgo.String(\"Why is the sky blue?\"),\n BodyText: apiclientgo.String(\"From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.\"),\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n AddedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n },\n RemovedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleVerifier,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleVerifier,\n },\n },\n Likes: &components.AnswerLikes{\n LikedBy: []components.AnswerLike{\n components.AnswerLike{\n User: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.AnswerLike{\n User: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.AnswerLike{\n User: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n LikedByUser: false,\n NumLikes: 716571,\n },\n Author: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Verification: &components.Verification{\n State: components.StateUnverified,\n Metadata: &components.VerificationMetadata{\n LastVerifier: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Reminders: []components.Reminder{\n components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 852101,\n },\n },\n LastReminder: &components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 829206,\n },\n CandidateVerifiers: []components.Person{\n components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n Board: &components.AnswerBoard{\n Name: \"\",\n Description: \"pronoun whether likely likewise negative possession ape furthermore\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 856490,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n Collections: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"tedious given quixotic\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 590805,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Items: []components.CollectionItem{\n components.CollectionItem{\n CollectionID: 913703,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeCollection,\n },\n },\n Children: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"tedious given quixotic\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 590805,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Items: []components.CollectionItem{\n components.CollectionItem{\n CollectionID: 913703,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeCollection,\n },\n },\n Children: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"tedious given quixotic\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 590805,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Items: []components.CollectionItem{\n components.CollectionItem{\n CollectionID: 913703,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeCollection,\n },\n },\n Children: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n },\n SourceDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ExtractedQnA: &components.ExtractedQnA{\n QuestionResult: &components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n Meeting: &components.Meeting{\n Attendees: &components.CalendarAttendees{\n People: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n GroupAttendees: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n },\n },\n },\n Collection: &components.Collection{\n Name: \"\",\n Description: \"fortunate ha gazebo\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 437915,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n AnswerBoard: &components.AnswerBoard{\n Name: \"\",\n Description: \"grouper amidst pulse fowl swine that following adolescent yippee celsius\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 751446,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n Code: &components.Code{\n RepoName: apiclientgo.String(\"scio\"),\n FileName: apiclientgo.String(\"README.md\"),\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n QuerySuggestions: &components.QuerySuggestionList{\n Suggestions: []components.QuerySuggestion{\n components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n },\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n RelatedDocuments: []components.RelatedDocuments{\n components.RelatedDocuments{\n QuerySuggestion: &components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n Results: []components.SearchResult{\n components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n },\n components.RelatedDocuments{\n QuerySuggestion: &components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n Results: []components.SearchResult{\n components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n },\n components.RelatedDocuments{\n QuerySuggestion: &components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n Results: []components.SearchResult{\n components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n },\n },\n RelatedQuestion: &components.RelatedQuestion{\n Ranges: []components.TextRange{\n components.TextRange{\n StartIndex: 913402,\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n components.TextRange{\n StartIndex: 913402,\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n components.TextRange{\n StartIndex: 913402,\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n },\n },\n },\n },\n components.StructuredTextItem{\n Link: apiclientgo.String(\"https://en.wikipedia.org/wiki/Diffuse_sky_radiation\"),\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Text: apiclientgo.String(\"Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.\"),\n StructuredResult: &components.StructuredResult{\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Customer: &components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Poc: []components.Person{\n components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n MergedCustomers: []components.Customer{\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n Team: &components.Team{\n ID: \"\",\n Name: \"\",\n Members: []components.PersonToTeamRelationship{\n components.PersonToTeamRelationship{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.PersonToTeamRelationship{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n CustomFields: []components.CustomFieldData{\n components.CustomFieldData{\n Label: \"\",\n Values: []components.CustomFieldValue{\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n },\n },\n components.CustomFieldData{\n Label: \"\",\n Values: []components.CustomFieldValue{\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n },\n },\n components.CustomFieldData{\n Label: \"\",\n Values: []components.CustomFieldValue{\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n components.CreateCustomFieldValueCustomFieldValuePerson(\n components.CustomFieldValuePerson{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n ),\n },\n },\n },\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n },\n CustomEntity: &components.CustomEntity{\n Roles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n },\n },\n Answer: &components.Answer{\n ID: 3,\n DocID: apiclientgo.String(\"ANSWERS_answer_3\"),\n Question: apiclientgo.String(\"Why is the sky blue?\"),\n BodyText: apiclientgo.String(\"From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.\"),\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n AddedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n },\n RemovedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleVerifier,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleVerifier,\n },\n },\n Likes: &components.AnswerLikes{\n LikedBy: []components.AnswerLike{\n components.AnswerLike{\n User: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.AnswerLike{\n User: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.AnswerLike{\n User: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n LikedByUser: false,\n NumLikes: 716571,\n },\n Author: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Verification: &components.Verification{\n State: components.StateUnverified,\n Metadata: &components.VerificationMetadata{\n LastVerifier: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Reminders: []components.Reminder{\n components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 852101,\n },\n },\n LastReminder: &components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 829206,\n },\n CandidateVerifiers: []components.Person{\n components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n Board: &components.AnswerBoard{\n Name: \"\",\n Description: \"pronoun whether likely likewise negative possession ape furthermore\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 856490,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n Collections: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"tedious given quixotic\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 590805,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Items: []components.CollectionItem{\n components.CollectionItem{\n CollectionID: 913703,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeCollection,\n },\n },\n Children: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"tedious given quixotic\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 590805,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Items: []components.CollectionItem{\n components.CollectionItem{\n CollectionID: 913703,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeCollection,\n },\n },\n Children: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"tedious given quixotic\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 590805,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Items: []components.CollectionItem{\n components.CollectionItem{\n CollectionID: 913703,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeCollection,\n },\n },\n Children: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"whoever vice reassuringly boo fess\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 953002,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n },\n SourceDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ExtractedQnA: &components.ExtractedQnA{\n QuestionResult: &components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n Meeting: &components.Meeting{\n Attendees: &components.CalendarAttendees{\n People: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n GroupAttendees: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n },\n },\n },\n Collection: &components.Collection{\n Name: \"\",\n Description: \"fortunate ha gazebo\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 437915,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n AnswerBoard: &components.AnswerBoard{\n Name: \"\",\n Description: \"grouper amidst pulse fowl swine that following adolescent yippee celsius\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 751446,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n Code: &components.Code{\n RepoName: apiclientgo.String(\"scio\"),\n FileName: apiclientgo.String(\"README.md\"),\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n QuerySuggestions: &components.QuerySuggestionList{\n Suggestions: []components.QuerySuggestion{\n components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n },\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n RelatedDocuments: []components.RelatedDocuments{\n components.RelatedDocuments{\n QuerySuggestion: &components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n Results: []components.SearchResult{\n components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n },\n components.RelatedDocuments{\n QuerySuggestion: &components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n Results: []components.SearchResult{\n components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n },\n components.RelatedDocuments{\n QuerySuggestion: &components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n Results: []components.SearchResult{\n components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n },\n },\n RelatedQuestion: &components.RelatedQuestion{\n Ranges: []components.TextRange{\n components.TextRange{\n StartIndex: 913402,\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n components.TextRange{\n StartIndex: 913402,\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n components.TextRange{\n StartIndex: 913402,\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n },\n },\n },\n },\n },\n },\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.Announcement != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.CreateannouncementResponse; + import java.lang.Exception; + import java.time.OffsetDateTime; + import java.util.List; + import java.util.Map; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + CreateAnnouncementRequest req = CreateAnnouncementRequest.builder() + .startTime(OffsetDateTime.parse("2023-05-01T12:02:10.816Z")) + .endTime(OffsetDateTime.parse("2024-03-17T14:19:30.278Z")) + .title("") + .body(StructuredText.builder() + .text("From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.") + .structuredList(List.of( + StructuredTextItem.builder() + .link("https://en.wikipedia.org/wiki/Diffuse_sky_radiation") + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .text("Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.") + .structuredResult(StructuredResult.builder() + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .customer(Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .poc(List.of( + Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build())) + .mergedCustomers(List.of( + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build(), + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build(), + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build())) + .notes("CIO is interested in trying out the product.") + .build()) + .team(Team.builder() + .id("") + .name("") + .members(List.of( + PersonToTeamRelationship.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + PersonToTeamRelationship.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .customFields(List.of( + CustomFieldData.builder() + .label("") + .values(List.of( + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()), + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()), + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()))) + .build(), + CustomFieldData.builder() + .label("") + .values(List.of( + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()), + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()), + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()))) + .build(), + CustomFieldData.builder() + .label("") + .values(List.of( + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()), + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()), + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()))) + .build())) + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build()) + .customEntity(CustomEntity.builder() + .roles(List.of( + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build()) + .answer(Answer.builder() + .id(3L) + .docId("ANSWERS_answer_3") + .question("Why is the sky blue?") + .bodyText("From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.") + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .addedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .removedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.VERIFIER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.VERIFIER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .likes(AnswerLikes.builder() + .likedBy(List.of( + AnswerLike.builder() + .user(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + AnswerLike.builder() + .user(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + AnswerLike.builder() + .user(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .likedByUser(false) + .numLikes(716571L) + .build()) + .author(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .verification(Verification.builder() + .state(State.UNVERIFIED) + .metadata(VerificationMetadata.builder() + .lastVerifier(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .reminders(List.of( + Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(852101L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .lastReminder(Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(829206L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .candidateVerifiers(List.of( + Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build())) + .build()) + .build()) + .board(AnswerBoard.builder() + .name("") + .description("pronoun whether likely likewise negative possession ape furthermore") + .id(856490L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .collections(List.of( + Collection.builder() + .name("") + .description("tedious given quixotic") + .id(590805L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .items(List.of( + CollectionItem.builder() + .collectionId(913703L) + .itemType(CollectionItemItemType.COLLECTION) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build())) + .children(List.of( + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build(), + Collection.builder() + .name("") + .description("tedious given quixotic") + .id(590805L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .items(List.of( + CollectionItem.builder() + .collectionId(913703L) + .itemType(CollectionItemItemType.COLLECTION) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build())) + .children(List.of( + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build(), + Collection.builder() + .name("") + .description("tedious given quixotic") + .id(590805L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .items(List.of( + CollectionItem.builder() + .collectionId(913703L) + .itemType(CollectionItemItemType.COLLECTION) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build())) + .children(List.of( + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build())) + .sourceDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .extractedQnA(ExtractedQnA.builder() + .questionResult(SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build()) + .build()) + .meeting(Meeting.builder() + .attendees(CalendarAttendees.builder() + .people(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .groupAttendees(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build())) + .build()) + .build()) + .collection(Collection.builder() + .name("") + .description("fortunate ha gazebo") + .id(437915L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .answerBoard(AnswerBoard.builder() + .name("") + .description("grouper amidst pulse fowl swine that following adolescent yippee celsius") + .id(751446L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .code(Code.builder() + .repoName("scio") + .fileName("README.md") + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .querySuggestions(QuerySuggestionList.builder() + .suggestions(List.of( + QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build())) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .relatedDocuments(List.of( + RelatedDocuments.builder() + .querySuggestion(QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build()) + .results(List.of( + SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build())) + .build(), + RelatedDocuments.builder() + .querySuggestion(QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build()) + .results(List.of( + SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build())) + .build(), + RelatedDocuments.builder() + .querySuggestion(QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build()) + .results(List.of( + SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build())) + .build())) + .relatedQuestion(RelatedQuestion.builder() + .ranges(List.of( + TextRange.builder() + .startIndex(913402L) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build(), + TextRange.builder() + .startIndex(913402L) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build(), + TextRange.builder() + .startIndex(913402L) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build())) + .build()) + .build()) + .build(), + StructuredTextItem.builder() + .link("https://en.wikipedia.org/wiki/Diffuse_sky_radiation") + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .text("Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.") + .structuredResult(StructuredResult.builder() + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .customer(Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .poc(List.of( + Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build())) + .mergedCustomers(List.of( + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build(), + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build(), + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build())) + .notes("CIO is interested in trying out the product.") + .build()) + .team(Team.builder() + .id("") + .name("") + .members(List.of( + PersonToTeamRelationship.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + PersonToTeamRelationship.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .customFields(List.of( + CustomFieldData.builder() + .label("") + .values(List.of( + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()), + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()), + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()))) + .build(), + CustomFieldData.builder() + .label("") + .values(List.of( + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()), + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()), + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()))) + .build(), + CustomFieldData.builder() + .label("") + .values(List.of( + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()), + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()), + CustomFieldValue.of(CustomFieldValuePerson.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()))) + .build())) + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build()) + .customEntity(CustomEntity.builder() + .roles(List.of( + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build()) + .answer(Answer.builder() + .id(3L) + .docId("ANSWERS_answer_3") + .question("Why is the sky blue?") + .bodyText("From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.") + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .addedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .removedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.VERIFIER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.VERIFIER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .likes(AnswerLikes.builder() + .likedBy(List.of( + AnswerLike.builder() + .user(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + AnswerLike.builder() + .user(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + AnswerLike.builder() + .user(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .likedByUser(false) + .numLikes(716571L) + .build()) + .author(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .verification(Verification.builder() + .state(State.UNVERIFIED) + .metadata(VerificationMetadata.builder() + .lastVerifier(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .reminders(List.of( + Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(852101L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .lastReminder(Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(829206L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .candidateVerifiers(List.of( + Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build())) + .build()) + .build()) + .board(AnswerBoard.builder() + .name("") + .description("pronoun whether likely likewise negative possession ape furthermore") + .id(856490L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .collections(List.of( + Collection.builder() + .name("") + .description("tedious given quixotic") + .id(590805L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .items(List.of( + CollectionItem.builder() + .collectionId(913703L) + .itemType(CollectionItemItemType.COLLECTION) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build())) + .children(List.of( + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build(), + Collection.builder() + .name("") + .description("tedious given quixotic") + .id(590805L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .items(List.of( + CollectionItem.builder() + .collectionId(913703L) + .itemType(CollectionItemItemType.COLLECTION) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build())) + .children(List.of( + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build(), + Collection.builder() + .name("") + .description("tedious given quixotic") + .id(590805L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .items(List.of( + CollectionItem.builder() + .collectionId(913703L) + .itemType(CollectionItemItemType.COLLECTION) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build())) + .children(List.of( + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("whoever vice reassuringly boo fess") + .id(953002L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build())) + .sourceDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .extractedQnA(ExtractedQnA.builder() + .questionResult(SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build()) + .build()) + .meeting(Meeting.builder() + .attendees(CalendarAttendees.builder() + .people(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .groupAttendees(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build())) + .build()) + .build()) + .collection(Collection.builder() + .name("") + .description("fortunate ha gazebo") + .id(437915L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .answerBoard(AnswerBoard.builder() + .name("") + .description("grouper amidst pulse fowl swine that following adolescent yippee celsius") + .id(751446L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .code(Code.builder() + .repoName("scio") + .fileName("README.md") + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .querySuggestions(QuerySuggestionList.builder() + .suggestions(List.of( + QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build())) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .relatedDocuments(List.of( + RelatedDocuments.builder() + .querySuggestion(QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build()) + .results(List.of( + SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build())) + .build(), + RelatedDocuments.builder() + .querySuggestion(QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build()) + .results(List.of( + SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build())) + .build(), + RelatedDocuments.builder() + .querySuggestion(QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build()) + .results(List.of( + SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build())) + .build())) + .relatedQuestion(RelatedQuestion.builder() + .ranges(List.of( + TextRange.builder() + .startIndex(913402L) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build(), + TextRange.builder() + .startIndex(913402L) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build(), + TextRange.builder() + .startIndex(913402L) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build())) + .build()) + .build()) + .build())) + .build()) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build(); + + CreateannouncementResponse res = sdk.client().announcements().create() + .request(req) + .call(); + + if (res.announcement().isPresent()) { + // handle response + } + } + } + /rest/api/v1/deleteannouncement: + post: + tags: + - Announcements + summary: Delete Announcement + description: Delete an existing user-generated announcement. + operationId: deleteannouncement + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteAnnouncementRequest" + description: Delete announcement request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: delete + x-speakeasy-group: client.announcements + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.client.announcements.delete(id=458809) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.client.announcements.delete({ + id: 458809, + }); + + + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Announcements.Delete(ctx, components.DeleteAnnouncementRequest{\n ID: 458809,\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DeleteAnnouncementRequest; + import com.glean.api_client.glean_api_client.models.operations.DeleteannouncementResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeleteAnnouncementRequest req = DeleteAnnouncementRequest.builder() + .id(458809L) + .build(); + + DeleteannouncementResponse res = sdk.client().announcements().delete() + .request(req) + .call(); + + // handle response + } + } + /rest/api/v1/updateannouncement: + post: + tags: + - Announcements + summary: Update Announcement + description: Update a textual announcement visible to some set of users based on department and location. + operationId: updateannouncement + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/UpdateAnnouncementRequest" + description: Announcement content. Id need to be specified for the announcement. + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/Announcement" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: update + x-speakeasy-group: client.announcements + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + from glean.api_client.utils import parse_datetime + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.announcements.update(start_time=parse_datetime("2023-10-24T01:53:24.440Z"), end_time=parse_datetime("2024-10-30T07:24:12.087Z"), title="", id=121004, body={ + "text": "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + "structured_list": [ + models.StructuredTextItem( + link="https://en.wikipedia.org/wiki/Diffuse_sky_radiation", + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + text="Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.", + structured_result=models.StructuredResult( + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + customer=models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + poc=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ], + merged_customers=[ + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + ], + notes="CIO is interested in trying out the product.", + ), + team=models.Team( + id="", + name="", + members=[ + models.PersonToTeamRelationship( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.PersonToTeamRelationship( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + custom_fields=[ + models.CustomFieldData( + label="", + values=[], + ), + models.CustomFieldData( + label="", + values=[], + ), + ], + datasource_profiles=[ + models.DatasourceProfile( + datasource="github", + handle="", + ), + models.DatasourceProfile( + datasource="github", + handle="", + ), + models.DatasourceProfile( + datasource="github", + handle="", + ), + ], + ), + custom_entity=models.CustomEntity( + roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + ], + ), + answer=models.Answer( + id=3, + doc_id="ANSWERS_answer_3", + question="Why is the sky blue?", + body_text="From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + added_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.OWNER, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.OWNER, + ), + ], + removed_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + ], + likes=models.AnswerLikes( + liked_by=[ + models.AnswerLike( + user=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + liked_by_user=True, + num_likes=38608, + ), + author=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + verification=models.Verification( + state=models.State.DEPRECATED, + metadata=models.VerificationMetadata( + last_verifier=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + reminders=[ + models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=735135, + ), + models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=735135, + ), + ], + last_reminder=models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=528697, + ), + candidate_verifiers=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ], + ), + ), + board=models.AnswerBoard( + name="", + description="treasure phrase meaty", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=355296, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + collections=[ + models.Collection( + name="", + description="thunderbolt acidly warmly hence zowie", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=416180, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + items=[ + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + ], + children=[ + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.Collection( + name="", + description="thunderbolt acidly warmly hence zowie", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=416180, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + items=[ + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + ], + children=[ + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + ], + source_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + extracted_qn_a=models.ExtractedQnA( + question_result=models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ), + meeting=models.Meeting( + attendees=models.CalendarAttendees( + people=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + group_attendees=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + group_attendees=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + ], + ), + ), + collection=models.Collection( + name="", + description="mismatch noisily jive worth meh following hmph analyse", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=5797, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + answer_board=models.AnswerBoard( + name="", + description="pulse yum shakily notwithstanding faithfully boohoo urgently exterior before um", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=609567, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + code=models.Code( + repo_name="scio", + file_name="README.md", + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + query_suggestions=models.QuerySuggestionList( + suggestions=[ + models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + ], + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + related_documents=[ + models.RelatedDocuments( + query_suggestion=models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + results=[ + models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ], + ), + ], + related_question=models.RelatedQuestion( + ranges=[ + models.TextRange( + start_index=896307, + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + models.TextRange( + start_index=896307, + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + ], + ), + ), + ), + models.StructuredTextItem( + link="https://en.wikipedia.org/wiki/Diffuse_sky_radiation", + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + text="Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.", + structured_result=models.StructuredResult( + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + customer=models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + poc=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ], + merged_customers=[ + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + ], + notes="CIO is interested in trying out the product.", + ), + team=models.Team( + id="", + name="", + members=[ + models.PersonToTeamRelationship( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.PersonToTeamRelationship( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + custom_fields=[ + models.CustomFieldData( + label="", + values=[], + ), + models.CustomFieldData( + label="", + values=[], + ), + ], + datasource_profiles=[ + models.DatasourceProfile( + datasource="github", + handle="", + ), + models.DatasourceProfile( + datasource="github", + handle="", + ), + models.DatasourceProfile( + datasource="github", + handle="", + ), + ], + ), + custom_entity=models.CustomEntity( + roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + ], + ), + answer=models.Answer( + id=3, + doc_id="ANSWERS_answer_3", + question="Why is the sky blue?", + body_text="From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + added_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.OWNER, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.OWNER, + ), + ], + removed_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + ], + likes=models.AnswerLikes( + liked_by=[ + models.AnswerLike( + user=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + liked_by_user=True, + num_likes=38608, + ), + author=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + verification=models.Verification( + state=models.State.DEPRECATED, + metadata=models.VerificationMetadata( + last_verifier=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + reminders=[ + models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=735135, + ), + models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=735135, + ), + ], + last_reminder=models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=528697, + ), + candidate_verifiers=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ], + ), + ), + board=models.AnswerBoard( + name="", + description="treasure phrase meaty", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=355296, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + collections=[ + models.Collection( + name="", + description="thunderbolt acidly warmly hence zowie", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=416180, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + items=[ + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + ], + children=[ + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.Collection( + name="", + description="thunderbolt acidly warmly hence zowie", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=416180, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + items=[ + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + ], + children=[ + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + ], + source_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + extracted_qn_a=models.ExtractedQnA( + question_result=models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ), + meeting=models.Meeting( + attendees=models.CalendarAttendees( + people=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + group_attendees=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + group_attendees=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + ], + ), + ), + collection=models.Collection( + name="", + description="mismatch noisily jive worth meh following hmph analyse", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=5797, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + answer_board=models.AnswerBoard( + name="", + description="pulse yum shakily notwithstanding faithfully boohoo urgently exterior before um", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=609567, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + code=models.Code( + repo_name="scio", + file_name="README.md", + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + query_suggestions=models.QuerySuggestionList( + suggestions=[ + models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + ], + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + related_documents=[ + models.RelatedDocuments( + query_suggestion=models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + results=[ + models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ], + ), + ], + related_question=models.RelatedQuestion( + ranges=[ + models.TextRange( + start_index=896307, + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + models.TextRange( + start_index=896307, + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + ], + ), + ), + ), + models.StructuredTextItem( + link="https://en.wikipedia.org/wiki/Diffuse_sky_radiation", + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + text="Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.", + structured_result=models.StructuredResult( + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + customer=models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + poc=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ], + merged_customers=[ + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + models.Customer( + id="", + company=models.Company( + name="", + location="New York City", + industry="Finances", + about="Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + ), + notes="CIO is interested in trying out the product.", + ), + ], + notes="CIO is interested in trying out the product.", + ), + team=models.Team( + id="", + name="", + members=[ + models.PersonToTeamRelationship( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.PersonToTeamRelationship( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + custom_fields=[ + models.CustomFieldData( + label="", + values=[], + ), + models.CustomFieldData( + label="", + values=[], + ), + ], + datasource_profiles=[ + models.DatasourceProfile( + datasource="github", + handle="", + ), + models.DatasourceProfile( + datasource="github", + handle="", + ), + models.DatasourceProfile( + datasource="github", + handle="", + ), + ], + ), + custom_entity=models.CustomEntity( + roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + ], + ), + answer=models.Answer( + id=3, + doc_id="ANSWERS_answer_3", + question="Why is the sky blue?", + body_text="From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + added_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.OWNER, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.OWNER, + ), + ], + removed_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + ], + likes=models.AnswerLikes( + liked_by=[ + models.AnswerLike( + user=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + liked_by_user=True, + num_likes=38608, + ), + author=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + verification=models.Verification( + state=models.State.DEPRECATED, + metadata=models.VerificationMetadata( + last_verifier=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + reminders=[ + models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=735135, + ), + models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=735135, + ), + ], + last_reminder=models.Reminder( + assignee=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + requestor=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + remind_at=528697, + ), + candidate_verifiers=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ], + ), + ), + board=models.AnswerBoard( + name="", + description="treasure phrase meaty", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=355296, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + collections=[ + models.Collection( + name="", + description="thunderbolt acidly warmly hence zowie", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=416180, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + items=[ + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + ], + children=[ + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.Collection( + name="", + description="thunderbolt acidly warmly hence zowie", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=416180, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + items=[ + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + models.CollectionItem( + collection_id=213025, + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + item_type=models.CollectionItemItemType.TEXT, + ), + ], + children=[ + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.Collection( + name="", + description="likewise blindly mooch travel pinion", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=184689, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + ], + source_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + extracted_qn_a=models.ExtractedQnA( + question_result=models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ), + meeting=models.Meeting( + attendees=models.CalendarAttendees( + people=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + group_attendees=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + group_attendees=[ + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + models.CalendarAttendee( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + ], + ), + ], + ), + ), + collection=models.Collection( + name="", + description="mismatch noisily jive worth meh following hmph analyse", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=5797, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + answer_board=models.AnswerBoard( + name="", + description="pulse yum shakily notwithstanding faithfully boohoo urgently exterior before um", + audience_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + id=609567, + creator=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + code=models.Code( + repo_name="scio", + file_name="README.md", + ), + shortcut=models.Shortcut( + input_alias="", + created_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + updated_by=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + destination_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + query_suggestions=models.QuerySuggestionList( + suggestions=[ + models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + ], + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ), + related_documents=[ + models.RelatedDocuments( + query_suggestion=models.QuerySuggestion( + query="app:github type:pull author:mortimer", + label="Mortimer's PRs", + datasource="github", + ), + results=[ + models.SearchResult( + title="title", + url="https://example.com/foo/bar", + native_app_url="slack://foo/bar", + snippets=[ + models.SearchResultSnippet( + snippet="snippet", + mime_type="mimeType", + ), + ], + must_include_suggestions=models.QuerySuggestionList(), + ), + ], + ), + ], + related_question=models.RelatedQuestion( + ranges=[ + models.TextRange( + start_index=896307, + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + models.TextRange( + start_index=896307, + document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + ], + ), + ), + ), + ], + }, audience_filters=[ + { + "field_name": "type", + "values": [ + { + "value": "Spreadsheet", + "relation_type": models.RelationType.EQUALS, + }, + { + "value": "Presentation", + "relation_type": models.RelationType.EQUALS, + }, + ], + }, + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.announcements.update({ + startTime: new Date("2023-10-24T01:53:24.440Z"), + endTime: new Date("2024-10-30T07:24:12.087Z"), + title: "", + body: { + text: "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + structuredList: [ + { + link: "https://en.wikipedia.org/wiki/Diffuse_sky_radiation", + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + text: "Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.", + structuredResult: { + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + customer: { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + poc: [ + { + name: "George Clooney", + obfuscatedId: "abc123", + }, + ], + mergedCustomers: [ + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + ], + notes: "CIO is interested in trying out the product.", + }, + team: { + id: "", + name: "", + members: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + customFields: [ + { + label: "", + values: [], + }, + { + label: "", + values: [], + }, + ], + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + ], + }, + customEntity: { + roles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + ], + }, + answer: { + id: 3, + docId: "ANSWERS_answer_3", + question: "Why is the sky blue?", + bodyText: "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + addedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "OWNER", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "OWNER", + }, + ], + removedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + ], + likes: { + likedBy: [ + { + user: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + likedByUser: true, + numLikes: 38608, + }, + author: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + verification: { + state: "DEPRECATED", + metadata: { + lastVerifier: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + reminders: [ + { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 735135, + }, + { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 735135, + }, + ], + lastReminder: { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 528697, + }, + candidateVerifiers: [ + { + name: "George Clooney", + obfuscatedId: "abc123", + }, + ], + }, + }, + board: { + name: "", + description: "treasure phrase meaty", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 355296, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + collections: [ + { + name: "", + description: "thunderbolt acidly warmly hence zowie", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 416180, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + items: [ + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + ], + children: [ + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + name: "", + description: "thunderbolt acidly warmly hence zowie", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 416180, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + items: [ + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + ], + children: [ + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + ], + sourceDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + extractedQnA: { + questionResult: { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + }, + meeting: { + attendees: { + people: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + groupAttendees: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + groupAttendees: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + ], + }, + }, + collection: { + name: "", + description: "mismatch noisily jive worth meh following hmph analyse", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 5797, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + answerBoard: { + name: "", + description: "pulse yum shakily notwithstanding faithfully boohoo urgently exterior before um", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 609567, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + code: { + repoName: "scio", + fileName: "README.md", + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + querySuggestions: { + suggestions: [ + { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + ], + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + relatedDocuments: [ + { + querySuggestion: { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + results: [ + { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + ], + }, + ], + relatedQuestion: { + ranges: [ + { + startIndex: 896307, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + { + startIndex: 896307, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + ], + }, + }, + }, + { + link: "https://en.wikipedia.org/wiki/Diffuse_sky_radiation", + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + text: "Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.", + structuredResult: { + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + customer: { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + poc: [ + { + name: "George Clooney", + obfuscatedId: "abc123", + }, + ], + mergedCustomers: [ + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + ], + notes: "CIO is interested in trying out the product.", + }, + team: { + id: "", + name: "", + members: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + customFields: [ + { + label: "", + values: [], + }, + { + label: "", + values: [], + }, + ], + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + ], + }, + customEntity: { + roles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + ], + }, + answer: { + id: 3, + docId: "ANSWERS_answer_3", + question: "Why is the sky blue?", + bodyText: "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + addedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "OWNER", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "OWNER", + }, + ], + removedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + ], + likes: { + likedBy: [ + { + user: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + likedByUser: true, + numLikes: 38608, + }, + author: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + verification: { + state: "DEPRECATED", + metadata: { + lastVerifier: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + reminders: [ + { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 735135, + }, + { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 735135, + }, + ], + lastReminder: { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 528697, + }, + candidateVerifiers: [ + { + name: "George Clooney", + obfuscatedId: "abc123", + }, + ], + }, + }, + board: { + name: "", + description: "treasure phrase meaty", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 355296, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + collections: [ + { + name: "", + description: "thunderbolt acidly warmly hence zowie", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 416180, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + items: [ + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + ], + children: [ + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + name: "", + description: "thunderbolt acidly warmly hence zowie", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 416180, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + items: [ + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + ], + children: [ + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + ], + sourceDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + extractedQnA: { + questionResult: { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + }, + meeting: { + attendees: { + people: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + groupAttendees: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + groupAttendees: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + ], + }, + }, + collection: { + name: "", + description: "mismatch noisily jive worth meh following hmph analyse", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 5797, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + answerBoard: { + name: "", + description: "pulse yum shakily notwithstanding faithfully boohoo urgently exterior before um", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 609567, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + code: { + repoName: "scio", + fileName: "README.md", + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + querySuggestions: { + suggestions: [ + { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + ], + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + relatedDocuments: [ + { + querySuggestion: { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + results: [ + { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + ], + }, + ], + relatedQuestion: { + ranges: [ + { + startIndex: 896307, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + { + startIndex: 896307, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + ], + }, + }, + }, + { + link: "https://en.wikipedia.org/wiki/Diffuse_sky_radiation", + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + text: "Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.", + structuredResult: { + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + customer: { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + poc: [ + { + name: "George Clooney", + obfuscatedId: "abc123", + }, + ], + mergedCustomers: [ + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + { + id: "", + company: { + name: "", + location: "New York City", + industry: "Finances", + about: "Financial, software, data, and media company headquartered in Midtown Manhattan, New York City", + }, + notes: "CIO is interested in trying out the product.", + }, + ], + notes: "CIO is interested in trying out the product.", + }, + team: { + id: "", + name: "", + members: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + customFields: [ + { + label: "", + values: [], + }, + { + label: "", + values: [], + }, + ], + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + ], + }, + customEntity: { + roles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + ], + }, + answer: { + id: 3, + docId: "ANSWERS_answer_3", + question: "Why is the sky blue?", + bodyText: "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + addedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "OWNER", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "OWNER", + }, + ], + removedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + ], + likes: { + likedBy: [ + { + user: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + likedByUser: true, + numLikes: 38608, + }, + author: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + verification: { + state: "DEPRECATED", + metadata: { + lastVerifier: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + reminders: [ + { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 735135, + }, + { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 735135, + }, + ], + lastReminder: { + assignee: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + requestor: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + remindAt: 528697, + }, + candidateVerifiers: [ + { + name: "George Clooney", + obfuscatedId: "abc123", + }, + ], + }, + }, + board: { + name: "", + description: "treasure phrase meaty", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 355296, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + collections: [ + { + name: "", + description: "thunderbolt acidly warmly hence zowie", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 416180, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + items: [ + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + ], + children: [ + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + name: "", + description: "thunderbolt acidly warmly hence zowie", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 416180, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + items: [ + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + { + collectionId: 213025, + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + itemType: "TEXT", + }, + ], + children: [ + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + name: "", + description: "likewise blindly mooch travel pinion", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 184689, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + ], + sourceDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + extractedQnA: { + questionResult: { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + }, + meeting: { + attendees: { + people: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + groupAttendees: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + groupAttendees: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + ], + }, + ], + }, + }, + collection: { + name: "", + description: "mismatch noisily jive worth meh following hmph analyse", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 5797, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + answerBoard: { + name: "", + description: "pulse yum shakily notwithstanding faithfully boohoo urgently exterior before um", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 609567, + creator: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + code: { + repoName: "scio", + fileName: "README.md", + }, + shortcut: { + inputAlias: "", + createdBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + updatedBy: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + destinationDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + querySuggestions: { + suggestions: [ + { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + ], + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + }, + relatedDocuments: [ + { + querySuggestion: { + query: "app:github type:pull author:mortimer", + label: "Mortimer's PRs", + datasource: "github", + }, + results: [ + { + title: "title", + url: "https://example.com/foo/bar", + nativeAppUrl: "slack://foo/bar", + snippets: [ + { + snippet: "snippet", + mimeType: "mimeType", + }, + ], + mustIncludeSuggestions: {}, + }, + ], + }, + ], + relatedQuestion: { + ranges: [ + { + startIndex: 896307, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + { + startIndex: 896307, + document: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + ], + }, + }, + }, + ], + }, + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 121004, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/types\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Announcements.Update(ctx, components.UpdateAnnouncementRequest{\n StartTime: types.MustTimeFromString(\"2023-10-24T01:53:24.440Z\"),\n EndTime: types.MustTimeFromString(\"2024-10-30T07:24:12.087Z\"),\n Title: \"\",\n Body: &components.StructuredText{\n Text: \"From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.\",\n StructuredList: []components.StructuredTextItem{\n components.StructuredTextItem{\n Link: apiclientgo.String(\"https://en.wikipedia.org/wiki/Diffuse_sky_radiation\"),\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Text: apiclientgo.String(\"Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.\"),\n StructuredResult: &components.StructuredResult{\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Customer: &components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Poc: []components.Person{\n components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n MergedCustomers: []components.Customer{\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n Team: &components.Team{\n ID: \"\",\n Name: \"\",\n Members: []components.PersonToTeamRelationship{\n components.PersonToTeamRelationship{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.PersonToTeamRelationship{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n CustomFields: []components.CustomFieldData{\n components.CustomFieldData{\n Label: \"\",\n Values: []components.CustomFieldValue{},\n },\n components.CustomFieldData{\n Label: \"\",\n Values: []components.CustomFieldValue{},\n },\n },\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n },\n CustomEntity: &components.CustomEntity{\n Roles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n },\n },\n Answer: &components.Answer{\n ID: 3,\n DocID: apiclientgo.String(\"ANSWERS_answer_3\"),\n Question: apiclientgo.String(\"Why is the sky blue?\"),\n BodyText: apiclientgo.String(\"From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.\"),\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n AddedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleOwner,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleOwner,\n },\n },\n RemovedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n },\n Likes: &components.AnswerLikes{\n LikedBy: []components.AnswerLike{\n components.AnswerLike{\n User: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n LikedByUser: true,\n NumLikes: 38608,\n },\n Author: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Verification: &components.Verification{\n State: components.StateDeprecated,\n Metadata: &components.VerificationMetadata{\n LastVerifier: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Reminders: []components.Reminder{\n components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 735135,\n },\n components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 735135,\n },\n },\n LastReminder: &components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 528697,\n },\n CandidateVerifiers: []components.Person{\n components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n Board: &components.AnswerBoard{\n Name: \"\",\n Description: \"treasure phrase meaty\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 355296,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n Collections: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"thunderbolt acidly warmly hence zowie\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 416180,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Items: []components.CollectionItem{\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n },\n Children: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"thunderbolt acidly warmly hence zowie\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 416180,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Items: []components.CollectionItem{\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n },\n Children: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n },\n SourceDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ExtractedQnA: &components.ExtractedQnA{\n QuestionResult: &components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n Meeting: &components.Meeting{\n Attendees: &components.CalendarAttendees{\n People: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n GroupAttendees: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n GroupAttendees: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n },\n },\n },\n Collection: &components.Collection{\n Name: \"\",\n Description: \"mismatch noisily jive worth meh following hmph analyse\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 5797,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n AnswerBoard: &components.AnswerBoard{\n Name: \"\",\n Description: \"pulse yum shakily notwithstanding faithfully boohoo urgently exterior before um\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 609567,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n Code: &components.Code{\n RepoName: apiclientgo.String(\"scio\"),\n FileName: apiclientgo.String(\"README.md\"),\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n QuerySuggestions: &components.QuerySuggestionList{\n Suggestions: []components.QuerySuggestion{\n components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n },\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n RelatedDocuments: []components.RelatedDocuments{\n components.RelatedDocuments{\n QuerySuggestion: &components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n Results: []components.SearchResult{\n components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n },\n },\n RelatedQuestion: &components.RelatedQuestion{\n Ranges: []components.TextRange{\n components.TextRange{\n StartIndex: 896307,\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n components.TextRange{\n StartIndex: 896307,\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n },\n },\n },\n },\n components.StructuredTextItem{\n Link: apiclientgo.String(\"https://en.wikipedia.org/wiki/Diffuse_sky_radiation\"),\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Text: apiclientgo.String(\"Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.\"),\n StructuredResult: &components.StructuredResult{\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Customer: &components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Poc: []components.Person{\n components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n MergedCustomers: []components.Customer{\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n Team: &components.Team{\n ID: \"\",\n Name: \"\",\n Members: []components.PersonToTeamRelationship{\n components.PersonToTeamRelationship{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.PersonToTeamRelationship{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n CustomFields: []components.CustomFieldData{\n components.CustomFieldData{\n Label: \"\",\n Values: []components.CustomFieldValue{},\n },\n components.CustomFieldData{\n Label: \"\",\n Values: []components.CustomFieldValue{},\n },\n },\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n },\n CustomEntity: &components.CustomEntity{\n Roles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n },\n },\n Answer: &components.Answer{\n ID: 3,\n DocID: apiclientgo.String(\"ANSWERS_answer_3\"),\n Question: apiclientgo.String(\"Why is the sky blue?\"),\n BodyText: apiclientgo.String(\"From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.\"),\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n AddedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleOwner,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleOwner,\n },\n },\n RemovedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n },\n Likes: &components.AnswerLikes{\n LikedBy: []components.AnswerLike{\n components.AnswerLike{\n User: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n LikedByUser: true,\n NumLikes: 38608,\n },\n Author: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Verification: &components.Verification{\n State: components.StateDeprecated,\n Metadata: &components.VerificationMetadata{\n LastVerifier: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Reminders: []components.Reminder{\n components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 735135,\n },\n components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 735135,\n },\n },\n LastReminder: &components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 528697,\n },\n CandidateVerifiers: []components.Person{\n components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n Board: &components.AnswerBoard{\n Name: \"\",\n Description: \"treasure phrase meaty\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 355296,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n Collections: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"thunderbolt acidly warmly hence zowie\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 416180,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Items: []components.CollectionItem{\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n },\n Children: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"thunderbolt acidly warmly hence zowie\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 416180,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Items: []components.CollectionItem{\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n },\n Children: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n },\n SourceDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ExtractedQnA: &components.ExtractedQnA{\n QuestionResult: &components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n Meeting: &components.Meeting{\n Attendees: &components.CalendarAttendees{\n People: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n GroupAttendees: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n GroupAttendees: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n },\n },\n },\n Collection: &components.Collection{\n Name: \"\",\n Description: \"mismatch noisily jive worth meh following hmph analyse\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 5797,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n AnswerBoard: &components.AnswerBoard{\n Name: \"\",\n Description: \"pulse yum shakily notwithstanding faithfully boohoo urgently exterior before um\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 609567,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n Code: &components.Code{\n RepoName: apiclientgo.String(\"scio\"),\n FileName: apiclientgo.String(\"README.md\"),\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n QuerySuggestions: &components.QuerySuggestionList{\n Suggestions: []components.QuerySuggestion{\n components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n },\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n RelatedDocuments: []components.RelatedDocuments{\n components.RelatedDocuments{\n QuerySuggestion: &components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n Results: []components.SearchResult{\n components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n },\n },\n RelatedQuestion: &components.RelatedQuestion{\n Ranges: []components.TextRange{\n components.TextRange{\n StartIndex: 896307,\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n components.TextRange{\n StartIndex: 896307,\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n },\n },\n },\n },\n components.StructuredTextItem{\n Link: apiclientgo.String(\"https://en.wikipedia.org/wiki/Diffuse_sky_radiation\"),\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Text: apiclientgo.String(\"Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.\"),\n StructuredResult: &components.StructuredResult{\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Customer: &components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Poc: []components.Person{\n components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n MergedCustomers: []components.Customer{\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n components.Customer{\n ID: \"\",\n Company: components.Company{\n Name: \"\",\n Location: apiclientgo.String(\"New York City\"),\n Industry: apiclientgo.String(\"Finances\"),\n About: apiclientgo.String(\"Financial, software, data, and media company headquartered in Midtown Manhattan, New York City\"),\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n },\n Notes: apiclientgo.String(\"CIO is interested in trying out the product.\"),\n },\n Team: &components.Team{\n ID: \"\",\n Name: \"\",\n Members: []components.PersonToTeamRelationship{\n components.PersonToTeamRelationship{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.PersonToTeamRelationship{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n CustomFields: []components.CustomFieldData{\n components.CustomFieldData{\n Label: \"\",\n Values: []components.CustomFieldValue{},\n },\n components.CustomFieldData{\n Label: \"\",\n Values: []components.CustomFieldValue{},\n },\n },\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n },\n CustomEntity: &components.CustomEntity{\n Roles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n },\n },\n Answer: &components.Answer{\n ID: 3,\n DocID: apiclientgo.String(\"ANSWERS_answer_3\"),\n Question: apiclientgo.String(\"Why is the sky blue?\"),\n BodyText: apiclientgo.String(\"From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.\"),\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n AddedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleOwner,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleOwner,\n },\n },\n RemovedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n },\n Likes: &components.AnswerLikes{\n LikedBy: []components.AnswerLike{\n components.AnswerLike{\n User: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n LikedByUser: true,\n NumLikes: 38608,\n },\n Author: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Verification: &components.Verification{\n State: components.StateDeprecated,\n Metadata: &components.VerificationMetadata{\n LastVerifier: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Reminders: []components.Reminder{\n components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 735135,\n },\n components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 735135,\n },\n },\n LastReminder: &components.Reminder{\n Assignee: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Requestor: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n RemindAt: 528697,\n },\n CandidateVerifiers: []components.Person{\n components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n Board: &components.AnswerBoard{\n Name: \"\",\n Description: \"treasure phrase meaty\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 355296,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n Collections: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"thunderbolt acidly warmly hence zowie\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 416180,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Items: []components.CollectionItem{\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n },\n Children: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"thunderbolt acidly warmly hence zowie\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 416180,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Items: []components.CollectionItem{\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n components.CollectionItem{\n CollectionID: 213025,\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ItemType: components.CollectionItemItemTypeText,\n },\n },\n Children: []components.Collection{\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.Collection{\n Name: \"\",\n Description: \"likewise blindly mooch travel pinion\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 184689,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n },\n SourceDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n ExtractedQnA: &components.ExtractedQnA{\n QuestionResult: &components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n Meeting: &components.Meeting{\n Attendees: &components.CalendarAttendees{\n People: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n GroupAttendees: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n GroupAttendees: []components.CalendarAttendee{\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n components.CalendarAttendee{\n Person: components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n },\n },\n },\n },\n },\n Collection: &components.Collection{\n Name: \"\",\n Description: \"mismatch noisily jive worth meh following hmph analyse\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 5797,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n AnswerBoard: &components.AnswerBoard{\n Name: \"\",\n Description: \"pulse yum shakily notwithstanding faithfully boohoo urgently exterior before um\",\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 609567,\n Creator: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n Code: &components.Code{\n RepoName: apiclientgo.String(\"scio\"),\n FileName: apiclientgo.String(\"README.md\"),\n },\n Shortcut: &components.Shortcut{\n InputAlias: \"\",\n CreatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n UpdatedBy: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n DestinationDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n QuerySuggestions: &components.QuerySuggestionList{\n Suggestions: []components.QuerySuggestion{\n components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n },\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n },\n RelatedDocuments: []components.RelatedDocuments{\n components.RelatedDocuments{\n QuerySuggestion: &components.QuerySuggestion{\n Query: \"app:github type:pull author:mortimer\",\n Label: apiclientgo.String(\"Mortimer's PRs\"),\n Datasource: apiclientgo.String(\"github\"),\n },\n Results: []components.SearchResult{\n components.SearchResult{\n Title: apiclientgo.String(\"title\"),\n URL: \"https://example.com/foo/bar\",\n NativeAppURL: apiclientgo.String(\"slack://foo/bar\"),\n Snippets: []components.SearchResultSnippet{\n components.SearchResultSnippet{\n Snippet: \"snippet\",\n MimeType: apiclientgo.String(\"mimeType\"),\n },\n },\n MustIncludeSuggestions: &components.QuerySuggestionList{},\n },\n },\n },\n },\n RelatedQuestion: &components.RelatedQuestion{\n Ranges: []components.TextRange{\n components.TextRange{\n StartIndex: 896307,\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n components.TextRange{\n StartIndex: 896307,\n Document: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n },\n },\n },\n },\n },\n },\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 121004,\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.Announcement != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.UpdateannouncementResponse; + import java.lang.Exception; + import java.time.OffsetDateTime; + import java.util.List; + import java.util.Map; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + UpdateAnnouncementRequest req = UpdateAnnouncementRequest.builder() + .startTime(OffsetDateTime.parse("2023-10-24T01:53:24.440Z")) + .endTime(OffsetDateTime.parse("2024-10-30T07:24:12.087Z")) + .title("") + .id(121004L) + .body(StructuredText.builder() + .text("From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.") + .structuredList(List.of( + StructuredTextItem.builder() + .link("https://en.wikipedia.org/wiki/Diffuse_sky_radiation") + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .text("Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.") + .structuredResult(StructuredResult.builder() + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .customer(Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .poc(List.of( + Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build())) + .mergedCustomers(List.of( + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build(), + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build(), + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build())) + .notes("CIO is interested in trying out the product.") + .build()) + .team(Team.builder() + .id("") + .name("") + .members(List.of( + PersonToTeamRelationship.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + PersonToTeamRelationship.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .customFields(List.of( + CustomFieldData.builder() + .label("") + .values(List.of()) + .build(), + CustomFieldData.builder() + .label("") + .values(List.of()) + .build())) + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build()) + .customEntity(CustomEntity.builder() + .roles(List.of( + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build()) + .answer(Answer.builder() + .id(3L) + .docId("ANSWERS_answer_3") + .question("Why is the sky blue?") + .bodyText("From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.") + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .addedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.OWNER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.OWNER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .removedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .likes(AnswerLikes.builder() + .likedBy(List.of( + AnswerLike.builder() + .user(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .likedByUser(true) + .numLikes(38608L) + .build()) + .author(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .verification(Verification.builder() + .state(State.DEPRECATED) + .metadata(VerificationMetadata.builder() + .lastVerifier(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .reminders(List.of( + Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(735135L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(735135L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .lastReminder(Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(528697L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .candidateVerifiers(List.of( + Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build())) + .build()) + .build()) + .board(AnswerBoard.builder() + .name("") + .description("treasure phrase meaty") + .id(355296L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .collections(List.of( + Collection.builder() + .name("") + .description("thunderbolt acidly warmly hence zowie") + .id(416180L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .items(List.of( + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(), + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(), + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build())) + .children(List.of( + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build(), + Collection.builder() + .name("") + .description("thunderbolt acidly warmly hence zowie") + .id(416180L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .items(List.of( + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(), + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(), + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build())) + .children(List.of( + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build())) + .sourceDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .extractedQnA(ExtractedQnA.builder() + .questionResult(SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build()) + .build()) + .meeting(Meeting.builder() + .attendees(CalendarAttendees.builder() + .people(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .groupAttendees(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build(), + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .groupAttendees(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build())) + .build()) + .build()) + .collection(Collection.builder() + .name("") + .description("mismatch noisily jive worth meh following hmph analyse") + .id(5797L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .answerBoard(AnswerBoard.builder() + .name("") + .description("pulse yum shakily notwithstanding faithfully boohoo urgently exterior before um") + .id(609567L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .code(Code.builder() + .repoName("scio") + .fileName("README.md") + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .querySuggestions(QuerySuggestionList.builder() + .suggestions(List.of( + QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build())) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .relatedDocuments(List.of( + RelatedDocuments.builder() + .querySuggestion(QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build()) + .results(List.of( + SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build())) + .build())) + .relatedQuestion(RelatedQuestion.builder() + .ranges(List.of( + TextRange.builder() + .startIndex(896307L) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build(), + TextRange.builder() + .startIndex(896307L) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build())) + .build()) + .build()) + .build(), + StructuredTextItem.builder() + .link("https://en.wikipedia.org/wiki/Diffuse_sky_radiation") + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .text("Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.") + .structuredResult(StructuredResult.builder() + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .customer(Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .poc(List.of( + Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build())) + .mergedCustomers(List.of( + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build(), + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build(), + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build())) + .notes("CIO is interested in trying out the product.") + .build()) + .team(Team.builder() + .id("") + .name("") + .members(List.of( + PersonToTeamRelationship.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + PersonToTeamRelationship.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .customFields(List.of( + CustomFieldData.builder() + .label("") + .values(List.of()) + .build(), + CustomFieldData.builder() + .label("") + .values(List.of()) + .build())) + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build()) + .customEntity(CustomEntity.builder() + .roles(List.of( + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build()) + .answer(Answer.builder() + .id(3L) + .docId("ANSWERS_answer_3") + .question("Why is the sky blue?") + .bodyText("From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.") + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .addedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.OWNER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.OWNER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .removedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .likes(AnswerLikes.builder() + .likedBy(List.of( + AnswerLike.builder() + .user(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .likedByUser(true) + .numLikes(38608L) + .build()) + .author(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .verification(Verification.builder() + .state(State.DEPRECATED) + .metadata(VerificationMetadata.builder() + .lastVerifier(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .reminders(List.of( + Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(735135L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(735135L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .lastReminder(Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(528697L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .candidateVerifiers(List.of( + Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build())) + .build()) + .build()) + .board(AnswerBoard.builder() + .name("") + .description("treasure phrase meaty") + .id(355296L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .collections(List.of( + Collection.builder() + .name("") + .description("thunderbolt acidly warmly hence zowie") + .id(416180L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .items(List.of( + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(), + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(), + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build())) + .children(List.of( + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build(), + Collection.builder() + .name("") + .description("thunderbolt acidly warmly hence zowie") + .id(416180L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .items(List.of( + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(), + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(), + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build())) + .children(List.of( + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build())) + .sourceDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .extractedQnA(ExtractedQnA.builder() + .questionResult(SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build()) + .build()) + .meeting(Meeting.builder() + .attendees(CalendarAttendees.builder() + .people(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .groupAttendees(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build(), + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .groupAttendees(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build())) + .build()) + .build()) + .collection(Collection.builder() + .name("") + .description("mismatch noisily jive worth meh following hmph analyse") + .id(5797L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .answerBoard(AnswerBoard.builder() + .name("") + .description("pulse yum shakily notwithstanding faithfully boohoo urgently exterior before um") + .id(609567L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .code(Code.builder() + .repoName("scio") + .fileName("README.md") + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .querySuggestions(QuerySuggestionList.builder() + .suggestions(List.of( + QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build())) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .relatedDocuments(List.of( + RelatedDocuments.builder() + .querySuggestion(QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build()) + .results(List.of( + SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build())) + .build())) + .relatedQuestion(RelatedQuestion.builder() + .ranges(List.of( + TextRange.builder() + .startIndex(896307L) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build(), + TextRange.builder() + .startIndex(896307L) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build())) + .build()) + .build()) + .build(), + StructuredTextItem.builder() + .link("https://en.wikipedia.org/wiki/Diffuse_sky_radiation") + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .text("Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue.") + .structuredResult(StructuredResult.builder() + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .customer(Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .poc(List.of( + Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build())) + .mergedCustomers(List.of( + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build(), + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build(), + Customer.builder() + .id("") + .company(Company.builder() + .name("") + .location("New York City") + .industry("Finances") + .about("Financial, software, data, and media company headquartered in Midtown Manhattan, New York City") + .build()) + .notes("CIO is interested in trying out the product.") + .build())) + .notes("CIO is interested in trying out the product.") + .build()) + .team(Team.builder() + .id("") + .name("") + .members(List.of( + PersonToTeamRelationship.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + PersonToTeamRelationship.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .customFields(List.of( + CustomFieldData.builder() + .label("") + .values(List.of()) + .build(), + CustomFieldData.builder() + .label("") + .values(List.of()) + .build())) + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build()) + .customEntity(CustomEntity.builder() + .roles(List.of( + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build()) + .answer(Answer.builder() + .id(3L) + .docId("ANSWERS_answer_3") + .question("Why is the sky blue?") + .bodyText("From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.") + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .addedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.OWNER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.OWNER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .removedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .likes(AnswerLikes.builder() + .likedBy(List.of( + AnswerLike.builder() + .user(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .likedByUser(true) + .numLikes(38608L) + .build()) + .author(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .verification(Verification.builder() + .state(State.DEPRECATED) + .metadata(VerificationMetadata.builder() + .lastVerifier(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .reminders(List.of( + Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(735135L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(735135L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .lastReminder(Reminder.builder() + .assignee(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .remindAt(528697L) + .requestor(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .candidateVerifiers(List.of( + Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build())) + .build()) + .build()) + .board(AnswerBoard.builder() + .name("") + .description("treasure phrase meaty") + .id(355296L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .collections(List.of( + Collection.builder() + .name("") + .description("thunderbolt acidly warmly hence zowie") + .id(416180L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .items(List.of( + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(), + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(), + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build())) + .children(List.of( + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build(), + Collection.builder() + .name("") + .description("thunderbolt acidly warmly hence zowie") + .id(416180L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .items(List.of( + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(), + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(), + CollectionItem.builder() + .collectionId(213025L) + .itemType(CollectionItemItemType.TEXT) + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build())) + .children(List.of( + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + Collection.builder() + .name("") + .description("likewise blindly mooch travel pinion") + .id(184689L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build())) + .sourceDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .extractedQnA(ExtractedQnA.builder() + .questionResult(SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build()) + .build()) + .meeting(Meeting.builder() + .attendees(CalendarAttendees.builder() + .people(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .groupAttendees(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build(), + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .groupAttendees(List.of( + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + CalendarAttendee.builder() + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build())) + .build()) + .build()) + .collection(Collection.builder() + .name("") + .description("mismatch noisily jive worth meh following hmph analyse") + .id(5797L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .answerBoard(AnswerBoard.builder() + .name("") + .description("pulse yum shakily notwithstanding faithfully boohoo urgently exterior before um") + .id(609567L) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .creator(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .code(Code.builder() + .repoName("scio") + .fileName("README.md") + .build()) + .shortcut(Shortcut.builder() + .inputAlias("") + .createdBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .updatedBy(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .destinationDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .querySuggestions(QuerySuggestionList.builder() + .suggestions(List.of( + QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build())) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build()) + .relatedDocuments(List.of( + RelatedDocuments.builder() + .querySuggestion(QuerySuggestion.builder() + .query("app:github type:pull author:mortimer") + .label("Mortimer's PRs") + .datasource("github") + .build()) + .results(List.of( + SearchResult.builder() + .url("https://example.com/foo/bar") + .title("title") + .nativeAppUrl("slack://foo/bar") + .snippets(List.of( + SearchResultSnippet.builder() + .snippet("snippet") + .mimeType("mimeType") + .build())) + .mustIncludeSuggestions(QuerySuggestionList.builder() + .build()) + .build())) + .build())) + .relatedQuestion(RelatedQuestion.builder() + .ranges(List.of( + TextRange.builder() + .startIndex(896307L) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build(), + TextRange.builder() + .startIndex(896307L) + .document(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build())) + .build()) + .build()) + .build())) + .build()) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build(); + + UpdateannouncementResponse res = sdk.client().announcements().update() + .request(req) + .call(); + + if (res.announcement().isPresent()) { + // handle response + } + } + } + /rest/api/v1/createanswer: + post: + tags: + - Answers + summary: Create Answer + description: Create a user-generated Answer that contains a question and answer. + operationId: createanswer + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CreateAnswerRequest" + description: CreateAnswer request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/Answer" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: create + x-speakeasy-group: client.answers + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.answers.create(data={ + "question": "Why is the sky blue?", + "body_text": "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + "audience_filters": [ + { + "field_name": "type", + "values": [ + { + "value": "Spreadsheet", + "relation_type": models.RelationType.EQUALS, + }, + { + "value": "Presentation", + "relation_type": models.RelationType.EQUALS, + }, + ], + }, + ], + "added_roles": [ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + ], + "removed_roles": [ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + ], + "roles": [ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VERIFIER, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VERIFIER, + ), + ], + "combined_answer_text": { + "text": "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + }, + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.answers.create({ + data: { + question: "Why is the sky blue?", + bodyText: "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + addedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + ], + removedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + ], + roles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VERIFIER", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VERIFIER", + }, + ], + combinedAnswerText: { + text: "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + }, + }, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Answers.Create(ctx, components.CreateAnswerRequest{\n Data: components.AnswerCreationData{\n Question: apiclientgo.String(\"Why is the sky blue?\"),\n BodyText: apiclientgo.String(\"From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.\"),\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n AddedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n },\n RemovedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n },\n Roles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleVerifier,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleVerifier,\n },\n },\n CombinedAnswerText: &components.StructuredTextMutableProperties{\n Text: \"From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.\",\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.Answer != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.CreateanswerResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + CreateAnswerRequest req = CreateAnswerRequest.builder() + .data(AnswerCreationData.builder() + .question("Why is the sky blue?") + .bodyText("From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.") + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .addedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .removedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .roles(List.of( + UserRoleSpecification.builder() + .role(UserRole.VERIFIER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.VERIFIER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .combinedAnswerText(StructuredTextMutableProperties.builder() + .text("From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.") + .build()) + .build()) + .build(); + + CreateanswerResponse res = sdk.client().answers().create() + .request(req) + .call(); + + if (res.answer().isPresent()) { + // handle response + } + } + } + /rest/api/v1/deleteanswer: + post: + tags: + - Answers + summary: Delete Answer + description: Delete an existing user-generated Answer. + operationId: deleteanswer + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteAnswerRequest" + description: DeleteAnswer request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: delete + x-speakeasy-group: client.answers + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.client.answers.delete(id=3, doc_id="ANSWERS_answer_3") + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.client.answers.delete({ + id: 3, + docId: "ANSWERS_answer_3", + }); + + + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Answers.Delete(ctx, components.DeleteAnswerRequest{\n ID: 3,\n DocID: apiclientgo.String(\"ANSWERS_answer_3\"),\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DeleteAnswerRequest; + import com.glean.api_client.glean_api_client.models.operations.DeleteanswerResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeleteAnswerRequest req = DeleteAnswerRequest.builder() + .id(3L) + .docId("ANSWERS_answer_3") + .build(); + + DeleteanswerResponse res = sdk.client().answers().delete() + .request(req) + .call(); + + // handle response + } + } + /rest/api/v1/editanswer: + post: + tags: + - Answers + summary: Update Answer + description: Update an existing user-generated Answer. + operationId: editanswer + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/EditAnswerRequest" + description: EditAnswer request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/Answer" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: update + x-speakeasy-group: client.answers + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.answers.update(id=3, doc_id="ANSWERS_answer_3", question="Why is the sky blue?", body_text="From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", audience_filters=[ + { + "field_name": "type", + "values": [ + { + "value": "Spreadsheet", + "relation_type": models.RelationType.EQUALS, + }, + { + "value": "Presentation", + "relation_type": models.RelationType.EQUALS, + }, + ], + }, + ], added_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.OWNER, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.OWNER, + ), + ], removed_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + ], roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.OWNER, + ), + ], combined_answer_text={ + "text": "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.answers.update({ + id: 3, + docId: "ANSWERS_answer_3", + question: "Why is the sky blue?", + bodyText: "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + addedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "OWNER", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "OWNER", + }, + ], + removedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + ], + roles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "OWNER", + }, + ], + combinedAnswerText: { + text: "From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.", + }, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Answers.Update(ctx, components.EditAnswerRequest{\n ID: 3,\n DocID: apiclientgo.String(\"ANSWERS_answer_3\"),\n Question: apiclientgo.String(\"Why is the sky blue?\"),\n BodyText: apiclientgo.String(\"From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.\"),\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n AddedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleOwner,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleOwner,\n },\n },\n RemovedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n },\n Roles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleOwner,\n },\n },\n CombinedAnswerText: &components.StructuredTextMutableProperties{\n Text: \"From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.\",\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.Answer != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.EditanswerResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + EditAnswerRequest req = EditAnswerRequest.builder() + .id(3L) + .docId("ANSWERS_answer_3") + .question("Why is the sky blue?") + .bodyText("From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.") + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .addedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.OWNER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.OWNER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .removedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .roles(List.of( + UserRoleSpecification.builder() + .role(UserRole.OWNER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .combinedAnswerText(StructuredTextMutableProperties.builder() + .text("From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light.") + .build()) + .build(); + + EditanswerResponse res = sdk.client().answers().update() + .request(req) + .call(); + + if (res.answer().isPresent()) { + // handle response + } + } + } + /rest/api/v1/getanswer: + post: + tags: + - Answers + summary: Read Answer + description: Read the details of a particular Answer given its ID. + operationId: getanswer + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetAnswerRequest" + description: GetAnswer request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetAnswerResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.answers + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.answers.retrieve(request={ + "id": 3, + "doc_id": "ANSWERS_answer_3", + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.answers.retrieve({ + id: 3, + docId: "ANSWERS_answer_3", + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Answers.Retrieve(ctx, components.GetAnswerRequest{\n ID: apiclientgo.Int64(3),\n DocID: apiclientgo.String(\"ANSWERS_answer_3\"),\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.GetAnswerResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.GetAnswerRequest; + import com.glean.api_client.glean_api_client.models.operations.GetanswerResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetAnswerRequest req = GetAnswerRequest.builder() + .id(3L) + .docId("ANSWERS_answer_3") + .build(); + + GetanswerResponse res = sdk.client().answers().retrieve() + .request(req) + .call(); + + if (res.getAnswerResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/listanswers: + post: + tags: + - Answers + summary: List Answers + description: List Answers created by the current user. + operationId: listanswers + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/ListAnswersRequest" + description: ListAnswers request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/ListAnswersResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: list + x-speakeasy-group: client.answers + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.answers.list() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.answers.list({}); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Answers.List(ctx, components.ListAnswersRequest{})\n if err != nil {\n log.Fatal(err)\n }\n if res.ListAnswersResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.ListAnswersRequest; + import com.glean.api_client.glean_api_client.models.operations.ListanswersResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ListAnswersRequest req = ListAnswersRequest.builder() + .build(); + + ListanswersResponse res = sdk.client().answers().list() + .request(req) + .call(); + + if (res.listAnswersResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/createauthtoken: + post: + tags: + - Authentication + summary: Create authentication token + description: Creates an authentication token for the authenticated user. + operationId: createauthtoken + x-visibility: Public + parameters: [] + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/CreateAuthTokenResponse" + "400": + description: Invalid Request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: createToken + x-speakeasy-group: client.authentication + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.authentication.create_token() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.authentication.createToken(); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Authentication.CreateToken(ctx)\n if err != nil {\n log.Fatal(err)\n }\n if res.CreateAuthTokenResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.CreateauthtokenResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + CreateauthtokenResponse res = sdk.client().authentication().createToken() + .call(); + + if (res.createAuthTokenResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/chat: + post: + tags: + - Chat + summary: Chat + description: Have a conversation with Glean AI. + operationId: chat + x-visibility: Public + x-codegen-request-body-name: payload + parameters: + - $ref: "#/components/parameters/timezoneOffset" + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/ChatRequest" + examples: + defaultExample: + value: + messages: + - author: USER + messageType: CONTENT + fragments: + - text: What are the company holidays this year? + gptAgentExample: + value: + agentConfig: + agent: GPT + messages: + - author: USER + messageType: CONTENT + fragments: + - text: Who was the first person to land on the moon? + description: Includes chat history for Glean AI to respond to. + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/ChatResponse" + examples: + defaultExample: + value: + messages: + - author: GLEAN_AI + messageType: CONTENT + hasMoreFragments: false + agentConfig: + agent: DEFAULT + mode: DEFAULT + fragments: + - text: There are no holidays! + streamingExample: + value: + messages: + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: true + fragments: null + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: true + fragments: null + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: true + fragments: + - text: e are + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: true + fragments: + - text: no hol + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: false + fragments: + - text: idays! + updateResponse: + value: + messages: + - author: GLEAN_AI + messageType: UPDATE + agentConfig: + agent: DEFAULT + mode: DEFAULT + fragments: + - text: "**Reading:**" + - structuredResults: + - document: + id: "123" + title: Company Handbook + citationResponse: + value: + messages: + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + citations: + - sourceDocument: + id: "123" + title: Company Handbook + referenceRanges: + - textRange: + startIndex: 0 + endIndex: 12 + type: CITATION + "400": + description: Invalid request + "401": + description: Not Authorized + "408": + description: Request Timeout + "429": + description: Too Many Requests + x-speakeasy-group: client.chat + x-speakeasy-name-override: create + x-speakeasy-usage-example: true + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.chat.create(messages=[ + { + "fragments": [ + models.ChatMessageFragment( + text="What are the company holidays this year?", + ), + ], + }, + ], timeout_millis=30000) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.chat.create({ + messages: [ + { + fragments: [ + { + text: "What are the company holidays this year?", + }, + ], + }, + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Chat.Create(ctx, components.ChatRequest{\n Messages: []components.ChatMessage{\n components.ChatMessage{\n Fragments: []components.ChatMessageFragment{\n components.ChatMessageFragment{\n Text: apiclientgo.String(\"What are the company holidays this year?\"),\n },\n },\n },\n },\n }, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.ChatResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.ChatResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ChatResponse res = sdk.client().chat().create() + .chatRequest(ChatRequest.builder() + .messages(List.of( + ChatMessage.builder() + .fragments(List.of( + ChatMessageFragment.builder() + .text("What are the company holidays this year?") + .build())) + .build())) + .build()) + .call(); + + if (res.chatResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/deleteallchats: + post: + tags: + - Chat + summary: Deletes all saved Chats owned by a user + description: Deletes all saved Chats a user has had and all their contained conversational content. + operationId: deleteallchats + x-visibility: Public + x-codegen-request-body-name: payload + parameters: + - $ref: "#/components/parameters/timezoneOffset" + responses: + "200": + description: OK + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Forbidden + x-speakeasy-name-override: deleteAll + x-speakeasy-group: client.chat + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.client.chat.delete_all() + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.client.chat.deleteAll(); + + + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Chat.DeleteAll(ctx, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.DeleteallchatsResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeleteallchatsResponse res = sdk.client().chat().deleteAll() + .call(); + + // handle response + } + } + /rest/api/v1/deletechats: + post: + tags: + - Chat + summary: Deletes saved Chats + description: Deletes saved Chats and all their contained conversational content. + operationId: deletechats + x-visibility: Public + x-codegen-request-body-name: payload + parameters: + - $ref: "#/components/parameters/timezoneOffset" + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteChatsRequest" + required: true + x-exportParamName: Request + responses: + "200": + description: OK + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Forbidden + "429": + description: Too Many Requests + x-speakeasy-name-override: delete + x-speakeasy-group: client.chat + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.client.chat.delete(ids=[]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.client.chat.delete({ + ids: [], + }); + + + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Chat.Delete(ctx, components.DeleteChatsRequest{\n Ids: []string{},\n }, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DeleteChatsRequest; + import com.glean.api_client.glean_api_client.models.operations.DeletechatsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeletechatsResponse res = sdk.client().chat().delete() + .deleteChatsRequest(DeleteChatsRequest.builder() + .ids(List.of()) + .build()) + .call(); + + // handle response + } + } + /rest/api/v1/getchat: + post: + tags: + - Chat + summary: Retrieves a Chat + description: Retrieves the chat history between Glean Assistant and the user for a given Chat. + operationId: getchat + x-visibility: Public + x-codegen-request-body-name: payload + parameters: + - $ref: "#/components/parameters/timezoneOffset" + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetChatRequest" + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetChatResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Forbidden + "429": + description: Too Many Requests + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.chat + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.chat.retrieve(id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.chat.retrieve({ + id: "", + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Chat.Retrieve(ctx, components.GetChatRequest{\n ID: \"\",\n }, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.GetChatResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.GetChatRequest; + import com.glean.api_client.glean_api_client.models.operations.GetchatResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetchatResponse res = sdk.client().chat().retrieve() + .getChatRequest(GetChatRequest.builder() + .id("") + .build()) + .call(); + + if (res.getChatResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/listchats: + post: + tags: + - Chat + summary: Retrieves all saved Chats + description: Retrieves all the saved Chats between Glean Assistant and the user. The returned Chats contain only metadata and no conversational content. + operationId: listchats + x-visibility: Public + x-codegen-request-body-name: payload + parameters: + - $ref: "#/components/parameters/timezoneOffset" + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/ListChatsResponse" + "401": + description: Not Authorized + "403": + description: Forbidden + "429": + description: Too Many Requests + x-speakeasy-name-override: list + x-speakeasy-group: client.chat + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.chat.list() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.chat.list(); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Chat.List(ctx, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.ListChatsResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.ListchatsResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ListchatsResponse res = sdk.client().chat().list() + .call(); + + if (res.listChatsResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/getchatapplication: + post: + tags: + - Chat + summary: Gets the metadata for a custom Chat application + description: Gets the Chat application details for the specified application ID. + operationId: getchatapplication + x-visibility: Preview + x-codegen-request-body-name: payload + parameters: + - $ref: "#/components/parameters/timezoneOffset" + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetChatApplicationRequest" + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetChatApplicationResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Forbidden + x-speakeasy-name-override: retrieveApplication + x-speakeasy-group: client.chat + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.chat.retrieve_application(id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.chat.retrieveApplication({ + id: "", + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Chat.RetrieveApplication(ctx, components.GetChatApplicationRequest{\n ID: \"\",\n }, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.GetChatApplicationResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.GetChatApplicationRequest; + import com.glean.api_client.glean_api_client.models.operations.GetchatapplicationResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetchatapplicationResponse res = sdk.client().chat().retrieveApplication() + .getChatApplicationRequest(GetChatApplicationRequest.builder() + .id("") + .build()) + .call(); + + if (res.getChatApplicationResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/uploadchatfiles: + post: + tags: + - Chat + summary: Upload files for Chat. + description: Upload files for Chat. + operationId: uploadchatfiles + x-visibility: Public + parameters: + - $ref: "#/components/parameters/timezoneOffset" + requestBody: + required: true + content: + multipart/form-data: + schema: + $ref: "#/components/schemas/UploadChatFilesRequest" + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/UploadChatFilesResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Forbidden + "429": + description: Too Many Requests + x-speakeasy-name-override: uploadFiles + x-speakeasy-group: client.chat + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.chat.upload_files(files=[ + { + "file_name": "example.file", + "content": open("example.file", "rb"), + }, + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + import { openAsBlob } from "node:fs"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.chat.uploadFiles({ + files: [ + { + fileName: "example.file", + content: await openAsBlob("example.file"), + }, + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Chat.UploadFiles(ctx, components.UploadChatFilesRequest{\n Files: []components.File{\n components.File{\n FileName: \"example.file\",\n Content: content,\n },\n },\n }, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.UploadChatFilesResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.File; + import com.glean.api_client.glean_api_client.models.components.UploadChatFilesRequest; + import com.glean.api_client.glean_api_client.models.operations.UploadchatfilesResponse; + import java.lang.Exception; + import java.nio.charset.StandardCharsets; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + UploadchatfilesResponse res = sdk.client().chat().uploadFiles() + .uploadChatFilesRequest(UploadChatFilesRequest.builder() + .files(List.of( + File.builder() + .fileName("example.file") + .content("0x8b739cFCeF".getBytes(StandardCharsets.UTF_8)) + .build())) + .build()) + .call(); + + if (res.uploadChatFilesResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/getchatfiles: + post: + tags: + - Chat + summary: Get files uploaded by a user for Chat. + description: Get files uploaded by a user for Chat. + operationId: getchatfiles + x-visibility: Public + parameters: + - $ref: "#/components/parameters/timezoneOffset" + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/GetChatFilesRequest" + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetChatFilesResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Forbidden + "429": + description: Too Many Requests + x-speakeasy-name-override: retrieveFiles + x-speakeasy-group: client.chat + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.chat.retrieve_files(file_ids=[ + "", + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.chat.retrieveFiles({ + fileIds: [ + "", + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Chat.RetrieveFiles(ctx, components.GetChatFilesRequest{\n FileIds: []string{\n \"\",\n },\n }, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.GetChatFilesResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.GetChatFilesRequest; + import com.glean.api_client.glean_api_client.models.operations.GetchatfilesResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetchatfilesResponse res = sdk.client().chat().retrieveFiles() + .getChatFilesRequest(GetChatFilesRequest.builder() + .fileIds(List.of( + "")) + .build()) + .call(); + + if (res.getChatFilesResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/deletechatfiles: + post: + tags: + - Chat + summary: Delete files uploaded by a user for chat. + description: Delete files uploaded by a user for Chat. + operationId: deletechatfiles + x-visibility: Public + parameters: + - $ref: "#/components/parameters/timezoneOffset" + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteChatFilesRequest" + responses: + "200": + description: OK + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Forbidden + "429": + description: Too Many Requests + x-speakeasy-name-override: deleteFiles + x-speakeasy-group: client.chat + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.client.chat.delete_files(file_ids=[ + "", + "", + "", + ]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.client.chat.deleteFiles({ + fileIds: [ + "", + "", + "", + ], + }); + + + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Chat.DeleteFiles(ctx, components.DeleteChatFilesRequest{\n FileIds: []string{\n \"\",\n \"\",\n \"\",\n },\n }, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DeleteChatFilesRequest; + import com.glean.api_client.glean_api_client.models.operations.DeletechatfilesResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeletechatfilesResponse res = sdk.client().chat().deleteFiles() + .deleteChatFilesRequest(DeleteChatFilesRequest.builder() + .fileIds(List.of( + "", + "", + "")) + .build()) + .call(); + + // handle response + } + } + /rest/api/v1/agents/{agent_id}: + get: + tags: + - Agents + summary: Get Agent + description: Get an agent by ID. This endpoint implements the LangChain Agent Protocol, specifically part of the Agents stage (https://langchain-ai.github.io/agent-protocol/api.html#tag/agents/GET/agents/{agent_id}). It adheres to the standard contract defined for agent interoperability and can be used by agent runtimes that support the Agent Protocol. + operationId: getAgent + x-visibility: Preview + parameters: + - $ref: "#/components/parameters/timezoneOffset" + - description: The ID of the agent. + required: true + schema: + type: string + title: Agent ID + description: The ID of the agent. + name: agent_id + in: path + responses: + "200": + description: Success + content: + application/json: + schema: + $ref: "#/components/schemas/Agent" + "400": + description: Bad request + "403": + description: Forbidden + "404": + description: Not Found + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorResponse" + "500": + description: Internal server error + x-speakeasy-group: client.agents + x-speakeasy-name-override: retrieve + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.agents.retrieve(agent_id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.agents.retrieve(""); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Agents.Retrieve(ctx, \"\", nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.Agent != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.GetAgentResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetAgentResponse res = sdk.client().agents().retrieve() + .agentId("") + .call(); + + if (res.agent().isPresent()) { + // handle response + } + } + } + /rest/api/v1/agents/{agent_id}/schemas: + get: + tags: + - Agents + summary: Get Agent Schemas + description: Get an agent's schemas by ID. This endpoint implements the LangChain Agent Protocol, specifically part of the Agents stage (https://langchain-ai.github.io/agent-protocol/api.html#tag/agents/GET/agents/{agent_id}/schemas). It adheres to the standard contract defined for agent interoperability and can be used by agent runtimes that support the Agent Protocol. + operationId: getAgentSchemas + x-visibility: Preview + parameters: + - $ref: "#/components/parameters/timezoneOffset" + - description: The ID of the agent. + required: true + schema: + type: string + title: Agent Id + description: The ID of the agent. + name: agent_id + in: path + responses: + "200": + description: Success + content: + application/json: + schema: + $ref: "#/components/schemas/AgentSchemas" + "400": + description: Bad request + "403": + description: Forbidden + "404": + description: Not Found + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorResponse" + "422": + description: Validation Error + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorResponse" + "500": + description: Internal server error + x-speakeasy-group: client.agents + x-speakeasy-name-override: retrieveSchemas + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.agents.retrieve_schemas(agent_id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.agents.retrieveSchemas(""); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Agents.RetrieveSchemas(ctx, \"\", nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.AgentSchemas != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.GetAgentSchemasResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetAgentSchemasResponse res = sdk.client().agents().retrieveSchemas() + .agentId("") + .call(); + + if (res.agentSchemas().isPresent()) { + // handle response + } + } + } + /rest/api/v1/agents/search: + post: + tags: + - Agents + summary: Search Agents + description: List Agents available in this service. This endpoint implements the LangChain Agent Protocol, specifically part of the Agents stage (https://langchain-ai.github.io/agent-protocol/api.html#tag/agents/POST/agents/search). It adheres to the standard contract defined for agent interoperability and can be used by agent runtimes that support the Agent Protocol. + operationId: searchAgents + x-visibility: Preview + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/SearchAgentsRequest" + responses: + "200": + description: Success + content: + application/json: + schema: + $ref: "#/components/schemas/SearchAgentsResponse" + "400": + description: Bad request + "403": + description: Forbidden + "404": + description: Not Found + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorResponse" + "422": + description: Validation Error + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorResponse" + "500": + description: Internal server error + x-speakeasy-group: client.agents + x-speakeasy-name-override: list + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.agents.list() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.agents.list({}); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Agents.List(ctx, components.SearchAgentsRequest{})\n if err != nil {\n log.Fatal(err)\n }\n if res.SearchAgentsResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.SearchAgentsRequest; + import com.glean.api_client.glean_api_client.models.operations.SearchAgentsResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + SearchAgentsRequest req = SearchAgentsRequest.builder() + .build(); + + SearchAgentsResponse res = sdk.client().agents().list() + .request(req) + .call(); + + if (res.searchAgentsResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/agents/runs/stream: + post: + tags: + - Agents + summary: Create Run, Stream Output + description: Creates and triggers a run of an agent. Streams the output in SSE format. This endpoint implements the LangChain Agent Protocol, specifically part of the Runs stage (https://langchain-ai.github.io/agent-protocol/api.html#tag/runs/POST/runs/stream). It adheres to the standard contract defined for agent interoperability and can be used by agent runtimes that support the Agent Protocol. Note that running agents that reference third party platform write actions is unsupported as it requires user confirmation. + operationId: createAndStreamRun + x-visibility: Preview + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/AgentRunCreate" + required: true + responses: + "200": + description: Success + content: + text/event-stream: + schema: + type: string + description: |- + The server will send a stream of events in SSE format. + **Example event**: + id: 1 + event: message + data: {} + "400": + description: Bad request + "403": + description: Forbidden + "404": + description: Not Found + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorResponse" + "409": + description: Conflict + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorResponse" + "422": + description: Validation Error + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorResponse" + "500": + description: Internal server error + x-speakeasy-group: client.agents + x-speakeasy-name-override: runStream + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.agents.run_stream() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.agents.runStream({}); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Agents.RunStream(ctx, components.AgentRunCreate{})\n if err != nil {\n log.Fatal(err)\n }\n if res.Res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.AgentRunCreate; + import com.glean.api_client.glean_api_client.models.operations.CreateAndStreamRunResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + AgentRunCreate req = AgentRunCreate.builder() + .build(); + + CreateAndStreamRunResponse res = sdk.client().agents().runStream() + .request(req) + .call(); + + if (res.res().isPresent()) { + // handle response + } + } + } + /rest/api/v1/agents/runs/wait: + post: + tags: + - Agents + summary: Create Run, Wait for Output + description: Creates and triggers a run of an agent. Waits for final output and then returns it. This endpoint implements the LangChain Agent Protocol, specifically part of the Runs stage (https://langchain-ai.github.io/agent-protocol/api.html#tag/runs/POST/runs/wait). It adheres to the standard contract defined for agent interoperability and can be used by agent runtimes that support the Agent Protocol. Note that running agents that reference third party platform write actions is unsupported as it requires user confirmation. + operationId: createAndWaitRun + x-visibility: Preview + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/AgentRunCreate" + required: true + responses: + "200": + description: Success + content: + application/json: + schema: + $ref: "#/components/schemas/AgentRunWaitResponse" + "400": + description: Bad request + "403": + description: Forbidden + "404": + description: Not Found + "409": + description: Conflict + "422": + description: Validation Error + "500": + description: Internal server error + x-speakeasy-group: client.agents + x-speakeasy-name-override: run + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.agents.run() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.agents.run({}); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Agents.Run(ctx, components.AgentRunCreate{})\n if err != nil {\n log.Fatal(err)\n }\n if res.AgentRunWaitResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.AgentRunCreate; + import com.glean.api_client.glean_api_client.models.operations.CreateAndWaitRunResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + AgentRunCreate req = AgentRunCreate.builder() + .build(); + + CreateAndWaitRunResponse res = sdk.client().agents().run() + .request(req) + .call(); + + if (res.agentRunWaitResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/addcollectionitems: + post: + tags: + - Collections + summary: Add Collection item + description: Add items to a Collection. + operationId: addcollectionitems + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/AddCollectionItemsRequest" + description: Data describing the add operation. + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/AddCollectionItemsResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: addItems + x-speakeasy-group: client.collections + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.collections.add_items(collection_id=7742.68) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.collections.addItems({ + collectionId: 7742.68, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Collections.AddItems(ctx, components.AddCollectionItemsRequest{\n CollectionID: 7742.68,\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.AddCollectionItemsResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.AddCollectionItemsRequest; + import com.glean.api_client.glean_api_client.models.operations.AddcollectionitemsResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + AddCollectionItemsRequest req = AddCollectionItemsRequest.builder() + .collectionId(7742.68) + .build(); + + AddcollectionitemsResponse res = sdk.client().collections().addItems() + .request(req) + .call(); + + if (res.addCollectionItemsResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/createcollection: + post: + tags: + - Collections + summary: Create Collection + description: Create a publicly visible (empty) Collection of documents. + operationId: createcollection + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CreateCollectionRequest" + description: Collection content plus any additional metadata for the request. + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/CreateCollectionResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "422": + description: Semantic error + content: + application/json: + schema: + $ref: "#/components/schemas/CollectionError" + "429": + description: Too Many Requests + x-speakeasy-group: client.collections + x-speakeasy-name-override: create + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.collections.create(name="", added_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + ], removed_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VERIFIER, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VERIFIER, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VERIFIER, + ), + ], audience_filters=[ + { + "field_name": "type", + "values": [ + { + "value": "Spreadsheet", + "relation_type": models.RelationType.EQUALS, + }, + { + "value": "Presentation", + "relation_type": models.RelationType.EQUALS, + }, + ], + }, + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.collections.create({ + name: "", + addedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + ], + removedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VERIFIER", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VERIFIER", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VERIFIER", + }, + ], + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Collections.Create(ctx, components.CreateCollectionRequest{\n Name: \"\",\n AddedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n },\n RemovedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleVerifier,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleVerifier,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleVerifier,\n },\n },\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.CreateCollectionResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.errors.CollectionError; + import com.glean.api_client.glean_api_client.models.operations.CreatecollectionResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws CollectionError, Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + CreateCollectionRequest req = CreateCollectionRequest.builder() + .name("") + .addedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .removedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.VERIFIER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.VERIFIER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.VERIFIER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build(); + + CreatecollectionResponse res = sdk.client().collections().create() + .request(req) + .call(); + + if (res.createCollectionResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/deletecollection: + post: + tags: + - Collections + summary: Delete Collection + description: Delete a Collection given the Collection's ID. + operationId: deletecollection + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteCollectionRequest" + description: DeleteCollection request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + "400": + description: Invalid request + "401": + description: Not Authorized + "422": + description: Semantic error + content: + application/json: + schema: + $ref: "#/components/schemas/CollectionError" + "429": + description: Too Many Requests + x-speakeasy-name-override: delete + x-speakeasy-group: client.collections + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.client.collections.delete(ids=[ + 930352, + 156719, + 25102, + ]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.client.collections.delete({ + ids: [ + 930352, + 156719, + 25102, + ], + }); + + + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Collections.Delete(ctx, components.DeleteCollectionRequest{\n Ids: []int64{\n 930352,\n 156719,\n 25102,\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DeleteCollectionRequest; + import com.glean.api_client.glean_api_client.models.errors.CollectionError; + import com.glean.api_client.glean_api_client.models.operations.DeletecollectionResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws CollectionError, Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeleteCollectionRequest req = DeleteCollectionRequest.builder() + .ids(List.of( + 930352L, + 156719L, + 25102L)) + .build(); + + DeletecollectionResponse res = sdk.client().collections().delete() + .request(req) + .call(); + + // handle response + } + } + /rest/api/v1/deletecollectionitem: + post: + tags: + - Collections + summary: Delete Collection item + description: Delete a single item from a Collection. + operationId: deletecollectionitem + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteCollectionItemRequest" + description: Data describing the delete operation. + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteCollectionItemResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "422": + description: Failed to save deletion + "429": + description: Too Many Requests + x-speakeasy-name-override: deleteItem + x-speakeasy-group: client.collections + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.collections.delete_item(collection_id=6980.49, item_id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.collections.deleteItem({ + collectionId: 6980.49, + itemId: "", + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Collections.DeleteItem(ctx, components.DeleteCollectionItemRequest{\n CollectionID: 6980.49,\n ItemID: \"\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.DeleteCollectionItemResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DeleteCollectionItemRequest; + import com.glean.api_client.glean_api_client.models.operations.DeletecollectionitemResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeleteCollectionItemRequest req = DeleteCollectionItemRequest.builder() + .collectionId(6980.49) + .itemId("") + .build(); + + DeletecollectionitemResponse res = sdk.client().collections().deleteItem() + .request(req) + .call(); + + if (res.deleteCollectionItemResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/editcollection: + post: + tags: + - Collections + summary: Update Collection + description: Update the properties of an existing Collection. + operationId: editcollection + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/EditCollectionRequest" + description: Collection content plus any additional metadata for the request. + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/EditCollectionResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "422": + description: Semantic error + content: + application/json: + schema: + $ref: "#/components/schemas/CollectionError" + "429": + description: Too Many Requests + x-speakeasy-name-override: update + x-speakeasy-group: client.collections + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.collections.update(name="", id=330922, added_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VERIFIER, + ), + ], removed_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.EDITOR, + ), + ], audience_filters=[ + { + "field_name": "type", + "values": [ + { + "value": "Spreadsheet", + "relation_type": models.RelationType.EQUALS, + }, + { + "value": "Presentation", + "relation_type": models.RelationType.EQUALS, + }, + ], + }, + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.collections.update({ + name: "", + addedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VERIFIER", + }, + ], + removedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "EDITOR", + }, + ], + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + id: 330922, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Collections.Update(ctx, components.EditCollectionRequest{\n Name: \"\",\n AddedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleVerifier,\n },\n },\n RemovedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleEditor,\n },\n },\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n ID: 330922,\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.EditCollectionResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.errors.CollectionError; + import com.glean.api_client.glean_api_client.models.operations.EditcollectionResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws CollectionError, Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + EditCollectionRequest req = EditCollectionRequest.builder() + .name("") + .id(330922L) + .addedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.VERIFIER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .removedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.EDITOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build(); + + EditcollectionResponse res = sdk.client().collections().update() + .request(req) + .call(); + + if (res.editCollectionResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/editcollectionitem: + post: + tags: + - Collections + summary: Update Collection item + description: Update the URL, Glean Document ID, description of an item within a Collection given its ID. + operationId: editcollectionitem + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/EditCollectionItemRequest" + description: Edit Collection Items request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/EditCollectionItemResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: updateItem + x-speakeasy-group: client.collections + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.collections.update_item(collection_id=142375, item_id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.collections.updateItem({ + collectionId: 142375, + itemId: "", + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Collections.UpdateItem(ctx, components.EditCollectionItemRequest{\n CollectionID: 142375,\n ItemID: \"\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.EditCollectionItemResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.EditCollectionItemRequest; + import com.glean.api_client.glean_api_client.models.operations.EditcollectionitemResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + EditCollectionItemRequest req = EditCollectionItemRequest.builder() + .collectionId(142375L) + .itemId("") + .build(); + + EditcollectionitemResponse res = sdk.client().collections().updateItem() + .request(req) + .call(); + + if (res.editCollectionItemResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/getcollection: + post: + tags: + - Collections + summary: Read Collection + description: Read the details of a Collection given its ID. Does not fetch items in this Collection. + operationId: getcollection + x-visibility: Preview + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetCollectionRequest" + description: GetCollection request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetCollectionResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.collections + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.collections.retrieve(id=425335) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.collections.retrieve({ + id: 425335, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Collections.Retrieve(ctx, components.GetCollectionRequest{\n ID: 425335,\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.GetCollectionResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.GetCollectionRequest; + import com.glean.api_client.glean_api_client.models.operations.GetcollectionResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetCollectionRequest req = GetCollectionRequest.builder() + .id(425335L) + .build(); + + GetcollectionResponse res = sdk.client().collections().retrieve() + .request(req) + .call(); + + if (res.getCollectionResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/listcollections: + post: + tags: + - Collections + summary: List Collections + description: List all existing Collections. + operationId: listcollections + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/ListCollectionsRequest" + description: ListCollections request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/ListCollectionsResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: list + x-speakeasy-group: client.collections + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.collections.list() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.collections.list({}); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Collections.List(ctx, components.ListCollectionsRequest{})\n if err != nil {\n log.Fatal(err)\n }\n if res.ListCollectionsResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.ListCollectionsRequest; + import com.glean.api_client.glean_api_client.models.operations.ListcollectionsResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ListCollectionsRequest req = ListCollectionsRequest.builder() + .build(); + + ListcollectionsResponse res = sdk.client().collections().list() + .request(req) + .call(); + + if (res.listCollectionsResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/getdocpermissions: + post: + tags: + - Documents + summary: Read document permissions + description: Read the emails of all users who have access to the given document. + operationId: getdocpermissions + x-visibility: Preview + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetDocPermissionsRequest" + description: Document permissions request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetDocPermissionsResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Forbidden + "429": + description: Too Many Requests + x-speakeasy-name-override: retrievePermissions + x-speakeasy-group: client.documents + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.documents.retrieve_permissions() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.documents.retrievePermissions({}); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Documents.RetrievePermissions(ctx, components.GetDocPermissionsRequest{})\n if err != nil {\n log.Fatal(err)\n }\n if res.GetDocPermissionsResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.GetDocPermissionsRequest; + import com.glean.api_client.glean_api_client.models.operations.GetdocpermissionsResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetDocPermissionsRequest req = GetDocPermissionsRequest.builder() + .build(); + + GetdocpermissionsResponse res = sdk.client().documents().retrievePermissions() + .request(req) + .call(); + + if (res.getDocPermissionsResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/getdocuments: + post: + tags: + - Documents + summary: Read documents + description: Read the documents including metadata (does not include enhanced metadata via `/documentmetadata`) for the given list of Glean Document IDs or URLs specified in the request. + operationId: getdocuments + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetDocumentsRequest" + description: Information about documents requested. + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetDocumentsResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Documents does not exist, or user cannot access documents. + "429": + description: Too Many Requests + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.documents + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.documents.retrieve() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.documents.retrieve(); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Documents.Retrieve(ctx, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.GetDocumentsResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.GetdocumentsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetDocumentsRequest req = GetDocumentsRequest.builder() + .documentSpecs(List.of( + DocumentSpecUnion.of(DocumentSpec1.builder() + .build()))) + .build(); + + GetdocumentsResponse res = sdk.client().documents().retrieve() + .request(req) + .call(); + + if (res.getDocumentsResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/getdocumentsbyfacets: + post: + tags: + - Documents + summary: Read documents by facets + description: Read the documents including metadata (does not include enhanced metadata via `/documentmetadata`) macthing the given facet conditions. + operationId: getdocumentsbyfacets + x-visibility: Preview + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetDocumentsByFacetsRequest" + description: Information about facet conditions for documents to be retrieved. + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetDocumentsByFacetsResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "404": + description: Not Found + "429": + description: Too Many Requests + x-speakeasy-name-override: retrieveByFacets + x-speakeasy-group: client.documents + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.documents.retrieve_by_facets(request={ + "filter_sets": [ + { + "filters": [ + { + "field_name": "type", + "values": [ + { + "value": "Spreadsheet", + "relation_type": models.RelationType.EQUALS, + }, + { + "value": "Presentation", + "relation_type": models.RelationType.EQUALS, + }, + ], + }, + ], + }, + { + "filters": [ + { + "field_name": "type", + "values": [ + { + "value": "Spreadsheet", + "relation_type": models.RelationType.EQUALS, + }, + { + "value": "Presentation", + "relation_type": models.RelationType.EQUALS, + }, + ], + }, + ], + }, + ], + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.documents.retrieveByFacets({ + filterSets: [ + { + filters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + }, + { + filters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + }, + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Documents.RetrieveByFacets(ctx, &components.GetDocumentsByFacetsRequest{\n FilterSets: []components.FacetFilterSet{\n components.FacetFilterSet{\n Filters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n },\n components.FacetFilterSet{\n Filters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.GetDocumentsByFacetsResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.GetdocumentsbyfacetsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetDocumentsByFacetsRequest req = GetDocumentsByFacetsRequest.builder() + .filterSets(List.of( + FacetFilterSet.builder() + .filters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build(), + FacetFilterSet.builder() + .filters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build())) + .build(); + + GetdocumentsbyfacetsResponse res = sdk.client().documents().retrieveByFacets() + .request(req) + .call(); + + if (res.getDocumentsByFacetsResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/insights: + post: + tags: + - Insights + summary: Read insights + description: Reads the aggregate information for each user, query, and content. + operationId: insights + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/InsightsRequest" + description: Includes request params for insights dashboard data. + required: true + x-exportParamName: InsightsRequest + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/InsightsResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.insights + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.insights.retrieve(categories=[ + models.InsightsRequestCategory.COLLECTIONS, + models.InsightsRequestCategory.SHORTCUTS, + models.InsightsRequestCategory.ANNOUNCEMENTS, + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.insights.retrieve({ + categories: [ + "COLLECTIONS", + "SHORTCUTS", + "ANNOUNCEMENTS", + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Insights.Retrieve(ctx, components.InsightsRequest{\n Categories: []components.InsightsRequestCategory{\n components.InsightsRequestCategoryCollections,\n components.InsightsRequestCategoryShortcuts,\n components.InsightsRequestCategoryAnnouncements,\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.InsightsResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.InsightsRequest; + import com.glean.api_client.glean_api_client.models.components.InsightsRequestCategory; + import com.glean.api_client.glean_api_client.models.operations.InsightsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + InsightsRequest req = InsightsRequest.builder() + .categories(List.of( + InsightsRequestCategory.COLLECTIONS, + InsightsRequestCategory.SHORTCUTS, + InsightsRequestCategory.ANNOUNCEMENTS)) + .build(); + + InsightsResponse res = sdk.client().insights().retrieve() + .request(req) + .call(); + + if (res.insightsResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/messages: + post: + tags: + - Messages + summary: Read messages + description: Retrieves list of messages from messaging/chat datasources (e.g. Slack, Teams). + operationId: messages + x-visibility: Preview + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/MessagesRequest" + description: Includes request params such as the id for channel/message and direction. + required: true + x-exportParamName: MessagesRequest + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/MessagesResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.messages + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.messages.retrieve(id_type=models.IDType.CONVERSATION_ID, id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.messages.retrieve({ + idType: "CONVERSATION_ID", + id: "", + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Messages.Retrieve(ctx, components.MessagesRequest{\n IDType: components.IDTypeConversationID,\n ID: \"\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.MessagesResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.IdType; + import com.glean.api_client.glean_api_client.models.components.MessagesRequest; + import com.glean.api_client.glean_api_client.models.operations.MessagesResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + MessagesRequest req = MessagesRequest.builder() + .idType(IdType.CONVERSATION_ID) + .id("") + .build(); + + MessagesResponse res = sdk.client().messages().retrieve() + .request(req) + .call(); + + if (res.messagesResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/editpin: + post: + tags: + - Pins + summary: Update pin + description: Update an existing user-generated pin. + operationId: editpin + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/EditPinRequest" + description: Edit pins request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/PinDocument" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: update + x-speakeasy-group: client.pins + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.pins.update(request={ + "audience_filters": [ + { + "field_name": "type", + "values": [ + { + "value": "Spreadsheet", + "relation_type": models.RelationType.EQUALS, + }, + { + "value": "Presentation", + "relation_type": models.RelationType.EQUALS, + }, + ], + }, + ], + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.pins.update({ + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Pins.Update(ctx, components.EditPinRequest{\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.PinDocument != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.EditpinResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + EditPinRequest req = EditPinRequest.builder() + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build(); + + EditpinResponse res = sdk.client().pins().update() + .request(req) + .call(); + + if (res.pinDocument().isPresent()) { + // handle response + } + } + } + /rest/api/v1/getpin: + post: + tags: + - Pins + summary: Read pin + description: Read pin details given its ID. + operationId: getpin + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetPinRequest" + description: Get pin request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetPinResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.pins + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.pins.retrieve() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.pins.retrieve({}); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Pins.Retrieve(ctx, components.GetPinRequest{})\n if err != nil {\n log.Fatal(err)\n }\n if res.GetPinResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.GetPinRequest; + import com.glean.api_client.glean_api_client.models.operations.GetpinResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetPinRequest req = GetPinRequest.builder() + .build(); + + GetpinResponse res = sdk.client().pins().retrieve() + .request(req) + .call(); + + if (res.getPinResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/listpins: + post: + tags: + - Pins + summary: List pins + description: Lists all pins. + operationId: listpins + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + type: object + description: List pins request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/ListPinsResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: list + x-speakeasy-group: client.pins + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.pins.list() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.pins.list({}); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/operations\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Pins.List(ctx, operations.ListpinsRequest{})\n if err != nil {\n log.Fatal(err)\n }\n if res.ListPinsResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.ListpinsRequest; + import com.glean.api_client.glean_api_client.models.operations.ListpinsResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ListpinsRequest req = ListpinsRequest.builder() + .build(); + + ListpinsResponse res = sdk.client().pins().list() + .request(req) + .call(); + + if (res.listPinsResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/pin: + post: + tags: + - Pins + summary: Create pin + description: Pin a document as a result for a given search query.Pin results that are known to be a good match. + operationId: pin + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/PinRequest" + description: Details about the document and query for the pin. + required: true + x-exportParamName: PinDocument + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/PinDocument" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: create + x-speakeasy-group: client.pins + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.pins.create(request={ + "audience_filters": [ + { + "field_name": "type", + "values": [ + { + "value": "Spreadsheet", + "relation_type": models.RelationType.EQUALS, + }, + { + "value": "Presentation", + "relation_type": models.RelationType.EQUALS, + }, + ], + }, + ], + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.pins.create({ + audienceFilters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Pins.Create(ctx, components.PinRequest{\n AudienceFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.PinDocument != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.PinResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + PinRequest req = PinRequest.builder() + .audienceFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build(); + + PinResponse res = sdk.client().pins().create() + .request(req) + .call(); + + if (res.pinDocument().isPresent()) { + // handle response + } + } + } + /rest/api/v1/unpin: + post: + tags: + - Pins + summary: Delete pin + description: Unpin a previously pinned result. + operationId: unpin + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/Unpin" + description: Details about the pin being unpinned. + required: true + x-exportParamName: Unpin + responses: + "200": + description: OK + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Forbidden from unpinning someone else's pin + "429": + description: Too Many Requests + x-speakeasy-name-override: remove + x-speakeasy-group: client.pins + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.client.pins.remove() + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.client.pins.remove({}); + + + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Pins.Remove(ctx, components.Unpin{})\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.Unpin; + import com.glean.api_client.glean_api_client.models.operations.UnpinResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + Unpin req = Unpin.builder() + .build(); + + UnpinResponse res = sdk.client().pins().remove() + .request(req) + .call(); + + // handle response + } + } + /rest/api/v1/adminsearch: + post: + tags: + - Search + summary: Search the index (admin) + description: Retrieves results for search query without respect for permissions. This is available only to privileged users. + operationId: adminsearch + x-visibility: Preview + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/SearchRequest" + description: Admin search request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/SearchResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Forbidden + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorInfo" + "422": + description: Invalid Query + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorInfo" + "429": + description: Too Many Requests + x-speakeasy-group: client.search + x-speakeasy-name-override: queryAsAdmin + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + from glean.api_client.utils import parse_datetime + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.search.query_as_admin(query="vacation policy", tracking_token="trackingToken", source_document=models.Document( + container_document=models.Document( + parent_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + ), page_size=10, max_snippet_size=400, input_details={ + "has_copy_paste": True, + }, request_options=models.SearchRequestOptions( + facet_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="article", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="document", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + models.FacetFilter( + field_name="department", + values=[ + models.FacetFilterValue( + value="engineering", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + facet_bucket_size=723824, + ), timeout_millis=5000, people=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.search.queryAsAdmin({ + trackingToken: "trackingToken", + pageSize: 10, + query: "vacation policy", + requestOptions: { + facetFilters: [ + { + fieldName: "type", + values: [ + { + value: "article", + relationType: "EQUALS", + }, + { + value: "document", + relationType: "EQUALS", + }, + ], + }, + { + fieldName: "department", + values: [ + { + value: "engineering", + relationType: "EQUALS", + }, + ], + }, + ], + facetBucketSize: 723824, + }, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/types\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Search.QueryAsAdmin(ctx, components.SearchRequest{\n TrackingToken: apiclientgo.String(\"trackingToken\"),\n PageSize: apiclientgo.Int64(10),\n Query: \"vacation policy\",\n RequestOptions: &components.SearchRequestOptions{\n FacetFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"article\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"document\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n components.FacetFilter{\n FieldName: apiclientgo.String(\"department\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"engineering\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n FacetBucketSize: 723824,\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.SearchResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.errors.GleanDataError; + import com.glean.api_client.glean_api_client.models.operations.AdminsearchResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws GleanDataError, Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + SearchRequest req = SearchRequest.builder() + .query("vacation policy") + .trackingToken("trackingToken") + .pageSize(10L) + .requestOptions(SearchRequestOptions.builder() + .facetBucketSize(723824L) + .facetFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("article") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("document") + .relationType(RelationType.EQUALS) + .build())) + .build(), + FacetFilter.builder() + .fieldName("department") + .values(List.of( + FacetFilterValue.builder() + .value("engineering") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build()) + .build(); + + AdminsearchResponse res = sdk.client().search().queryAsAdmin() + .request(req) + .call(); + + if (res.searchResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/autocomplete: + post: + tags: + - Search + summary: Autocomplete + description: Retrieve query suggestions, operators and documents for the given partially typed query. + operationId: autocomplete + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/AutocompleteRequest" + description: Autocomplete request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/AutocompleteResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-group: client.search + x-speakeasy-name-override: autocomplete + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.search.autocomplete(request={ + "tracking_token": "trackingToken", + "query": "what is a que", + "datasource": "GDRIVE", + "result_size": 10, + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.search.autocomplete({ + trackingToken: "trackingToken", + query: "what is a que", + datasource: "GDRIVE", + resultSize: 10, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Search.Autocomplete(ctx, components.AutocompleteRequest{\n TrackingToken: apiclientgo.String(\"trackingToken\"),\n Query: apiclientgo.String(\"what is a que\"),\n Datasource: apiclientgo.String(\"GDRIVE\"),\n ResultSize: apiclientgo.Int64(10),\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.AutocompleteResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.AutocompleteRequest; + import com.glean.api_client.glean_api_client.models.operations.AutocompleteResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + AutocompleteRequest req = AutocompleteRequest.builder() + .trackingToken("trackingToken") + .query("what is a que") + .datasource("GDRIVE") + .resultSize(10L) + .build(); + + AutocompleteResponse res = sdk.client().search().autocomplete() + .request(req) + .call(); + + if (res.autocompleteResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/feed: + post: + tags: + - Search + summary: Feed of documents and events + description: The personalized feed/home includes different types of contents including suggestions, recents, calendar events and many more. + operationId: feed + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/FeedRequest" + description: Includes request params, client data and more for making user's feed. + required: true + x-exportParamName: FeedRequest + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/FeedResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "408": + description: Request Timeout + "429": + description: Too Many Requests + x-speakeasy-name-override: retrieveFeed + x-speakeasy-group: client.search + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.search.retrieve_feed(request={ + "timeout_millis": 5000, + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.search.retrieveFeed({ + timeoutMillis: 5000, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Search.RetrieveFeed(ctx, components.FeedRequest{\n TimeoutMillis: apiclientgo.Int64(5000),\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.FeedResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.FeedRequest; + import com.glean.api_client.glean_api_client.models.operations.FeedResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + FeedRequest req = FeedRequest.builder() + .timeoutMillis(5000L) + .build(); + + FeedResponse res = sdk.client().search().retrieveFeed() + .request(req) + .call(); + + if (res.feedResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/recommendations: + post: + tags: + - Search + summary: Recommend documents + description: Retrieve recommended documents for the given URL or Glean Document ID. + operationId: recommendations + x-visibility: Preview + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/RecommendationsRequest" + description: Recommendations request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/RecommendationsResponse" + "202": + description: Accepted. The Retry-After header has a hint about when the response will be available + "204": + description: There are no recommendations for this URL + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Document does not exist or user cannot access document + "429": + description: Too Many Requests + x-speakeasy-group: client.search + x-speakeasy-name-override: recommendations + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + from glean.api_client.utils import parse_datetime + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.search.recommendations(request=models.RecommendationsRequest( + source_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + page_size=100, + max_snippet_size=400, + request_options=models.RecommendationsRequestOptions( + facet_filter_sets=[ + models.FacetFilterSet( + filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="Spreadsheet", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="Presentation", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + ), + ], + context=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + )) + + assert res is not None + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.search.recommendations({ + sourceDocument: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + pageSize: 100, + maxSnippetSize: 400, + requestOptions: { + facetFilterSets: [ + { + filters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + }, + ], + context: { + metadata: { + datasource: "datasource", + objectType: "Feature Request", + container: "container", + parentId: "JIRA_EN-1337", + mimeType: "mimeType", + documentId: "documentId", + createTime: new Date("2000-01-23T04:56:07.000Z"), + updateTime: new Date("2000-01-23T04:56:07.000Z"), + author: { + name: "name", + obfuscatedId: "", + }, + components: [ + "Backend", + "Networking", + ], + status: "[\"Done\"]", + customData: { + "someCustomField": {}, + }, + }, + }, + }, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/types\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Search.Recommendations(ctx, components.RecommendationsRequest{\n SourceDocument: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n PageSize: apiclientgo.Int64(100),\n MaxSnippetSize: apiclientgo.Int64(400),\n RequestOptions: &components.RecommendationsRequestOptions{\n FacetFilterSets: []components.FacetFilterSet{\n components.FacetFilterSet{\n Filters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n },\n },\n Context: &components.Document{\n Metadata: &components.DocumentMetadata{\n Datasource: apiclientgo.String(\"datasource\"),\n ObjectType: apiclientgo.String(\"Feature Request\"),\n Container: apiclientgo.String(\"container\"),\n ParentID: apiclientgo.String(\"JIRA_EN-1337\"),\n MimeType: apiclientgo.String(\"mimeType\"),\n DocumentID: apiclientgo.String(\"documentId\"),\n CreateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n UpdateTime: types.MustNewTimeFromString(\"2000-01-23T04:56:07.000Z\"),\n Author: &components.Person{\n Name: \"name\",\n ObfuscatedID: \"\",\n },\n Components: []string{\n \"Backend\",\n \"Networking\",\n },\n Status: apiclientgo.String(\"[\\\"Done\\\"]\"),\n CustomData: map[string]components.CustomDataValue{\n \"someCustomField\": components.CustomDataValue{},\n },\n },\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.ResultsResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.RecommendationsResponse; + import java.lang.Exception; + import java.time.OffsetDateTime; + import java.util.List; + import java.util.Map; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + RecommendationsRequest req = RecommendationsRequest.builder() + .sourceDocument(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .pageSize(100L) + .maxSnippetSize(400L) + .requestOptions(RecommendationsRequestOptions.builder() + .facetFilterSets(List.of( + FacetFilterSet.builder() + .filters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build())) + .context(Document.builder() + .metadata(DocumentMetadata.builder() + .datasource("datasource") + .objectType("Feature Request") + .container("container") + .parentId("JIRA_EN-1337") + .mimeType("mimeType") + .documentId("documentId") + .createTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .updateTime(OffsetDateTime.parse("2000-01-23T04:56:07.000Z")) + .author(Person.builder() + .name("name") + .obfuscatedId("") + .build()) + .components(List.of( + "Backend", + "Networking")) + .status("[\"Done\"]") + .customData(Map.ofEntries( + Map.entry("someCustomField", CustomDataValue.builder() + .build()))) + .build()) + .build()) + .build()) + .build(); + + RecommendationsResponse res = sdk.client().search().recommendations() + .request(req) + .call(); + + if (res.resultsResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/search: + post: + tags: + - Search + summary: Search + description: Retrieve results from the index for the given query and filters. + operationId: search + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/SearchRequest" + description: Search request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/SearchResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Forbidden + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorInfo" + "408": + description: Request Timeout + "422": + description: Invalid Query + content: + application/json: + schema: + $ref: "#/components/schemas/ErrorInfo" + "429": + description: Too Many Requests + x-speakeasy-group: client.search + x-speakeasy-name-override: query + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + from glean.api_client.utils import parse_datetime + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.search.query(query="vacation policy", tracking_token="trackingToken", source_document=models.Document( + container_document=models.Document( + parent_document=models.Document( + metadata=models.DocumentMetadata( + datasource="datasource", + object_type="Feature Request", + container="container", + parent_id="JIRA_EN-1337", + mime_type="mimeType", + document_id="documentId", + create_time=parse_datetime("2000-01-23T04:56:07.000Z"), + update_time=parse_datetime("2000-01-23T04:56:07.000Z"), + author=models.Person( + name="name", + obfuscated_id="", + ), + components=[ + "Backend", + "Networking", + ], + status="[\"Done\"]", + custom_data={ + "someCustomField": models.CustomDataValue(), + }, + ), + ), + ), + ), page_size=10, max_snippet_size=400, input_details={ + "has_copy_paste": True, + }, request_options=models.SearchRequestOptions( + facet_filters=[ + models.FacetFilter( + field_name="type", + values=[ + models.FacetFilterValue( + value="article", + relation_type=models.RelationType.EQUALS, + ), + models.FacetFilterValue( + value="document", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + models.FacetFilter( + field_name="department", + values=[ + models.FacetFilterValue( + value="engineering", + relation_type=models.RelationType.EQUALS, + ), + ], + ), + ], + facet_bucket_size=939520, + ), timeout_millis=5000, people=[ + models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.search.query({ + trackingToken: "trackingToken", + pageSize: 10, + query: "vacation policy", + requestOptions: { + facetFilters: [ + { + fieldName: "type", + values: [ + { + value: "article", + relationType: "EQUALS", + }, + { + value: "document", + relationType: "EQUALS", + }, + ], + }, + { + fieldName: "department", + values: [ + { + value: "engineering", + relationType: "EQUALS", + }, + ], + }, + ], + facetBucketSize: 939520, + }, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/types\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Search.Query(ctx, components.SearchRequest{\n TrackingToken: apiclientgo.String(\"trackingToken\"),\n PageSize: apiclientgo.Int64(10),\n Query: \"vacation policy\",\n RequestOptions: &components.SearchRequestOptions{\n FacetFilters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"article\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"document\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n components.FacetFilter{\n FieldName: apiclientgo.String(\"department\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"engineering\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n FacetBucketSize: 939520,\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.SearchResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.errors.GleanDataError; + import com.glean.api_client.glean_api_client.models.operations.SearchResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws GleanDataError, Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + SearchRequest req = SearchRequest.builder() + .query("vacation policy") + .trackingToken("trackingToken") + .pageSize(10L) + .requestOptions(SearchRequestOptions.builder() + .facetBucketSize(939520L) + .facetFilters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("article") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("document") + .relationType(RelationType.EQUALS) + .build())) + .build(), + FacetFilter.builder() + .fieldName("department") + .values(List.of( + FacetFilterValue.builder() + .value("engineering") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build()) + .build(); + + SearchResponse res = sdk.client().search().query() + .request(req) + .call(); + + if (res.searchResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/listentities: + post: + tags: + - Entities + summary: List entities + description: List some set of details for all entities that fit the given criteria and return in the requested order. Does not support negation in filters, assumes relation type EQUALS. There is a limit of 10000 entities that can be retrieved via this endpoint. + operationId: listentities + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/ListEntitiesRequest" + description: List people request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/ListEntitiesResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-group: client.entities + x-speakeasy-name-override: list + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.entities.list(request={ + "filter_": [ + { + "field_name": "type", + "values": [ + { + "value": "Spreadsheet", + "relation_type": models.RelationType.EQUALS, + }, + { + "value": "Presentation", + "relation_type": models.RelationType.EQUALS, + }, + ], + }, + ], + "page_size": 100, + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.entities.list({ + filter: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + pageSize: 100, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Entities.List(ctx, components.ListEntitiesRequest{\n Filter: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n PageSize: apiclientgo.Int64(100),\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.ListEntitiesResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.ListentitiesResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ListEntitiesRequest req = ListEntitiesRequest.builder() + .filter(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .pageSize(100L) + .build(); + + ListentitiesResponse res = sdk.client().entities().list() + .request(req) + .call(); + + if (res.listEntitiesResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/people: + post: + tags: + - Entities + summary: Read people + description: Read people details for the given IDs. + operationId: people + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/PeopleRequest" + description: People request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/PeopleResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: readPeople + x-speakeasy-group: client.entities + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.entities.read_people(request={ + "obfuscated_ids": [ + "abc123", + "abc456", + ], + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.entities.readPeople({ + obfuscatedIds: [ + "abc123", + "abc456", + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Entities.ReadPeople(ctx, components.PeopleRequest{\n ObfuscatedIds: []string{\n \"abc123\",\n \"abc456\",\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.PeopleResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.PeopleRequest; + import com.glean.api_client.glean_api_client.models.operations.PeopleResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + PeopleRequest req = PeopleRequest.builder() + .obfuscatedIds(List.of( + "abc123", + "abc456")) + .build(); + + PeopleResponse res = sdk.client().entities().readPeople() + .request(req) + .call(); + + if (res.peopleResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/createshortcut: + post: + tags: + - Shortcuts + summary: Create shortcut + description: Create a user-generated shortcut that contains an alias and destination URL. + operationId: createshortcut + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CreateShortcutRequest" + description: CreateShortcut request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/CreateShortcutResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: create + x-speakeasy-group: client.shortcuts + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.shortcuts.create(data={ + "added_roles": [ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VIEWER, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VIEWER, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VIEWER, + ), + ], + "removed_roles": [ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + ], + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.shortcuts.create({ + data: { + addedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VIEWER", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VIEWER", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VIEWER", + }, + ], + removedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + ], + }, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Shortcuts.Create(ctx, components.CreateShortcutRequest{\n Data: components.ShortcutMutableProperties{\n AddedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleViewer,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleViewer,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleViewer,\n },\n },\n RemovedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.CreateShortcutResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.CreateshortcutResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + CreateShortcutRequest req = CreateShortcutRequest.builder() + .data(ShortcutMutableProperties.builder() + .addedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.VIEWER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.VIEWER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.VIEWER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .removedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build()) + .build(); + + CreateshortcutResponse res = sdk.client().shortcuts().create() + .request(req) + .call(); + + if (res.createShortcutResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/deleteshortcut: + post: + tags: + - Shortcuts + summary: Delete shortcut + description: Delete an existing user-generated shortcut. + operationId: deleteshortcut + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteShortcutRequest" + description: DeleteShortcut request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: delete + x-speakeasy-group: client.shortcuts + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.client.shortcuts.delete(id=975862) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.client.shortcuts.delete({ + id: 975862, + }); + + + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Shortcuts.Delete(ctx, components.DeleteShortcutRequest{\n ID: 975862,\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DeleteShortcutRequest; + import com.glean.api_client.glean_api_client.models.operations.DeleteshortcutResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeleteShortcutRequest req = DeleteShortcutRequest.builder() + .id(975862L) + .build(); + + DeleteshortcutResponse res = sdk.client().shortcuts().delete() + .request(req) + .call(); + + // handle response + } + } + /rest/api/v1/getshortcut: + post: + tags: + - Shortcuts + summary: Read shortcut + description: Read a particular shortcut's details given its ID. + operationId: getshortcut + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetShortcutRequest" + description: GetShortcut request + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetShortcutResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-group: client.shortcuts + x-speakeasy-name-override: retrieve + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.shortcuts.retrieve(request={ + "alias": "", + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.shortcuts.retrieve({ + alias: "", + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Shortcuts.Retrieve(ctx, components.CreateGetShortcutRequestUnionGetShortcutRequest(\n components.GetShortcutRequest{\n Alias: \"\",\n },\n ))\n if err != nil {\n log.Fatal(err)\n }\n if res.GetShortcutResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.GetShortcutRequest; + import com.glean.api_client.glean_api_client.models.components.GetShortcutRequestUnion; + import com.glean.api_client.glean_api_client.models.operations.GetshortcutResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetShortcutRequestUnion req = GetShortcutRequestUnion.of(GetShortcutRequest.builder() + .alias("") + .build()); + + GetshortcutResponse res = sdk.client().shortcuts().retrieve() + .request(req) + .call(); + + if (res.getShortcutResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/listshortcuts: + post: + tags: + - Shortcuts + summary: List shortcuts + description: List shortcuts editable/owned by the currently authenticated user. + operationId: listshortcuts + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/ListShortcutsPaginatedRequest" + description: Filters, sorters, paging params required for pagination + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/ListShortcutsPaginatedResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-group: client.shortcuts + x-speakeasy-name-override: list + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.shortcuts.list(page_size=10, filters=[ + { + "field_name": "type", + "values": [ + { + "value": "Spreadsheet", + "relation_type": models.RelationType.EQUALS, + }, + { + "value": "Presentation", + "relation_type": models.RelationType.EQUALS, + }, + ], + }, + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.shortcuts.list({ + pageSize: 10, + filters: [ + { + fieldName: "type", + values: [ + { + value: "Spreadsheet", + relationType: "EQUALS", + }, + { + value: "Presentation", + relationType: "EQUALS", + }, + ], + }, + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Shortcuts.List(ctx, components.ListShortcutsPaginatedRequest{\n PageSize: 10,\n Filters: []components.FacetFilter{\n components.FacetFilter{\n FieldName: apiclientgo.String(\"type\"),\n Values: []components.FacetFilterValue{\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Spreadsheet\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n components.FacetFilterValue{\n Value: apiclientgo.String(\"Presentation\"),\n RelationType: components.RelationTypeEquals.ToPointer(),\n },\n },\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.ListShortcutsPaginatedResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.ListshortcutsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ListShortcutsPaginatedRequest req = ListShortcutsPaginatedRequest.builder() + .pageSize(10L) + .filters(List.of( + FacetFilter.builder() + .fieldName("type") + .values(List.of( + FacetFilterValue.builder() + .value("Spreadsheet") + .relationType(RelationType.EQUALS) + .build(), + FacetFilterValue.builder() + .value("Presentation") + .relationType(RelationType.EQUALS) + .build())) + .build())) + .build(); + + ListshortcutsResponse res = sdk.client().shortcuts().list() + .request(req) + .call(); + + if (res.listShortcutsPaginatedResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/updateshortcut: + post: + tags: + - Shortcuts + summary: Update shortcut + description: Updates the shortcut with the given ID. + operationId: updateshortcut + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/UpdateShortcutRequest" + description: Shortcut content. Id need to be specified for the shortcut. + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/UpdateShortcutResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-group: client.shortcuts + x-speakeasy-name-override: update + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.shortcuts.update(id=268238, added_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.ANSWER_MODERATOR, + ), + ], removed_roles=[ + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VERIFIER, + ), + models.UserRoleSpecification( + person=models.Person( + name="George Clooney", + obfuscated_id="abc123", + ), + role=models.UserRole.VERIFIER, + ), + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.shortcuts.update({ + id: 268238, + addedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "ANSWER_MODERATOR", + }, + ], + removedRoles: [ + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VERIFIER", + }, + { + person: { + name: "George Clooney", + obfuscatedId: "abc123", + }, + role: "VERIFIER", + }, + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Shortcuts.Update(ctx, components.UpdateShortcutRequest{\n ID: 268238,\n AddedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleAnswerModerator,\n },\n },\n RemovedRoles: []components.UserRoleSpecification{\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleVerifier,\n },\n components.UserRoleSpecification{\n Person: &components.Person{\n Name: \"George Clooney\",\n ObfuscatedID: \"abc123\",\n },\n Role: components.UserRoleVerifier,\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.UpdateShortcutResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.UpdateshortcutResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + UpdateShortcutRequest req = UpdateShortcutRequest.builder() + .id(268238L) + .addedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.ANSWER_MODERATOR) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .removedRoles(List.of( + UserRoleSpecification.builder() + .role(UserRole.VERIFIER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build(), + UserRoleSpecification.builder() + .role(UserRole.VERIFIER) + .person(Person.builder() + .name("George Clooney") + .obfuscatedId("abc123") + .build()) + .build())) + .build(); + + UpdateshortcutResponse res = sdk.client().shortcuts().update() + .request(req) + .call(); + + if (res.updateShortcutResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/summarize: + post: + tags: + - Summarize + summary: Summarize documents + description: Generate an AI summary of the requested documents. + operationId: summarize + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/SummarizeRequest" + description: Includes request params such as the query and specs of the documents to summarize. + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/SummarizeResponse" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: summarize + x-speakeasy-group: client.documents + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.documents.summarize(document_specs=[ + {}, + {}, + {}, + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.documents.summarize({ + documentSpecs: [ + {}, + {}, + {}, + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Documents.Summarize(ctx, components.SummarizeRequest{\n DocumentSpecs: []components.DocumentSpecUnion{\n components.CreateDocumentSpecUnionDocumentSpec1(\n components.DocumentSpec1{},\n ),\n components.CreateDocumentSpecUnionDocumentSpec1(\n components.DocumentSpec1{},\n ),\n components.CreateDocumentSpecUnionDocumentSpec1(\n components.DocumentSpec1{},\n ),\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.SummarizeResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.SummarizeResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + SummarizeRequest req = SummarizeRequest.builder() + .documentSpecs(List.of( + DocumentSpecUnion.of(DocumentSpec1.builder() + .build()), + DocumentSpecUnion.of(DocumentSpec1.builder() + .build()), + DocumentSpecUnion.of(DocumentSpec1.builder() + .build()))) + .build(); + + SummarizeResponse res = sdk.client().documents().summarize() + .request(req) + .call(); + + if (res.summarizeResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/addverificationreminder: + post: + tags: + - Verification + summary: Create verification + description: Creates a verification reminder for the document. Users can create verification reminders from different product surfaces. + operationId: addverificationreminder + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/ReminderRequest" + description: Details about the reminder. + required: true + x-exportParamName: ReminderRequest + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/Verification" + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Document does not exist, does not support verification or user cannot access document + "429": + description: Too Many Requests + x-speakeasy-name-override: addReminder + x-speakeasy-group: client.verification + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.verification.add_reminder(document_id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.verification.addReminder({ + documentId: "", + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Verification.AddReminder(ctx, components.ReminderRequest{\n DocumentID: \"\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.Verification != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.ReminderRequest; + import com.glean.api_client.glean_api_client.models.operations.AddverificationreminderResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ReminderRequest req = ReminderRequest.builder() + .documentId("") + .build(); + + AddverificationreminderResponse res = sdk.client().verification().addReminder() + .request(req) + .call(); + + if (res.verification().isPresent()) { + // handle response + } + } + } + /rest/api/v1/listverifications: + post: + tags: + - Verification + summary: List verifications + description: Returns the information to be rendered in verification dashboard. Includes information for each document owned by user regarding their verifications. + operationId: listverifications + x-visibility: Public + x-codegen-request-body-name: payload + parameters: + - in: query + name: count + description: Maximum number of documents to return + required: false + schema: + type: integer + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/VerificationFeed" + "400": + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: list + x-speakeasy-group: client.verification + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.verification.list() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.verification.list(); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Verification.List(ctx, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.VerificationFeed != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.ListverificationsResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ListverificationsResponse res = sdk.client().verification().list() + .call(); + + if (res.verificationFeed().isPresent()) { + // handle response + } + } + } + /rest/api/v1/verify: + post: + tags: + - Verification + summary: Update verification + description: Verify documents to keep the knowledge up to date within customer corpus. + operationId: verify + x-visibility: Public + x-codegen-request-body-name: payload + parameters: [] + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/VerifyRequest" + description: Details about the verification request. + required: true + x-exportParamName: VerifyRequest + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/Verification" + "400": + description: Invalid request + "401": + description: Not Authorized + "403": + description: Document does not exist, does not support verification or user cannot access document + "429": + description: Too Many Requests + x-speakeasy-name-override: verify + x-speakeasy-group: client.verification + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.verification.verify(document_id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.verification.verify({ + documentId: "", + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Verification.Verify(ctx, components.VerifyRequest{\n DocumentID: \"\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.Verification != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.VerifyRequest; + import com.glean.api_client.glean_api_client.models.operations.VerifyResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + VerifyRequest req = VerifyRequest.builder() + .documentId("") + .build(); + + VerifyResponse res = sdk.client().verification().verify() + .request(req) + .call(); + + if (res.verification().isPresent()) { + // handle response + } + } + } + /rest/api/v1/tools/list: + get: + summary: List available tools + description: Returns a filtered set of available tools based on optional tool name parameters. If no filters are provided, all available tools are returned. + x-visibility: Preview + parameters: + - in: query + name: toolNames + description: Optional array of tool names to filter by + required: false + schema: + type: array + items: + type: string + style: form + explode: false + responses: + "200": + description: Successful operation + content: + application/json: + schema: + $ref: "#/components/schemas/ToolsListResponse" + "400": + description: Bad Request + "401": + description: Unauthorized + "404": + description: Not Found + "429": + description: Too Many Requests + tags: + - Tools + x-speakeasy-name-override: list + x-speakeasy-group: client.tools + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.tools.list() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.tools.list(); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Tools.List(ctx, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.ToolsListResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.GetRestApiV1ToolsListResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetRestApiV1ToolsListResponse res = sdk.client().tools().list() + .call(); + + if (res.toolsListResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/tools/call: + post: + summary: Execute the specified tool + description: Execute the specified tool with provided parameters + x-visibility: Preview + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/ToolsCallRequest" + responses: + "200": + description: Successful operation + content: + application/json: + schema: + $ref: "#/components/schemas/ToolsCallResponse" + "400": + description: Bad Request + "401": + description: Unauthorized + "404": + description: Not Found + "429": + description: Too Many Requests + tags: + - Tools + x-speakeasy-name-override: run + x-speakeasy-group: client.tools + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.tools.run(name="", parameters={ + "key": { + "name": "", + "value": "", + }, + }) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.tools.run({ + name: "", + parameters: { + "key": { + name: "", + value: "", + }, + }, + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Tools.Run(ctx, components.ToolsCallRequest{\n Name: \"\",\n Parameters: map[string]components.ToolsCallParameter{\n \"key\": components.ToolsCallParameter{\n Name: \"\",\n Value: \"\",\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.ToolsCallResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.ToolsCallParameter; + import com.glean.api_client.glean_api_client.models.components.ToolsCallRequest; + import com.glean.api_client.glean_api_client.models.operations.PostRestApiV1ToolsCallResponse; + import java.lang.Exception; + import java.util.Map; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ToolsCallRequest req = ToolsCallRequest.builder() + .name("") + .parameters(Map.ofEntries( + Map.entry("key", ToolsCallParameter.builder() + .name("") + .value("") + .build()))) + .build(); + + PostRestApiV1ToolsCallResponse res = sdk.client().tools().run() + .request(req) + .call(); + + if (res.toolsCallResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/governance/data/policies/{id}: + get: + description: Fetches the specified policy version, or the latest if no version is provided. + summary: Gets specified Policy. + operationId: getpolicy + x-visibility: Public + tags: + - Governance + parameters: + - name: id + in: path + description: The id of the policy to fetch. + required: true + schema: + type: string + - name: version + in: query + description: The version of the policy to fetch. Each time a policy is updated, the older version is still stored. If this is left empty, the latest policy is fetched. + required: false + schema: + type: integer + format: int64 + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetDlpReportResponse" + "403": + description: Permissions error + "500": + description: Internal error + x-speakeasy-group: client.governance.data.policies + x-speakeasy-name-override: retrieve + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.governance.data.policies.retrieve(id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.governance.data.policies.retrieve(""); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Governance.Data.Policies.Retrieve(ctx, \"\", nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.GetDlpReportResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.GetpolicyResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetpolicyResponse res = sdk.client().governance().data().policies().retrieve() + .id("") + .call(); + + if (res.getDlpReportResponse().isPresent()) { + // handle response + } + } + } + post: + description: Updates an existing policy. + summary: Updates an existing policy. + operationId: updatepolicy + tags: + - Governance + parameters: + - name: id + in: path + description: The id of the policy to fetch. + required: true + schema: + type: string + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/UpdateDlpReportRequest" + required: true + responses: + "200": + description: OK + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/UpdateDlpReportResponse" + "403": + description: Permissions error + "500": + description: Internal error + x-speakeasy-group: client.governance.data.policies + x-speakeasy-name-override: update + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.governance.data.policies.update(id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.governance.data.policies.update({}, ""); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Governance.Data.Policies.Update(ctx, \"\", components.UpdateDlpReportRequest{})\n if err != nil {\n log.Fatal(err)\n }\n if res.UpdateDlpReportResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.UpdateDlpReportRequest; + import com.glean.api_client.glean_api_client.models.operations.UpdatepolicyResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + UpdatepolicyResponse res = sdk.client().governance().data().policies().update() + .id("") + .updateDlpReportRequest(UpdateDlpReportRequest.builder() + .build()) + .call(); + + if (res.updateDlpReportResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/governance/data/policies: + get: + description: Lists policies with filtering. + summary: Lists policies. + operationId: listpolicies + x-visibility: Public + tags: + - Governance + parameters: + - name: autoHide + in: query + description: Filter to return reports with a given value of auto-hide. + required: false + schema: + type: boolean + - name: frequency + in: query + description: Filter to return reports with a given frequency. + required: false + schema: + type: string + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/ListDlpReportsResponse" + "403": + description: Permissions error + "500": + description: Internal error + x-speakeasy-group: client.governance.data.policies + x-speakeasy-name-override: list + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.governance.data.policies.list() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.governance.data.policies.list(); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Governance.Data.Policies.List(ctx, nil, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.ListDlpReportsResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.ListpoliciesResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ListpoliciesResponse res = sdk.client().governance().data().policies().list() + .call(); + + if (res.listDlpReportsResponse().isPresent()) { + // handle response + } + } + } + post: + description: Creates a new policy with specified specifications and returns its id. + summary: Creates new policy. + operationId: createpolicy + x-visibility: Public + tags: + - Governance + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/CreateDlpReportRequest" + required: true + responses: + "200": + description: OK + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/CreateDlpReportResponse" + "403": + description: Permissions error + "500": + description: Internal error + x-speakeasy-group: client.governance.data.policies + x-speakeasy-name-override: create + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.governance.data.policies.create() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.governance.data.policies.create({}); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Governance.Data.Policies.Create(ctx, components.CreateDlpReportRequest{})\n if err != nil {\n log.Fatal(err)\n }\n if res.CreateDlpReportResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.CreateDlpReportRequest; + import com.glean.api_client.glean_api_client.models.operations.CreatepolicyResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + CreateDlpReportRequest req = CreateDlpReportRequest.builder() + .build(); + + CreatepolicyResponse res = sdk.client().governance().data().policies().create() + .request(req) + .call(); + + if (res.createDlpReportResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/governance/data/policies/{id}/download: + get: + description: Downloads CSV violations report for a specific policy id. This does not support continuous policies. + summary: Downloads violations CSV for policy. + operationId: downloadpolicycsv + x-visibility: Public + tags: + - Governance + parameters: + - name: id + in: path + description: The id of the policy to download violations for. + required: true + schema: + type: string + responses: + "200": + description: Downloads csv of batch policy violations. + content: + text/csv; charset=UTF-8: + schema: + description: CSV of all the violations found for this policy. + type: string + "403": + description: Permissions error + "500": + description: Internal error + x-speakeasy-group: client.governance.data.policies + x-speakeasy-name-override: download + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.governance.data.policies.download(id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.governance.data.policies.download(""); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Governance.Data.Policies.Download(ctx, \"\")\n if err != nil {\n log.Fatal(err)\n }\n if res.Res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.DownloadpolicycsvResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DownloadpolicycsvResponse res = sdk.client().governance().data().policies().download() + .id("") + .call(); + + if (res.res().isPresent()) { + // handle response + } + } + } + /rest/api/v1/governance/data/reports: + post: + description: Creates a new one-time report and executes its batch job. + summary: Creates new one-time report. + operationId: createreport + x-visibility: Public + tags: + - Governance + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/UpdateDlpConfigRequest" + required: true + responses: + "200": + description: OK + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/UpdateDlpConfigResponse" + "403": + description: Permissions error + "500": + description: Internal error + x-speakeasy-group: client.governance.data.reports + x-speakeasy-name-override: create + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.governance.data.reports.create() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.governance.data.reports.create({}); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Governance.Data.Reports.Create(ctx, components.UpdateDlpConfigRequest{})\n if err != nil {\n log.Fatal(err)\n }\n if res.UpdateDlpConfigResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.UpdateDlpConfigRequest; + import com.glean.api_client.glean_api_client.models.operations.CreatereportResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + UpdateDlpConfigRequest req = UpdateDlpConfigRequest.builder() + .build(); + + CreatereportResponse res = sdk.client().governance().data().reports().create() + .request(req) + .call(); + + if (res.updateDlpConfigResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/governance/data/reports/{id}/download: + get: + description: Downloads CSV violations report for a specific report id. + summary: Downloads violations CSV for report. + operationId: downloadreportcsv + x-visibility: Public + tags: + - Governance + parameters: + - name: id + in: path + description: The id of the report to download violations for. + required: true + schema: + type: string + responses: + "200": + description: Downloads csv of one-time report violations. + content: + text/csv; charset=UTF-8: + schema: + description: CSV of all the violations found for this report. + type: string + "403": + description: Permissions error + "500": + description: Internal error + x-speakeasy-group: client.governance.data.reports + x-speakeasy-name-override: download + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.governance.data.reports.download(id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.governance.data.reports.download(""); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Governance.Data.Reports.Download(ctx, \"\")\n if err != nil {\n log.Fatal(err)\n }\n if res.Res != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.DownloadreportcsvResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DownloadreportcsvResponse res = sdk.client().governance().data().reports().download() + .id("") + .call(); + + if (res.res().isPresent()) { + // handle response + } + } + } + /rest/api/v1/governance/data/reports/{id}/status: + get: + description: Fetches the status of the run corresponding to the report-id. + summary: Fetches report run status. + operationId: getreportstatus + x-visibility: Public + tags: + - Governance + parameters: + - name: id + in: path + description: The id of the report to get run status for. + required: true + schema: + type: string + responses: + "200": + description: Fetches status of report run. + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/ReportStatusResponse" + "403": + description: Permissions error + "500": + description: Internal error + x-speakeasy-group: client.governance.data.reports + x-speakeasy-name-override: status + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.governance.data.reports.status(id="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.governance.data.reports.status(""); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Governance.Data.Reports.Status(ctx, \"\")\n if err != nil {\n log.Fatal(err)\n }\n if res.ReportStatusResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.GetreportstatusResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetreportstatusResponse res = sdk.client().governance().data().reports().status() + .id("") + .call(); + + if (res.reportStatusResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/governance/documents/visibilityoverrides: + get: + description: Fetches the visibility override status of the documents passed. + summary: Fetches documents visibility. + operationId: getdocvisibility + x-visibility: Public + tags: + - Governance + parameters: + - name: docIds + in: query + description: List of doc-ids which will have their hide status fetched. + schema: + type: array + items: + type: string + responses: + "200": + description: The visibility status of documents + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/GetDocumentVisibilityOverridesResponse" + "403": + description: Permissions error + "500": + description: Internal error + x-speakeasy-group: client.governance.documents.visibilityoverrides + x-speakeasy-name-override: list + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.governance.documents.visibilityoverrides.list() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.governance.documents.visibilityoverrides.list(); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Governance.Documents.Visibilityoverrides.List(ctx, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.GetDocumentVisibilityOverridesResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.GetdocvisibilityResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetdocvisibilityResponse res = sdk.client().governance().documents().visibilityoverrides().list() + .call(); + + if (res.getDocumentVisibilityOverridesResponse().isPresent()) { + // handle response + } + } + } + post: + description: Sets the visibility-override state of the documents specified, effectively hiding or un-hiding documents. + summary: Hide/Un-hide docs. + operationId: setdocvisibility + x-visibility: Public + tags: + - Governance + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/UpdateDocumentVisibilityOverridesRequest" + required: true + responses: + "200": + description: OK + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/UpdateDocumentVisibilityOverridesResponse" + "403": + description: Permissions error + "500": + description: Internal error + x-speakeasy-group: client.governance.documents.visibilityoverrides + x-speakeasy-name-override: create + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.governance.documents.visibilityoverrides.create() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.governance.documents.visibilityoverrides.create({}); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Governance.Documents.Visibilityoverrides.Create(ctx, components.UpdateDocumentVisibilityOverridesRequest{})\n if err != nil {\n log.Fatal(err)\n }\n if res.UpdateDocumentVisibilityOverridesResponse != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.UpdateDocumentVisibilityOverridesRequest; + import com.glean.api_client.glean_api_client.models.operations.SetdocvisibilityResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + UpdateDocumentVisibilityOverridesRequest req = UpdateDocumentVisibilityOverridesRequest.builder() + .build(); + + SetdocvisibilityResponse res = sdk.client().governance().documents().visibilityoverrides().create() + .request(req) + .call(); + + if (res.updateDocumentVisibilityOverridesResponse().isPresent()) { + // handle response + } + } + } + /rest/api/v1/chat#stream: + post: + tags: + - Chat + summary: Chat + description: Have a conversation with Glean AI. + operationId: chatStream + x-visibility: Public + x-codegen-request-body-name: payload + parameters: + - $ref: "#/components/parameters/timezoneOffset" + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/ChatRequest" + examples: + defaultExample: + value: + messages: + - author: USER + messageType: CONTENT + fragments: + - text: What are the company holidays this year? + gptAgentExample: + value: + agentConfig: + agent: GPT + messages: + - author: USER + messageType: CONTENT + fragments: + - text: Who was the first person to land on the moon? + description: Includes chat history for Glean AI to respond to. + required: true + x-exportParamName: Request + responses: + "200": + description: OK + content: + text/plain: + schema: + $ref: "#/components/schemas/ChatRequestStream" + examples: + defaultExample: + value: + messages: + - author: GLEAN_AI + messageType: CONTENT + hasMoreFragments: false + agentConfig: + agent: DEFAULT + mode: DEFAULT + fragments: + - text: There are no holidays! + streamingExample: + value: + messages: + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: true + fragments: null + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: true + fragments: null + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: true + fragments: + - text: e are + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: true + fragments: + - text: no hol + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + hasMoreFragments: false + fragments: + - text: idays! + updateResponse: + value: + messages: + - author: GLEAN_AI + messageType: UPDATE + agentConfig: + agent: DEFAULT + mode: DEFAULT + fragments: + - text: "**Reading:**" + - structuredResults: + - document: + id: "123" + title: Company Handbook + citationResponse: + value: + messages: + - author: GLEAN_AI + messageType: CONTENT + agentConfig: + agent: DEFAULT + mode: DEFAULT + citations: + - sourceDocument: + id: "123" + title: Company Handbook + referenceRanges: + - textRange: + startIndex: 0 + endIndex: 12 + type: CITATION + "400": + description: Invalid request + "401": + description: Not Authorized + "408": + description: Request Timeout + "429": + description: Too Many Requests + x-speakeasy-group: client.chat + x-speakeasy-name-override: createStream + x-speakeasy-usage-example: true + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.client.chat.create_stream(messages=[ + { + "fragments": [ + models.ChatMessageFragment( + text="What are the company holidays this year?", + ), + ], + }, + ], timeout_millis=30000) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.client.chat.createStream({ + messages: [ + { + fragments: [ + { + text: "What are the company holidays this year?", + }, + ], + }, + ], + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Client.Chat.CreateStream(ctx, components.ChatRequest{\n Messages: []components.ChatMessage{\n components.ChatMessage{\n Fragments: []components.ChatMessageFragment{\n components.ChatMessageFragment{\n Text: apiclientgo.String(\"What are the company holidays this year?\"),\n },\n },\n },\n },\n }, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res.ChatRequestStream != nil {\n // handle response\n }\n}" + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.ChatStreamResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ChatStreamResponse res = sdk.client().chat().createStream() + .chatRequest(ChatRequest.builder() + .messages(List.of( + ChatMessage.builder() + .fragments(List.of( + ChatMessageFragment.builder() + .text("What are the company holidays this year?") + .build())) + .build())) + .build()) + .call(); + + if (res.chatRequestStream().isPresent()) { + // handle response + } + } + } +components: + securitySchemes: + APIToken: + scheme: bearer + type: http + schemas: + ActivityEventParams: + properties: + bodyContent: + description: The HTML content of the page body. + type: string + datasourceInstance: + type: string + description: The full datasource instance name inferred from the URL of the event + datasource: + type: string + description: The datasource without the instance inferred from the URL of the event + instanceOnlyName: + type: string + description: The instance only name of the datasource instance, e.g. 1 for jira_1, inferred from the URL of the event + duration: + description: Length in seconds of the activity. For VIEWS, this represents the amount the page was visible in the foreground. + type: integer + query: + description: The user's search query associated with a SEARCH. + type: string + referrer: + description: The referring URL of the VIEW or SEARCH. + type: string + title: + description: The page title associated with the URL of the event + type: string + truncated: + description: Indicates that the parameters are incomplete and more parameters may be sent with the same action+timestamp+URL in the future. This is used for sending the duration when a `VIEW` is finished. + type: boolean + ActivityEvent: + required: + - action + - source + - timestamp + - url + properties: + id: + type: string + description: Universally unique identifier of the event. To allow for reliable retransmission, only the earliest received event of a given UUID is considered valid by the server and subsequent are ignored. + action: + type: string + description: The type of activity this represents. + x-enumDescriptions: + VIEW: Represents a visit to the given `url`. + EDIT: Represents an edit of the document represented by the `url`. + SEARCH: Represents a search performed at the given `url`. + COMMENT: Represents a comment on the document represented by the `url`. + CRAWL: Represents an explicit request to index the given `url` along with associated attributes in this payload. + HISTORICAL_SEARCH: Represents a search performed at the given `url` as indicated by the user's history. + HISTORICAL_VIEW: Represents a visit to the given `url` as indicated by the user's history. + enum: + - VIEW + - EDIT + - SEARCH + - COMMENT + - CRAWL + - HISTORICAL_SEARCH + - HISTORICAL_VIEW + params: + $ref: "#/components/schemas/ActivityEventParams" + timestamp: + type: string + description: The ISO 8601 timestamp when the activity began. + format: date-time + url: + description: The URL of the activity. + type: string + Activity: + required: + - events + properties: + events: + type: array + items: + $ref: "#/components/schemas/ActivityEvent" + example: + events: + - url: https://example.com/ + action: HISTORICAL_VIEW + timestamp: "2000-01-23T04:56:07.000Z" + - url: https://example.com/search?q=query + action: SEARCH + timestamp: "2000-01-23T04:56:07.000Z" + params: + query: query + - url: https://example.com/ + action: VIEW + timestamp: "2000-01-23T04:56:07.000Z" + params: + duration: 20 + referrer: https://example.com/document + SessionInfo: + properties: + sessionTrackingToken: + type: string + description: A unique token for this session. A new session (and token) is created when the user issues a request from a new tab or when our server hasn't seen activity for more than 10 minutes from a tab. + tabId: + type: string + description: A unique id for all requests a user makes from a given tab, no matter how far apart. A new tab id is only generated when a user issues a request from a new tab. + lastSeen: + type: string + format: date-time + description: The last time the server saw this token. + lastQuery: + type: string + description: The last query seen by the server. + User: + properties: + userID: + description: An opaque user ID for the claimed authority (i.e., the actas param, or the origid if actas is not specified). + type: string + origID: + description: An opaque user ID for the authenticated user (ignores actas). + type: string + FeedbackChatExchange: + properties: + timestamp: + type: integer + format: int64 + description: Unix timestamp in millis for the chat request. + agent: + type: string + description: Either DEFAULT (company knowledge) or GPT (world knowledge). + userQuery: + type: string + description: Initial query entered by the user. + searchQuery: + type: string + description: Search query performed by the agent. + resultDocuments: + type: array + description: List of documents read by the agent. + items: + properties: + title: + type: string + url: + type: string + response: + type: string + ManualFeedbackInfo: + properties: + email: + type: string + description: The email address of the user who submitted the Feedback.event.MANUAL_FEEDBACK event. + source: + type: string + description: The source associated with the Feedback.event.MANUAL_FEEDBACK event. + enum: + - AUTOCOMPLETE + - CALENDAR + - CHAT + - CHAT_GENERAL + - CONCEPT_CARD + - DESKTOP_APP + - DISAMBIGUATION_CARD + - EXPERT_DETECTION + - FEED + - GENERATED_Q_AND_A + - INLINE_MENU + - NATIVE_RESULT + - Q_AND_A + - RELATED_QUESTIONS + - REPORT_ISSUE + - SCIOBOT + - SEARCH + - SIDEBAR + - SUMMARY + issue: + type: string + description: The issue the user indicated in the feedback. + deprecated: true + issues: + type: array + description: The issue(s) the user indicated in the feedback. + items: + type: string + enum: + - INACCURATE_RESPONSE + - INCOMPLETE_OR_NO_ANSWER + - INCORRECT_CITATION + - MISSING_CITATION + - OTHER + - OUTDATED_RESPONSE + - RESULT_MISSING + - RESULT_SHOULD_NOT_APPEAR + - RESULTS_HELPFUL + - RESULTS_POOR_ORDER + - TOO_MUCH_ONE_KIND + imageUrls: + type: array + items: + type: string + description: URLs of images uploaded by user when providing feedback + query: + type: string + description: The query associated with the Feedback.event.MANUAL_FEEDBACK event. + obscuredQuery: + type: string + description: The query associated with the Feedback.event.MANUAL_FEEDBACK event, but obscured such that the vowels are replaced with special characters. For search feedback events only. + activeTab: + type: string + description: Which tabs the user had chosen at the time of the Feedback.event.MANUAL_FEEDBACK event. For search feedback events only. + comments: + type: string + description: The comments users can optionally add to the Feedback.event.MANUAL_FEEDBACK events. + searchResults: + type: array + items: + type: string + description: The array of search result Glean Document IDs, ordered by top to bottom result. + previousMessages: + type: array + items: + type: string + description: The array of previous messages in a chat session, ordered by oldest to newest. + chatTranscript: + type: array + items: + $ref: "#/components/schemas/FeedbackChatExchange" + description: Array of previous request/response exchanges, ordered by oldest to newest. + numQueriesFromFirstRun: + type: integer + description: How many times this query has been run in the past. + vote: + type: string + description: The vote associated with the Feedback.event.MANUAL_FEEDBACK event. + enum: + - UPVOTE + - DOWNVOTE + rating: + type: integer + description: A rating associated with the user feedback. The value will be between one and the maximum given by ratingScale, inclusive. + ratingKey: + type: string + description: A description of the rating that contextualizes how it appeared to the user, e.g. "satisfied". + ratingScale: + type: integer + description: The scale of comparison for a rating associated with the feedback. Rating values start from one and go up to the maximum specified by ratingScale. For example, a five-option satisfaction rating will have a ratingScale of 5 and a thumbs-up/thumbs-down rating will have a ratingScale of 2. + SeenFeedbackInfo: + properties: + isExplicit: + type: boolean + description: The confidence of the user seeing the object is high because they explicitly interacted with it e.g. answer impression in SERP with additional user interaction. + UserViewInfo: + properties: + docId: + type: string + description: Unique Glean Document ID of the associated document. + docTitle: + type: string + description: Title of associated document. + docUrl: + type: string + description: URL of associated document. + WorkflowFeedbackInfo: + properties: + source: + type: string + enum: + - ZERO_STATE + - LIBRARY + - HOMEPAGE + description: Where the feedback of the workflow originated from + Feedback: + required: + - event + - trackingTokens + properties: + id: + type: string + description: Universally unique identifier of the event. To allow for reliable retransmission, only the earliest received event of a given UUID is considered valid by the server and subsequent are ignored. + category: + type: string + description: The feature category to which the feedback applies. These should be broad product areas such as Announcements, Answers, Search, etc. rather than specific components or UI treatments within those areas. + enum: + - ANNOUNCEMENT + - AUTOCOMPLETE + - COLLECTIONS + - FEED + - SEARCH + - CHAT + - NTP + - WORKFLOWS + - SUMMARY + - GENERAL + - PROMPTS + trackingTokens: + type: array + description: A list of server-generated trackingTokens to which this event applies. + items: + type: string + event: + type: string + description: The action the user took within a Glean client with respect to the object referred to by the given `trackingToken`. + x-enumDescriptions: + CLICK: The object's primary link was clicked with the intent to view its full representation. Depending on the object type, this may imply an external navigation or navigating to a new page or view within the Glean app. + CONTAINER_CLICK: A link to the object's parent container (e.g. the folder in which it's located) was clicked. + COPY_LINK: The user copied a link to the primary link. + CREATE: The user creates a document. + DISMISS: The user dismissed the object such that it was hidden from view. + DOWNVOTE: The user gave feedback that the object was not useful. + EMAIL: The user attempted to send an email. + EXECUTE: The user executed the object (e.g. ran a workflow). + FILTER: The user applied a filter. + FIRST_TOKEN: The first token of a streaming response is received. + FOCUS_IN: The user clicked into an interactive element, e.g. the search box. + LAST_TOKEN: The final token of a streaming response is received. + MANUAL_FEEDBACK: The user submitted textual manual feedback regarding the object. + MARK_AS_READ: The user explicitly marked the content as read. + MESSAGE: The user attempted to send a message using their default messaing app. + MIDDLE_CLICK: The user middle clicked the object's primary link with the intent to open its full representation in a new tab. + PAGE_BLUR: The user puts a page out of focus but keeps it in the background. + PAGE_FOCUS: The user puts a page in focus, meaning it is the first to receive keyboard events. + PAGE_LEAVE: The user leaves a page and it is unloaded (by clicking a link, closing the tab/window, etc). + PREVIEW: The user clicked the object's inline preview affordance. + RIGHT_CLICK: The user right clicked the object's primary link. This may indicate an intent to open it in a new tab or copy it. + SECTION_CLICK: The user clicked a link to a subsection of the primary object. + SEEN: The user has likely seen the object (e.g. took action to make the object visible within the user's viewport). + SHARE: The user shared the object with another user. + SHOW_MORE: The user clicked the object's show more affordance. + UPVOTE: The user gave feedback that the object was useful. + VIEW: The object was visible within the user's viewport. + VISIBLE: The object was visible within the user's viewport. + enum: + - CLICK + - CONTAINER_CLICK + - COPY_LINK + - CREATE + - DISMISS + - DOWNVOTE + - EMAIL + - EXECUTE + - FILTER + - FIRST_TOKEN + - FOCUS_IN + - LAST_TOKEN + - MANUAL_FEEDBACK + - MARK_AS_READ + - MESSAGE + - MIDDLE_CLICK + - PAGE_BLUR + - PAGE_FOCUS + - PAGE_LEAVE + - PREVIEW + - RELATED_CLICK + - RIGHT_CLICK + - SECTION_CLICK + - SEEN + - SHARE + - SHOW_MORE + - UPVOTE + - VIEW + - VISIBLE + position: + type: integer + description: Position of the element in the case that the client controls order (such as feed and autocomplete). + payload: + type: string + description: For type MANUAL_FEEDBACK, contains string of user feedback. For autocomplete, partial query string. For feed, string of user feedback in addition to manual feedback signals extracted from all suggested content. + sessionInfo: + $ref: "#/components/schemas/SessionInfo" + timestamp: + type: string + description: The ISO 8601 timestamp when the event occured. + format: date-time + user: + $ref: "#/components/schemas/User" + pathname: + type: string + description: The path the client was at when the feedback event triggered. + channels: + type: array + description: Where the feedback will be sent, e.g. to Glean, the user's company, or both. If no channels are specified, feedback will go only to Glean. + items: + type: string + enum: + - COMPANY + - GLEAN + url: + type: string + description: The URL the client was at when the feedback event triggered. + uiTree: + description: The UI element tree associated with the event, if any. + items: + type: string + type: array + uiElement: + type: string + description: The UI element associated with the event, if any. + manualFeedbackInfo: + $ref: "#/components/schemas/ManualFeedbackInfo" + seenFeedbackInfo: + $ref: "#/components/schemas/SeenFeedbackInfo" + userViewInfo: + $ref: "#/components/schemas/UserViewInfo" + workflowFeedbackInfo: + $ref: "#/components/schemas/WorkflowFeedbackInfo" + applicationId: + type: string + description: The application ID of the client that sent the feedback event. + agentId: + type: string + description: The agent ID of the client that sent the feedback event. + example: + trackingTokens: + - trackingTokens + event: VIEW + StructuredTextMutableProperties: + required: + - text + properties: + text: + type: string + example: From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light. + ConnectorType: + type: string + description: The source from which document content was pulled, e.g. an API crawl or browser history + enum: + - API_CRAWL + - BROWSER_CRAWL + - BROWSER_HISTORY + - BUILTIN + - FEDERATED_SEARCH + - PUSH_API + - WEB_CRAWL + - NATIVE_HISTORY + DocumentContent: + properties: + fullTextList: + type: array + items: + type: string + description: The plaintext content of the document. + Document: + properties: + id: + type: string + description: The Glean Document ID. + datasource: + type: string + description: The app or other repository type from which the document was extracted + connectorType: + $ref: "#/components/schemas/ConnectorType" + docType: + type: string + description: The datasource-specific type of the document (e.g. for Jira issues, this is the issue type such as Bug or Feature Request). + content: + $ref: "#/components/schemas/DocumentContent" + containerDocument: + $ref: "#/components/schemas/Document" + parentDocument: + $ref: "#/components/schemas/Document" + title: + type: string + description: The title of the document. + url: + type: string + description: A permalink for the document. + metadata: + $ref: "#/components/schemas/DocumentMetadata" + sections: + type: array + description: A list of content sub-sections in the document, e.g. text blocks with different headings in a Drive doc or Confluence page. + items: + $ref: "#/components/schemas/DocumentSection" + SearchProviderInfo: + properties: + name: + type: string + description: Name of the search provider. + logoUrl: + type: string + description: URL to the provider's logo. + searchLinkUrlTemplate: + type: string + description: URL template that can be used to perform the suggested search by replacing the {query} placeholder with the query suggestion. + example: + name: Google + logo: https://app.glean.com/images/feather/globe.svg + searchLinkUrlTemplate: https://www.google.com/search?q={query}&hl=en + FacetFilterValue: + properties: + value: + type: string + example: Spreadsheet + relationType: + type: string + enum: + - EQUALS + - ID_EQUALS + - LT + - GT + example: EQUALS + isNegated: + type: boolean + deprecated: true + description: DEPRECATED - please use relationType instead + FacetFilter: + properties: + fieldName: + type: string + example: owner + values: + type: array + items: + $ref: "#/components/schemas/FacetFilterValue" + description: Within a single FacetFilter, the values are to be treated like an OR. For example, fieldName type with values [EQUALS Presentation, EQUALS Spreadsheet] means we want to show a document if it's a Presentation OR a Spreadsheet. + groupName: + type: string + example: Spreadsheet + description: Indicates the value of a facet, if any, that the given facet is grouped under. This is only used for nested facets, for example, fieldName could be owner and groupName would be Spreadsheet if showing all owners for spreadsheets as a nested facet. + example: + fieldName: type + values: + - value: Spreadsheet + relationType: EQUALS + - value: Presentation + relationType: EQUALS + FacetFilterSet: + properties: + filters: + type: array + items: + $ref: "#/components/schemas/FacetFilter" + description: Within a single FacetFilterSet, the filters are treated as AND. For example, owner Sumeet and type Spreadsheet shows documents that are by Sumeet AND are Spreadsheets. + FacetBucketFilter: + properties: + facet: + type: string + description: The facet whose buckets should be filtered. + prefix: + type: string + description: The per-term prefix that facet buckets should be filtered on. + AuthToken: + required: + - accessToken + - datasource + properties: + accessToken: + type: string + datasource: + type: string + scope: + type: string + tokenType: + type: string + authUser: + description: Used by Google to indicate the index of the logged in user. Useful for generating hyperlinks that support multilogin. + type: string + expiration: + description: Unix timestamp when this token expires (in seconds since epoch UTC). + type: integer + format: int64 + example: + accessToken: 123abc + datasource: gmail + scope: email profile https://www.googleapis.com/auth/gmail.readonly + tokenType: Bearer + authUser: "1" + DocumentSpec: + oneOf: + - type: object + properties: + url: + type: string + description: The URL of the document. + - type: object + properties: + id: + type: string + description: The ID of the document. + - type: object + properties: + ugcType: + type: string + enum: + - ANNOUNCEMENTS + - ANSWERS + - COLLECTIONS + - SHORTCUTS + description: The type of the user generated content (UGC datasource). + contentId: + type: integer + description: The id for user generated content. + docType: + type: string + description: The specific type of the user generated content type. + RestrictionFilters: + properties: + containerSpecs: + description: "Specifications for containers that should be used as part of the restriction (include/exclude). Memberships are recursively defined for a subset of datasources (currently: SharePoint, OneDrive, Google Drive, and Confluence). Please contact the Glean team to enable this for more datasources. Recursive memberships do not apply for Collections." + type: array + items: + $ref: "#/components/schemas/DocumentSpec" + SearchRequestOptions: + required: + - facetBucketSize + properties: + datasourceFilter: + type: string + description: Filter results to a single datasource name (e.g. gmail, slack). All results are returned if missing. + datasourcesFilter: + type: array + items: + type: string + description: Filter results to one or more datasources (e.g. gmail, slack). All results are returned if missing. + queryOverridesFacetFilters: + type: boolean + description: If true, the operators in the query are taken to override any operators in facetFilters in the case of conflict. This is used to correctly set rewrittenFacetFilters and rewrittenQuery. + facetFilters: + type: array + items: + $ref: "#/components/schemas/FacetFilter" + description: A list of filters for the query. An AND is assumed between different facetFilters. For example, owner Sumeet and type Spreadsheet shows documents that are by Sumeet AND are Spreadsheets. + facetFilterSets: + type: array + items: + $ref: "#/components/schemas/FacetFilterSet" + description: A list of facet filter sets that will be OR'ed together. SearchRequestOptions where both facetFilterSets and facetFilters set are considered as bad request. Callers should set only one of these fields. + facetBucketFilter: + $ref: "#/components/schemas/FacetBucketFilter" + facetBucketSize: + type: integer + description: The maximum number of FacetBuckets to return in each FacetResult. + defaultFacets: + type: array + items: + type: string + description: Facets for which FacetResults should be fetched and that don't apply to a particular datasource. If specified, these values will replace the standard default facets (last_updated_at, from, etc.). The requested facets will be returned alongside datasource-specific facets if searching a single datasource. + authTokens: + type: array + description: Auth tokens which may be used for non-indexed, federated results (e.g. Gmail). + items: + $ref: "#/components/schemas/AuthToken" + fetchAllDatasourceCounts: + type: boolean + description: Hints that the QE should return result counts (via the datasource facet result) for all supported datasources, rather than just those specified in the datasource[s]Filter + responseHints: + type: array + description: Array of hints containing which fields should be populated in the response. + items: + type: string + description: Hints for the response content. + x-enumDescriptions: + ALL_RESULT_COUNTS: Return result counts for each result set which has non-zero results, even when the request itself is limited to a subset. + FACET_RESULTS: Return only facet results. + QUERY_METADATA: Returns result counts for each result set which has non-zero results, as well as other information about the search such as suggested spelling corrections. + RESULTS: Return search result documents. + SPELLCHECK_METADATA: Return metadata pertaining to spellcheck results. + enum: + - ALL_RESULT_COUNTS + - FACET_RESULTS + - QUERY_METADATA + - RESULTS + - SPELLCHECK_METADATA + timezoneOffset: + type: integer + description: The offset of the client's timezone in minutes from UTC. e.g. PDT is -420 because it's 7 hours behind UTC. + disableSpellcheck: + type: boolean + description: Whether or not to disable spellcheck. + disableQueryAutocorrect: + type: boolean + description: Disables automatic adjustment of the input query for spelling corrections or other reasons. + returnLlmContentOverSnippets: + type: boolean + description: "[beta] Enables expanded content to be returned for LLM usage. The size of content per result returned should be modified using maxSnippetSize. Server may return less or more than what is specified in maxSnippetSize. For more details, https://docs.google.com/document/d/1CTOLSxWWT9WDEnHVLoCUaxbGYyXYP8kctPRF-RluSQY/edit. Requires sufficient permissions." + inclusions: + $ref: "#/components/schemas/RestrictionFilters" + description: A list of filters which restrict the search results to only the specified content. + exclusions: + $ref: "#/components/schemas/RestrictionFilters" + description: A list of filters specifying content to avoid getting search results from. Exclusions take precendence over inclusions and other query parameters, such as search operators and search facets. + example: + datasourceFilter: JIRA + datasourcesFilter: + - JIRA + queryOverridesFacetFilters: true + facetFilters: + - fieldName: fieldName + values: + - fieldValues + - fieldValues + - fieldName: fieldName + values: + - fieldValues + - fieldValues + TextRange: + required: + - startIndex + description: A subsection of a given string to which some special formatting should be applied. + properties: + startIndex: + type: integer + description: The inclusive start index of the range. + endIndex: + type: integer + description: The exclusive end index of the range. + type: + type: string + enum: + - BOLD + - CITATION + - HIGHLIGHT + - LINK + url: + type: string + description: The URL associated with the range, if applicable. For example, the linked URL for a LINK range. + document: + $ref: "#/components/schemas/Document" + description: A document corresponding to the range, if applicable. For example, the cited document for a CITATION range. + SearchRequestInputDetails: + properties: + hasCopyPaste: + type: boolean + description: Whether the associated query was at least partially copy-pasted. If subsequent requests are issued after a copy-pasted query is constructed (e.g. with facet modifications), this bit should continue to be set for those requests. + example: + hasCopyPaste: true + QuerySuggestion: + required: + - query + properties: + missingTerm: + type: string + description: A query term missing from the original query on which this suggestion is based. + query: + type: string + description: The query being suggested (e.g. enforcing the missing term from the original query). + searchProviderInfo: + $ref: "#/components/schemas/SearchProviderInfo" + description: Information about the search provider that generated this suggestion. + label: + type: string + description: A user-facing description to display for the suggestion. + datasource: + type: string + description: The datasource associated with the suggestion. + requestOptions: + $ref: "#/components/schemas/SearchRequestOptions" + ranges: + type: array + items: + $ref: "#/components/schemas/TextRange" + description: The bolded ranges within the query of the QuerySuggestion. + inputDetails: + $ref: "#/components/schemas/SearchRequestInputDetails" + example: + query: app:github type:pull author:mortimer + label: Mortimer's PRs + datasource: github + Person: + required: + - name + - obfuscatedId + properties: + name: + type: string + description: The display name. + obfuscatedId: + type: string + description: An opaque identifier that can be used to request metadata for a Person. + relatedDocuments: + type: array + items: + $ref: "#/components/schemas/RelatedDocuments" + description: A list of documents related to this person. + metadata: + $ref: "#/components/schemas/PersonMetadata" + example: + name: George Clooney + obfuscatedId: abc123 + Company: + required: + - name + properties: + name: + type: string + description: User-friendly display name. + profileUrl: + type: string + description: Link to internal company company profile. + websiteUrls: + type: array + description: Link to company's associated websites. + items: + type: string + logoUrl: + type: string + description: The URL of the company's logo. Public, Glean-authenticated and Base64 encoded data URLs are all valid (but not third-party-authenticated URLs). + location: + type: string + description: User facing string representing the company's location. + example: New York City + phone: + type: string + description: Phone number as a number string. + fax: + type: string + description: Fax number as a number string. + industry: + type: string + description: User facing string representing the company's industry. + example: Finances + annualRevenue: + type: number + format: double + description: Average company's annual revenue for reference. + numberOfEmployees: + type: integer + format: int64 + description: Average company's number of employees for reference. + stockSymbol: + type: string + description: Company's stock symbol if company is public. + foundedDate: + type: string + format: date + description: The date when the company was founded. + about: + type: string + description: User facing description of company. + example: Financial, software, data, and media company headquartered in Midtown Manhattan, New York City + DocumentCounts: + type: object + description: A map of {string, int} pairs representing counts of each document type associated with this customer. + additionalProperties: + type: integer + CustomDataValue: + properties: + displayLabel: + type: string + stringValue: + type: string + stringListValue: + type: array + description: list of strings for multi-value properties + items: + type: string + numberValue: + type: number + booleanValue: + type: boolean + CustomData: + type: object + description: Custom fields specific to individual datasources + additionalProperties: + $ref: "#/components/schemas/CustomDataValue" + CustomerMetadata: + properties: + datasourceId: + type: string + description: The user visible id of the salesforce customer account. + customData: + $ref: "#/components/schemas/CustomData" + Customer: + required: + - id + - company + properties: + id: + type: string + description: Unique identifier. + domains: + type: array + description: Link to company's associated website domains. + items: + type: string + company: + $ref: "#/components/schemas/Company" + documentCounts: + $ref: "#/components/schemas/DocumentCounts" + poc: + type: array + description: A list of POC for company. + items: + $ref: "#/components/schemas/Person" + metadata: + $ref: "#/components/schemas/CustomerMetadata" + mergedCustomers: + type: array + description: A list of Customers. + items: + $ref: "#/components/schemas/Customer" + startDate: + type: string + format: date + description: The date when the interaction with customer started. + contractAnnualRevenue: + type: number + format: double + description: Average contract annual revenue with that customer. + notes: + type: string + description: User facing (potentially generated) notes about company. + example: CIO is interested in trying out the product. + RelatedObject: + required: + - id + properties: + id: + type: string + description: The ID of the related object + metadata: + type: object + description: Some metadata of the object which can be displayed, while not having the actual object. + properties: + name: + type: string + description: Placeholder name of the object, not the relationship. + RelatedObjectEdge: + properties: + objects: + type: array + items: + $ref: "#/components/schemas/RelatedObject" + RelatedObjects: + properties: + relatedObjects: + type: object + description: A list of objects related to a source object. + additionalProperties: + $ref: "#/components/schemas/RelatedObjectEdge" + ScopeType: + type: string + description: Describes the scope for a ReadPermission, WritePermission, or GrantPermission object + enum: + - GLOBAL + - OWN + WritePermission: + description: Describes the write permissions levels that a user has for a specific feature + properties: + scopeType: + $ref: "#/components/schemas/ScopeType" + create: + type: boolean + description: True if user has create permission for this feature and scope + update: + type: boolean + description: True if user has update permission for this feature and scope + delete: + type: boolean + description: True if user has delete permission for this feature and scope + ObjectPermissions: + properties: + write: + $ref: "#/components/schemas/WritePermission" + PermissionedObject: + properties: + permissions: + $ref: "#/components/schemas/ObjectPermissions" + description: The permissions the current viewer has with respect to a particular object. + PersonToTeamRelationship: + required: + - person + type: object + description: Metadata about the relationship of a person to a team. + properties: + person: + $ref: "#/components/schemas/Person" + relationship: + type: string + description: The team member's relationship to the team. This defaults to MEMBER if not set. + default: MEMBER + enum: + - MEMBER + - MANAGER + - LEAD + - POINT_OF_CONTACT + - OTHER + customRelationshipStr: + type: string + description: Displayed name for the relationship if relationship is set to `OTHER`. + joinDate: + type: string + format: date-time + description: The team member's start date + TeamEmail: + properties: + email: + type: string + format: email + description: An email address + type: + type: string + enum: + - PRIMARY + - SECONDARY + - ONCALL + - OTHER + default: OTHER + isUserGenerated: + type: boolean + description: true iff the email was manually added by a user from within Glean (aka not from the original data source) + CustomFieldValueStr: + properties: + strText: + type: string + description: Text field for string value. + CustomFieldValueHyperlink: + properties: + urlAnchor: + type: string + description: Anchor text for hyperlink. + urlLink: + type: string + description: Link for this URL. + CustomFieldValuePerson: + properties: + person: + $ref: "#/components/schemas/Person" + CustomFieldValue: + oneOf: + - $ref: "#/components/schemas/CustomFieldValueStr" + - $ref: "#/components/schemas/CustomFieldValueHyperlink" + - $ref: "#/components/schemas/CustomFieldValuePerson" + CustomFieldData: + required: + - label + - values + - displayable + properties: + label: + type: string + description: A user-facing label for this field. + values: + type: array + items: + $ref: "#/components/schemas/CustomFieldValue" + displayable: + type: boolean + description: Determines whether the client should display this custom field + default: true + DatasourceProfile: + required: + - datasource + - handle + properties: + datasource: + type: string + example: github + description: The datasource the profile is of. + handle: + type: string + description: The display name of the entity in the given datasource. + url: + type: string + description: URL to view the entity's profile. + nativeAppUrl: + type: string + description: A deep link, if available, into the datasource's native application for the entity's platform (i.e. slack://...). + isUserGenerated: + type: boolean + description: For internal use only. True iff the data source profile was manually added by a user from within Glean (aka not from the original data source) + Team: + allOf: + - $ref: "#/components/schemas/RelatedObjects" + - $ref: "#/components/schemas/PermissionedObject" + - type: object + required: + - id + - name + properties: + id: + type: string + description: Unique identifier + name: + type: string + description: Team name + description: + type: string + description: A description of the team + businessUnit: + type: string + description: Typically the highest level organizational unit; generally applies to bigger companies with multiple distinct businesses. + department: + type: string + description: An organizational unit where everyone has a similar task, e.g. `Engineering`. + photoUrl: + type: string + format: url + description: A link to the team's photo. + bannerUrl: + type: string + format: url + description: A link to the team's banner photo. + externalLink: + type: string + format: uri + description: Link to a team page on the internet or your company's intranet + members: + type: array + description: The members on this team + items: + $ref: "#/components/schemas/PersonToTeamRelationship" + memberCount: + type: integer + description: Number of members on this team (recursive; includes all individuals that belong to this team, and all individuals that belong to a subteam within this team) + emails: + type: array + description: The emails for this team + items: + $ref: "#/components/schemas/TeamEmail" + customFields: + type: array + description: Customizable fields for additional team information. + items: + $ref: "#/components/schemas/CustomFieldData" + datasourceProfiles: + type: array + description: The datasource profiles of the team + items: + $ref: "#/components/schemas/DatasourceProfile" + datasource: + type: string + description: the data source of the team, e.g. GDRIVE + createdFrom: + type: string + description: For teams created from docs, the doc title. Otherwise empty. + lastUpdatedAt: + type: string + format: date-time + description: when this team was last updated. + status: + type: string + description: whether this team is fully processed or there are still unprocessed operations that'll affect it + default: PROCESSED + enum: + - PROCESSED + - QUEUED_FOR_CREATION + - QUEUED_FOR_DELETION + canBeDeleted: + type: boolean + description: can this team be deleted. Some manually ingested teams like GCS_CSV or PUSH_API cannot + default: true + loggingId: + type: string + description: The logging id of the team used in scrubbed logs, client analytics, and metrics. + CustomEntityMetadata: + properties: + customData: + $ref: "#/components/schemas/CustomData" + GroupType: + type: string + description: The type of user group + enum: + - DEPARTMENT + - ALL + - TEAM + - JOB_TITLE + - ROLE_TYPE + - LOCATION + - REGION + - EXTERNAL_GROUP + Group: + required: + - type + - id + properties: + type: + $ref: "#/components/schemas/GroupType" + id: + type: string + description: A unique identifier for the group. May be the same as name. + name: + type: string + description: Name of the group. + UserRole: + type: string + description: A user's role with respect to a specific document. + enum: + - OWNER + - VIEWER + - ANSWER_MODERATOR + - EDITOR + - VERIFIER + UserRoleSpecification: + required: + - role + properties: + sourceDocumentSpec: + $ref: "#/components/schemas/DocumentSpec" + description: The document spec of the object this role originates from. The object this role is included with will usually have the same information as this document spec, but if the role is inherited, then the document spec refers to the parent document that the role came from. + person: + $ref: "#/components/schemas/Person" + group: + $ref: "#/components/schemas/Group" + role: + $ref: "#/components/schemas/UserRole" + CustomEntity: + allOf: + - $ref: "#/components/schemas/PermissionedObject" + - type: object + properties: + id: + type: string + description: Unique identifier. + title: + type: string + description: Title or name of the custom entity. + datasource: + type: string + description: The datasource the custom entity is from. + objectType: + type: string + description: The type of the entity. Interpretation is specific to each datasource + metadata: + $ref: "#/components/schemas/CustomEntityMetadata" + roles: + type: array + description: A list of user roles for the custom entity explicitly granted by the owner. + items: + $ref: "#/components/schemas/UserRoleSpecification" + AnswerId: + properties: + id: + type: integer + description: The opaque ID of the Answer. + example: 3 + AnswerDocId: + properties: + docId: + type: string + description: Glean Document ID of the Answer. The Glean Document ID is supported for cases where the Answer ID isn't available. If both are available, using the Answer ID is preferred. + example: ANSWERS_answer_3 + AnswerMutableProperties: + properties: + question: + type: string + example: Why is the sky blue? + questionVariations: + type: array + description: Additional ways of phrasing this question. + items: + type: string + bodyText: + type: string + description: The plain text answer to the question. + example: From https://en.wikipedia.org/wiki/Diffuse_sky_radiation, the sky is blue because blue light is more strongly scattered than longer-wavelength light. + boardId: + type: integer + description: The parent board ID of this Answer, or 0 if it's a floating Answer. + audienceFilters: + type: array + description: Filters which restrict who should see the answer. Values are taken from the corresponding filters in people search. + items: + $ref: "#/components/schemas/FacetFilter" + addedRoles: + type: array + description: A list of user roles for the answer added by the owner. + items: + $ref: "#/components/schemas/UserRoleSpecification" + removedRoles: + type: array + description: A list of user roles for the answer removed by the owner. + items: + $ref: "#/components/schemas/UserRoleSpecification" + roles: + type: array + description: A list of roles for this answer explicitly granted by an owner, editor, or admin. + items: + $ref: "#/components/schemas/UserRoleSpecification" + sourceDocumentSpec: + $ref: "#/components/schemas/DocumentSpec" + sourceType: + type: string + enum: + - DOCUMENT + - ASSISTANT + StructuredText: + allOf: + - $ref: "#/components/schemas/StructuredTextMutableProperties" + - type: object + properties: + structuredList: + type: array + items: + $ref: "#/components/schemas/StructuredTextItem" + description: An array of objects each of which contains either a string or a link which optionally corresponds to a document. + AnswerLike: + properties: + user: + $ref: "#/components/schemas/Person" + createTime: + type: string + format: date-time + description: The time the user liked the answer in ISO format (ISO 8601). + AnswerLikes: + required: + - likedBy + - likedByUser + - numLikes + properties: + likedBy: + type: array + items: + $ref: "#/components/schemas/AnswerLike" + likedByUser: + type: boolean + description: Whether the user in context liked the answer. + numLikes: + type: integer + description: The total number of likes for the answer. + Reminder: + required: + - assignee + - remindAt + properties: + assignee: + $ref: "#/components/schemas/Person" + requestor: + $ref: "#/components/schemas/Person" + remindAt: + type: integer + description: Unix timestamp for when the reminder should trigger (in seconds since epoch UTC). + createdAt: + type: integer + description: Unix timestamp for when the reminder was first created (in seconds since epoch UTC). + reason: + type: string + description: An optional free-text reason for the reminder. This is particularly useful when a reminder is used to ask for verification from another user (for example, "Duplicate", "Incomplete", "Incorrect"). + TimePoint: + properties: + epochSeconds: + type: integer + description: Epoch seconds. Has precedence over daysFromNow. + daysFromNow: + type: integer + description: The number of days from now. Specification relative to current time. Can be negative. + Period: + properties: + minDaysFromNow: + type: integer + description: DEPRECATED - The number of days from now in the past to define upper boundary of time period. + deprecated: true + maxDaysFromNow: + type: integer + description: DEPRECATED - The number of days from now in the past to define lower boundary of time period. + deprecated: true + start: + $ref: "#/components/schemas/TimePoint" + end: + $ref: "#/components/schemas/TimePoint" + CountInfo: + required: + - count + properties: + count: + type: integer + description: The counter value + period: + $ref: "#/components/schemas/Period" + org: + type: string + description: The unit of organization over which we did the count aggregation, e.g. org (department) or company + VerificationMetadata: + required: + - documentId + properties: + lastVerifier: + $ref: "#/components/schemas/Person" + lastVerificationTs: + type: integer + description: The unix timestamp of the verification (in seconds since epoch UTC). + expirationTs: + type: integer + description: The unix timestamp of the verification expiration if applicable (in seconds since epoch UTC). + document: + $ref: "#/components/schemas/Document" + reminders: + type: array + items: + $ref: "#/components/schemas/Reminder" + description: Info about all outstanding verification reminders for the document if exists. + lastReminder: + $ref: "#/components/schemas/Reminder" + visitorCount: + type: array + items: + $ref: "#/components/schemas/CountInfo" + description: Number of visitors to the document during included time periods. + candidateVerifiers: + type: array + items: + $ref: "#/components/schemas/Person" + description: List of potential verifiers for the document e.g. old verifiers and/or users with view/edit permissions. + Verification: + required: + - state + properties: + state: + type: string + enum: + - UNVERIFIED + - VERIFIED + - DEPRECATED + description: The verification state for the document. + metadata: + $ref: "#/components/schemas/VerificationMetadata" + CollectionBaseMutableProperties: + required: + - name + properties: + name: + type: string + description: The unique name of the Collection. + description: + type: string + description: A brief summary of the Collection's contents. + addedRoles: + type: array + description: A list of added user roles for the Collection. + items: + $ref: "#/components/schemas/UserRoleSpecification" + removedRoles: + type: array + description: A list of removed user roles for the Collection. + items: + $ref: "#/components/schemas/UserRoleSpecification" + audienceFilters: + type: array + items: + $ref: "#/components/schemas/FacetFilter" + description: Filters which restrict who should see this Collection. Values are taken from the corresponding filters in people search. + AnswerBoardMutableProperties: + allOf: + - $ref: "#/components/schemas/CollectionBaseMutableProperties" + AnswerBoard: + allOf: + - $ref: "#/components/schemas/AnswerBoardMutableProperties" + - $ref: "#/components/schemas/PermissionedObject" + - type: object + required: + - id + - description + properties: + id: + type: integer + description: The unique ID of the Answer Board. + createTime: + type: string + format: date-time + updateTime: + type: string + format: date-time + creator: + $ref: "#/components/schemas/Person" + updatedBy: + $ref: "#/components/schemas/Person" + itemCount: + type: integer + description: The number of items currently in the Answer Board. Separated from the actual items so we can grab the count without items. + roles: + type: array + description: A list of user roles for the Answer Board. + items: + $ref: "#/components/schemas/UserRoleSpecification" + Thumbnail: + properties: + photoId: + type: string + description: Photo id if the thumbnail is from splash. + url: + type: string + description: Thumbnail URL. This can be user provided image and/or from downloaded images hosted by Glean. + CollectionMutableProperties: + allOf: + - $ref: "#/components/schemas/CollectionBaseMutableProperties" + - type: object + required: + - name + properties: + icon: + type: string + description: The emoji icon of this Collection. + adminLocked: + type: boolean + description: Indicates whether edits are allowed for everyone or only admins. + parentId: + type: integer + description: The parent of this Collection, or 0 if it's a top-level Collection. + thumbnail: + $ref: "#/components/schemas/Thumbnail" + allowedDatasource: + type: string + description: The datasource type this Collection can hold. + CollectionItemMutableProperties: + properties: + name: + type: string + description: The optional name of the Collection item. + description: + type: string + description: A helpful description of why this CollectionItem is in the Collection that it's in. + icon: + type: string + description: The emoji icon for this CollectionItem. Only used for Text type items. + UserGeneratedContentId: + properties: + id: + type: integer + description: The opaque id of the user generated content. + ShortcutMutableProperties: + properties: + inputAlias: + type: string + description: Link text following go/ prefix as entered by the user. + destinationUrl: + type: string + description: Destination URL for the shortcut. + destinationDocumentId: + type: string + description: Glean Document ID for the URL, if known. + description: + type: string + description: A short, plain text blurb to help people understand the intent of the shortcut. + unlisted: + type: boolean + description: Whether this shortcut is unlisted or not. Unlisted shortcuts are visible to author + admins only. + urlTemplate: + type: string + description: For variable shortcuts, contains the URL template; note, `destinationUrl` contains default URL. + addedRoles: + type: array + description: A list of user roles added for the Shortcut. + items: + $ref: "#/components/schemas/UserRoleSpecification" + removedRoles: + type: array + description: A list of user roles removed for the Shortcut. + items: + $ref: "#/components/schemas/UserRoleSpecification" + ShortcutMetadata: + properties: + createdBy: + $ref: "#/components/schemas/Person" + createTime: + type: string + format: date-time + description: The time the shortcut was created in ISO format (ISO 8601). + updatedBy: + $ref: "#/components/schemas/Person" + updateTime: + type: string + format: date-time + description: The time the shortcut was updated in ISO format (ISO 8601). + destinationDocument: + $ref: "#/components/schemas/Document" + description: Document that corresponds to the destination URL, if applicable. + intermediateUrl: + type: string + description: The URL from which the user is then redirected to the destination URL. Full replacement for https://go/. + viewPrefix: + type: string + description: The part of the shortcut preceding the input alias when used for showing shortcuts to users. Should end with "/". e.g. "go/" for native shortcuts. + isExternal: + type: boolean + description: Indicates whether a shortcut is native or external. + editUrl: + type: string + description: The URL using which the user can access the edit page of the shortcut. + Shortcut: + allOf: + - $ref: "#/components/schemas/UserGeneratedContentId" + - $ref: "#/components/schemas/ShortcutMutableProperties" + - $ref: "#/components/schemas/PermissionedObject" + - $ref: "#/components/schemas/ShortcutMetadata" + - type: object + required: + - inputAlias + properties: + alias: + type: string + description: canonical link text following go/ prefix where hyphen/underscore is removed. + title: + type: string + description: Title for the Go Link + roles: + type: array + description: A list of user roles for the Go Link. + items: + $ref: "#/components/schemas/UserRoleSpecification" + Collection: + allOf: + - $ref: "#/components/schemas/CollectionMutableProperties" + - $ref: "#/components/schemas/PermissionedObject" + - type: object + required: + - id + - description + properties: + id: + type: integer + description: The unique ID of the Collection. + createTime: + type: string + format: date-time + updateTime: + type: string + format: date-time + creator: + $ref: "#/components/schemas/Person" + updatedBy: + $ref: "#/components/schemas/Person" + itemCount: + type: integer + description: The number of items currently in the Collection. Separated from the actual items so we can grab the count without items. + childCount: + type: integer + description: The number of children Collections. Separated from the actual children so we can grab the count without children. + items: + type: array + items: + $ref: "#/components/schemas/CollectionItem" + description: The items in this Collection. + pinMetadata: + $ref: "#/components/schemas/CollectionPinnedMetadata" + description: Metadata having what categories this Collection is pinned to and the eligible categories to pin to + shortcuts: + type: array + items: + type: string + description: The names of the shortcuts (Go Links) that point to this Collection. + children: + type: array + items: + $ref: "#/components/schemas/Collection" + description: The children Collections of this Collection. + roles: + type: array + description: A list of user roles for the Collection. + items: + $ref: "#/components/schemas/UserRoleSpecification" + CollectionItem: + allOf: + - $ref: "#/components/schemas/CollectionItemMutableProperties" + - type: object + required: + - collectionId + - itemType + properties: + collectionId: + type: integer + description: The Collection ID of the Collection that this CollectionItem belongs in. + documentId: + type: string + description: If this CollectionItem is indexed, the Glean Document ID of that document. + url: + type: string + description: The URL of this CollectionItem. + itemId: + type: string + description: Unique identifier for the item within the Collection it belongs to. + createdBy: + $ref: "#/components/schemas/Person" + description: The person who added this Collection item. + createdAt: + type: string + format: date-time + description: Unix timestamp for when the item was first added (in seconds since epoch UTC). + document: + $ref: "#/components/schemas/Document" + description: The Document this CollectionItem corresponds to (omitted if item is a non-indexed URL). + shortcut: + $ref: "#/components/schemas/Shortcut" + description: The Shortcut this CollectionItem corresponds to (only included if item URL is for a Go Link). + collection: + $ref: "#/components/schemas/Collection" + description: The Collection this CollectionItem corresponds to (only included if item type is COLLECTION). + itemType: + type: string + enum: + - DOCUMENT + - TEXT + - URL + - COLLECTION + CollectionPinnableCategories: + type: string + description: Categories a Collection can be pinned to. + enum: + - COMPANY_RESOURCE + - DEPARTMENT_RESOURCE + - TEAM_RESOURCE + CollectionPinnableTargets: + type: string + description: What targets can a Collection be pinned to. + enum: + - RESOURCE_CARD + - TEAM_PROFILE_PAGE + CollectionPinTarget: + required: + - category + properties: + category: + $ref: "#/components/schemas/CollectionPinnableCategories" + value: + type: string + description: Optional. If category supports values, then the additional value for the category e.g. department name for DEPARTMENT_RESOURCE, team name/id for TEAM_RESOURCE and so on. + target: + $ref: "#/components/schemas/CollectionPinnableTargets" + CollectionPinMetadata: + required: + - id + - target + properties: + id: + type: integer + description: The ID of the Collection. + target: + $ref: "#/components/schemas/CollectionPinTarget" + CollectionPinnedMetadata: + required: + - pinnedCategories + - eligibleCategoriesForPinning + properties: + existingPins: + type: array + items: + $ref: "#/components/schemas/CollectionPinTarget" + description: List of targets this Collection is pinned to. + eligiblePins: + type: array + items: + $ref: "#/components/schemas/CollectionPinMetadata" + description: List of targets this Collection can be pinned to, excluding the targets this Collection is already pinned to. We also include Collection ID already is pinned to each eligible target, which will be 0 if the target has no pinned Collection. + Answer: + allOf: + - $ref: "#/components/schemas/AnswerId" + - $ref: "#/components/schemas/AnswerDocId" + - $ref: "#/components/schemas/AnswerMutableProperties" + - $ref: "#/components/schemas/PermissionedObject" + - type: object + required: + - id + properties: + combinedAnswerText: + $ref: "#/components/schemas/StructuredText" + likes: + $ref: "#/components/schemas/AnswerLikes" + author: + $ref: "#/components/schemas/Person" + createTime: + type: string + format: date-time + description: The time the answer was created in ISO format (ISO 8601). + updateTime: + type: string + format: date-time + description: The time the answer was last updated in ISO format (ISO 8601). + updatedBy: + $ref: "#/components/schemas/Person" + verification: + $ref: "#/components/schemas/Verification" + board: + $ref: "#/components/schemas/AnswerBoard" + description: The parent board this answer is in. + collections: + type: array + description: The collections to which the answer belongs. + items: + $ref: "#/components/schemas/Collection" + documentCategory: + type: string + description: The document's document_category(.proto). + sourceDocument: + $ref: "#/components/schemas/Document" + SearchResult: + required: + - url + allOf: + - $ref: "#/components/schemas/Result" + - type: object + properties: + document: + $ref: "#/components/schemas/Document" + title: + type: string + url: + type: string + nativeAppUrl: + type: string + description: A deep link, if available, into the datasource's native application for the user's platform (e.g. slack://...). + snippets: + type: array + items: + $ref: "#/components/schemas/SearchResultSnippet" + description: Text content from the result document which contains search query terms, if available. + fullText: + type: string + description: The full body text of the result if not already contained in the snippets. Only populated for conversation results (e.g. results from a messaging app such as Slack). + fullTextList: + type: array + description: The full body text of the result if not already contained in the snippets; each item in the array represents a separate line in the original text. Only populated for conversation results (e.g. results from a messaging app such as Slack). + items: + type: string + relatedResults: + type: array + items: + $ref: "#/components/schemas/RelatedDocuments" + description: A list of results related to this search result. Eg. for conversation results it contains individual messages from the conversation document which will be shown on SERP. + clusteredResults: + type: array + description: A list of results that should be displayed as associated with this result. + items: + $ref: "#/components/schemas/SearchResult" + allClusteredResults: + type: array + description: A list of results that should be displayed as associated with this result. + items: + $ref: "#/components/schemas/ClusterGroup" + attachmentCount: + type: integer + description: The total number of attachments. + attachments: + type: array + description: A (potentially partial) list of results representing documents attached to the main result document. + items: + $ref: "#/components/schemas/SearchResult" + backlinkResults: + type: array + description: A list of results that should be displayed as backlinks of this result in reverse chronological order. + items: + $ref: "#/components/schemas/SearchResult" + clusterType: + $ref: "#/components/schemas/ClusterTypeEnum" + mustIncludeSuggestions: + $ref: "#/components/schemas/QuerySuggestionList" + querySuggestion: + $ref: "#/components/schemas/QuerySuggestion" + prominence: + $ref: "#/components/schemas/SearchResultProminenceEnum" + attachmentContext: + type: string + description: Additional context for the relationship between the result and the document it's attached to. + pins: + type: array + description: A list of pins associated with this search result. + items: + $ref: "#/components/schemas/PinDocument" + example: + snippets: + - snippet: snippet + mimeType: mimeType + metadata: + container: container + createTime: "2000-01-23T04:56:07.000Z" + datasource: datasource + author: + name: name + documentId: documentId + updateTime: "2000-01-23T04:56:07.000Z" + mimeType: mimeType + objectType: objectType + title: title + url: https://example.com/foo/bar + nativeAppUrl: slack://foo/bar + mustIncludeSuggestions: + - missingTerm: container + query: container + ExtractedQnA: + properties: + heading: + type: string + description: Heading text that was matched to produce this result. + question: + type: string + description: Question text that was matched to produce this result. + questionResult: + $ref: "#/components/schemas/SearchResult" + CalendarAttendee: + required: + - person + properties: + isOrganizer: + type: boolean + description: Whether or not this attendee is an organizer. + isInGroup: + type: boolean + description: Whether or not this attendee is in a group. Needed temporarily at least to support both flat attendees and tree for compatibility. + person: + $ref: "#/components/schemas/Person" + groupAttendees: + type: array + description: If this attendee is a group, represents the list of individual attendees in the group. + items: + $ref: "#/components/schemas/CalendarAttendee" + responseStatus: + type: string + enum: + - ACCEPTED + - DECLINED + - NO_RESPONSE + - TENTATIVE + CalendarAttendees: + properties: + people: + type: array + items: + $ref: "#/components/schemas/CalendarAttendee" + description: Full details of some of the attendees of this event + isLimit: + type: boolean + description: Whether the total count of the people returned is at the retrieval limit. + total: + type: integer + description: Total number of attendees in this event. + numAccepted: + type: integer + description: Total number of attendees who have accepted this event. + numDeclined: + type: integer + description: Total number of attendees who have declined this event. + numNoResponse: + type: integer + description: Total number of attendees who have not responded to this event. + numTentative: + type: integer + description: Total number of attendees who have responded tentatively (i.e. responded maybe) to this event. + Meeting: + properties: + id: + type: string + title: + type: string + description: + type: string + url: + type: string + startTime: + type: string + format: date-time + endTime: + type: string + format: date-time + attendees: + $ref: "#/components/schemas/CalendarAttendees" + description: The attendee list, including their response status + AppResult: + required: + - datasource + properties: + datasource: + type: string + description: The app or other repository type this represents + docType: + type: string + description: The datasource-specific type of the document (e.g. for Jira issues, this is the issue type such as Bug or Feature Request). + mimeType: + type: string + description: Mimetype is used to differentiate between sub applications from a datasource (e.g. Sheets, Docs from Gdrive) + iconUrl: + type: string + description: If there is available icon URL. + CodeLine: + properties: + lineNumber: + type: integer + content: + type: string + ranges: + type: array + items: + $ref: "#/components/schemas/TextRange" + description: Index ranges depicting matched sections of the line + Code: + properties: + repoName: + type: string + fileName: + type: string + fileUrl: + type: string + lines: + type: array + items: + $ref: "#/components/schemas/CodeLine" + isLastMatch: + type: boolean + description: Last file match for a repo + example: + repoName: scio + fileName: README.md + matches: + - lineNumber: 1 + content: Welcome to the beginning + ranges: [] + - lineNumber: 2 + content: Second line of the file + ranges: [] + - lineNumber: 3 + content: hello world hello world + ranges: + - startindex: 0 + endIndex: 5 + - startIndex: 12 + endIndex: 17 + QuerySuggestionList: + properties: + suggestions: + type: array + items: + $ref: "#/components/schemas/QuerySuggestion" + person: + $ref: "#/components/schemas/Person" + RelatedDocuments: + properties: + relation: + type: string + description: How this document relates to the including entity. + enum: + - ATTACHMENT + - CANONICAL + - CASE + - CONTACT + - CONVERSATION_MESSAGES + - EXPERT + - FROM + - HIGHLIGHT + - OPPORTUNITY + - RECENT + - SOURCE + - TICKET + - TRANSCRIPT + - WITH + x-enumDescriptions: + CANONICAL: Canonical documents for the entity, such as overview docs, architecture docs elastic. + associatedEntityId: + type: string + description: Which entity in the response that this entity relates to. Relevant when there are multiple entities associated with the response (such as merged customers) + querySuggestion: + $ref: "#/components/schemas/QuerySuggestion" + documents: + type: array + items: + $ref: "#/components/schemas/Document" + description: A truncated list of documents with this relation. TO BE DEPRECATED. + deprecated: true + results: + type: array + items: + $ref: "#/components/schemas/SearchResult" + description: A truncated list of documents associated with this relation. To be used in favor of `documents` because it contains a trackingToken. + RelatedQuestion: + properties: + question: + type: string + description: The text of the related question + answer: + type: string + description: The answer for the related question + ranges: + type: array + items: + $ref: "#/components/schemas/TextRange" + description: Subsections of the answer string to which some special formatting should be applied (eg. bold) + EntityType: + type: string + description: The type of entity. + x-include-enum-class-prefix: true + enum: + - PERSON + - PROJECT + - CUSTOMER + Disambiguation: + type: object + description: A disambiguation between multiple entities with the same name + properties: + name: + type: string + description: Name of the ambiguous entity + id: + type: string + description: The unique id of the entity in the knowledge graph + type: + $ref: "#/components/schemas/EntityType" + SearchResultSnippet: + required: + - snippet + properties: + snippet: + type: string + description: A matching snippet from the document. Query term matches are marked by the unicode characters uE006 and uE007. + mimeType: + type: string + description: The mime type of the snippets, currently either text/plain or text/html. + text: + type: string + description: A matching snippet from the document with no highlights. + snippetTextOrdering: + type: integer + description: Used for sorting based off the snippet's location within all_snippetable_text + ranges: + type: array + items: + $ref: "#/components/schemas/TextRange" + description: The bolded ranges within text. + url: + type: string + description: A URL, generated based on availability, that links to the position of the snippet text or to the nearest header above the snippet text. + example: + snippet: snippet + mimeType: mimeType + StructuredResult: + description: A single object that can support any object in the work graph. Only a single object will be populated. + properties: + document: + $ref: "#/components/schemas/Document" + person: + $ref: "#/components/schemas/Person" + customer: + $ref: "#/components/schemas/Customer" + team: + $ref: "#/components/schemas/Team" + customEntity: + $ref: "#/components/schemas/CustomEntity" + answer: + $ref: "#/components/schemas/Answer" + extractedQnA: + $ref: "#/components/schemas/ExtractedQnA" + meeting: + $ref: "#/components/schemas/Meeting" + app: + $ref: "#/components/schemas/AppResult" + collection: + $ref: "#/components/schemas/Collection" + answerBoard: + $ref: "#/components/schemas/AnswerBoard" + code: + $ref: "#/components/schemas/Code" + shortcut: + $ref: "#/components/schemas/Shortcut" + querySuggestions: + $ref: "#/components/schemas/QuerySuggestionList" + relatedDocuments: + type: array + items: + $ref: "#/components/schemas/RelatedDocuments" + description: A list of documents related to this structured result. + relatedQuestion: + $ref: "#/components/schemas/RelatedQuestion" + disambiguation: + $ref: "#/components/schemas/Disambiguation" + snippets: + description: Any snippets associated to the populated object. + type: array + items: + $ref: "#/components/schemas/SearchResultSnippet" + trackingToken: + type: string + description: An opaque token that represents this particular result in this particular query. To be used for /feedback reporting. + prominence: + type: string + description: The level of visual distinction that should be given to a result. + x-enumDescriptions: + HERO: A high-confidence result that should feature prominently on the page. + PROMOTED: May not be the best result but should be given additional visual distinction. + STANDARD: Should not be distinct from any other results. + enum: + - HERO + - PROMOTED + - STANDARD + source: + type: string + description: Source context for this result. Possible values depend on the result type. + enum: + - EXPERT_DETECTION + - ENTITY_NLQ + Result: + properties: + structuredResults: + type: array + description: An array of entities in the work graph retrieved via a data request. + items: + $ref: "#/components/schemas/StructuredResult" + trackingToken: + type: string + description: An opaque token that represents this particular result in this particular query. To be used for /feedback reporting. + ClusterTypeEnum: + type: string + description: The reason for inclusion of clusteredResults. + enum: + - SIMILAR + - FRESHNESS + - TITLE + - CONTENT + - NONE + - THREAD_REPLY + - THREAD_ROOT + - PREFIX + - SUFFIX + ClusterGroup: + required: + - visibleCountHint + properties: + clusteredResults: + type: array + description: A list of results that should be displayed as associated with this result. + items: + $ref: "#/components/schemas/SearchResult" + clusterType: + $ref: "#/components/schemas/ClusterTypeEnum" + visibleCountHint: + type: integer + description: The default number of results to display before truncating and showing a "see more" link + SearchResultProminenceEnum: + type: string + description: | + The level of visual distinction that should be given to a result. + x-enumDescriptions: + HERO: A high-confidence result that should feature prominently on the page. + PROMOTED: May not be the best result but should be given additional visual distinction. + STANDARD: Should not be distinct from any other results. + enum: + - HERO + - PROMOTED + - STANDARD + PinDocumentMutableProperties: + properties: + queries: + type: array + description: The query strings for which the pinned result will show. + items: + type: string + audienceFilters: + type: array + description: Filters which restrict who should see the pinned document. Values are taken from the corresponding filters in people search. + items: + $ref: "#/components/schemas/FacetFilter" + PinDocument: + allOf: + - $ref: "#/components/schemas/PinDocumentMutableProperties" + - type: object + required: + - documentId + properties: + id: + type: string + description: The opaque id of the pin. + documentId: + type: string + description: The document which should be a pinned result. + audienceFilters: + type: array + description: Filters which restrict who should see the pinned document. Values are taken from the corresponding filters in people search. + items: + $ref: "#/components/schemas/FacetFilter" + attribution: + $ref: "#/components/schemas/Person" + updatedBy: + $ref: "#/components/schemas/Person" + createTime: + type: string + format: date-time + updateTime: + type: string + format: date-time + PersonTeam: + description: Use `id` if you index teams via Glean, and use `name` and `externalLink` if you want to use your own team pages + properties: + id: + type: string + description: Unique identifier + name: + type: string + description: Team name + externalLink: + type: string + format: uri + description: Link to a team page on the internet or your company's intranet + relationship: + type: string + description: The team member's relationship to the team. This defaults to MEMBER if not set. + default: MEMBER + enum: + - MEMBER + - MANAGER + - LEAD + - POINT_OF_CONTACT + - OTHER + joinDate: + type: string + format: date-time + description: The team member's start date + StructuredLocation: + type: object + description: Detailed location with information about country, state, city etc. + properties: + deskLocation: + type: string + description: Desk number. + timezone: + type: string + description: Location's timezone, e.g. UTC, PST. + address: + type: string + description: Office address or name. + city: + type: string + description: Name of the city. + state: + type: string + description: State code. + region: + type: string + description: Region information, e.g. NORAM, APAC. + zipCode: + type: string + description: ZIP Code for the address. + country: + type: string + description: Country name. + countryCode: + type: string + description: Alpha-2 or Alpha-3 ISO 3166 country code, e.g. US or USA. + SocialNetwork: + required: + - name + - profileUrl + properties: + name: + type: string + description: Possible values are "twitter", "linkedin". + profileName: + type: string + description: Human-readable profile name. + profileUrl: + type: string + format: url + description: Link to profile. + PersonDistance: + required: + - name + - obfuscatedId + - distance + properties: + name: + type: string + description: The display name. + obfuscatedId: + type: string + description: An opaque identifier that can be used to request metadata for a Person. + distance: + type: number + format: float + description: Distance to person, refer to PeopleDistance pipeline on interpretation of the value. + CommunicationChannel: + type: string + enum: + - COMMUNICATION_CHANNEL_EMAIL + - COMMUNICATION_CHANNEL_SLACK + ChannelInviteInfo: + description: Information regarding the invite status of a person for a particular channel. + properties: + channel: + description: Channel through which the invite was sent + $ref: "#/components/schemas/CommunicationChannel" + isAutoInvite: + description: Bit that tracks if this invite was automatically sent or user-sent + type: boolean + inviter: + description: The person that invited this person. + $ref: "#/components/schemas/Person" + inviteTime: + type: string + format: date-time + description: The time this person was invited in ISO format (ISO 8601). + reminderTime: + type: string + format: date-time + description: The time this person was reminded in ISO format (ISO 8601) if a reminder was sent. + InviteInfo: + description: Information regarding the invite status of a person. + properties: + signUpTime: + type: string + format: date-time + description: The time this person signed up in ISO format (ISO 8601). + invites: + type: array + items: + $ref: "#/components/schemas/ChannelInviteInfo" + description: Latest invites received by the user for each channel + inviter: + deprecated: true + description: The person that invited this person. + $ref: "#/components/schemas/Person" + inviteTime: + deprecated: true + type: string + format: date-time + description: The time this person was invited in ISO format (ISO 8601). + reminderTime: + deprecated: true + type: string + format: date-time + description: The time this person was reminded in ISO format (ISO 8601) if a reminder was sent. + ReadPermission: + description: Describes the read permission level that a user has for a specific feature + properties: + scopeType: + $ref: "#/components/schemas/ScopeType" + ReadPermissions: + description: Describes the read permission levels that a user has for permissioned features. Key must be PermissionedFeatureOrObject + additionalProperties: + type: array + description: List of read permissions (for different scopes but same feature) + items: + $ref: "#/components/schemas/ReadPermission" + WritePermissions: + description: Describes the write permissions levels that a user has for permissioned features. Key must be PermissionedFeatureOrObject + additionalProperties: + type: array + description: List of write permissions (for different scopes but same feature) + items: + $ref: "#/components/schemas/WritePermission" + GrantPermission: + description: Describes the grant permission level that a user has for a specific feature + properties: + scopeType: + $ref: "#/components/schemas/ScopeType" + GrantPermissions: + description: Describes the grant permission levels that a user has for permissioned features. Key must be PermissionedFeatureOrObject + additionalProperties: + type: array + description: List of grant permissions (for different scopes but same feature) + items: + $ref: "#/components/schemas/GrantPermission" + Permissions: + description: |- + Describes the permissions levels that a user has for permissioned features. When the client sends this, Permissions.read and Permissions.write are the additional permissions granted to a user on top of what they have via their roles. + When the server sends this, Permissions.read and Permissions.write are the complete (merged) set of permissions the user has, and Permissions.roles is just for display purposes. + properties: + canAdminSearch: + type: boolean + description: TODO--deprecate in favor of the read and write properties. True if the user has access to /adminsearch + canAdminClientApiGlobalTokens: + type: boolean + description: TODO--deprecate in favor of the read and write properties. True if the user can administrate client API tokens with global scope + canDlp: + type: boolean + description: TODO--deprecate in favor of the read and write properties. True if the user has access to data loss prevention (DLP) features + read: + $ref: "#/components/schemas/ReadPermissions" + write: + $ref: "#/components/schemas/WritePermissions" + grant: + $ref: "#/components/schemas/GrantPermissions" + role: + type: string + description: The roleId of the canonical role a user has. The displayName is equal to the roleId. + roles: + type: array + description: The roleIds of the roles a user has. + items: + type: string + TimeInterval: + required: + - start + - end + properties: + start: + type: string + description: The RFC3339 timestamp formatted start time of this event. + end: + type: string + description: The RFC3339 timestamp formatted end time of this event. + AnonymousEvent: + description: A generic, light-weight calendar event. + type: object + properties: + time: + $ref: "#/components/schemas/TimeInterval" + eventType: + description: The nature of the event, for example "out of office". + type: string + enum: + - DEFAULT + - OUT_OF_OFFICE + IconConfig: + description: Defines how to render an icon + properties: + generatedBackgroundColorKey: + type: string + backgroundColor: + type: string + color: + type: string + key: + type: string + iconType: + enum: + - COLLECTION + - CUSTOM + - DATASOURCE + - DATASOURCE_INSTANCE + - FAVICON + - FILE_TYPE + - GENERATED_BACKGROUND + - GLYPH + - MIME_TYPE + - NO_ICON + - PERSON + - REACTIONS + - URL + masked: + type: boolean + description: Whether the icon should be masked based on current theme. + name: + type: string + description: The name of the icon if applicable, e.g. the glyph name for `IconType.GLYPH` icons. + url: + type: string + description: The URL to an image to be displayed if applicable, e.g. the URL for `iconType.URL` icons. + example: + color: "#343CED" + key: person_icon + iconType: GLYPH + name: user + Badge: + type: object + description: Displays a user's accomplishment or milestone + properties: + key: + type: string + description: An auto generated unique identifier. + displayName: + type: string + description: The badge name displayed to users + iconConfig: + $ref: "#/components/schemas/IconConfig" + pinned: + type: boolean + description: The badge should be shown on the PersonAttribution + example: + key: deployment_name_new_hire + displayName: New hire + iconConfig: + color: "#343CED" + key: person_icon + iconType: GLYPH + name: user + PersonMetadata: + properties: + type: + type: string + x-enumDescriptions: + FULL_TIME: The person is a current full-time employee of the company. + CONTRACTOR: The person is a current contractor of the company. + NON_EMPLOYEE: The person object represents a non-human actor such as a service or admin account. + FORMER_EMPLOYEE: The person is a previous employee of the company. + enum: + - FULL_TIME + - CONTRACTOR + - NON_EMPLOYEE + - FORMER_EMPLOYEE + example: FULL_TIME + firstName: + type: string + description: The first name of the person + lastName: + type: string + description: The last name of the person + title: + type: string + description: Job title. + businessUnit: + type: string + description: Typically the highest level organizational unit; generally applies to bigger companies with multiple distinct businesses. + department: + type: string + description: An organizational unit where everyone has a similar task, e.g. `Engineering`. + teams: + description: Info about the employee's team(s). + type: array + items: + $ref: "#/components/schemas/PersonTeam" + departmentCount: + type: integer + description: The number of people in this person's department. + email: + type: string + description: The user's primary email address + aliasEmails: + type: array + description: Additional email addresses of this user beyond the primary, if any. + items: + type: string + location: + type: string + description: User facing string representing the person's location. + structuredLocation: + $ref: "#/components/schemas/StructuredLocation" + externalProfileLink: + type: string + description: Link to a customer's internal profile page. This is set to '#' when no link is desired. + manager: + $ref: "#/components/schemas/Person" + managementChain: + description: The chain of reporting in the company as far up as it goes. The last entry is this person's direct manager. + type: array + items: + $ref: "#/components/schemas/Person" + phone: + type: string + description: Phone number as a number string. + timezone: + type: string + description: The timezone of the person. E.g. "Pacific Daylight Time". + timezoneOffset: + type: integer + format: int64 + description: The offset of the person's timezone in seconds from UTC. + photoUrl: + type: string + format: url + description: The URL of the person's avatar. Public, glean-authenticated and Base64 encoded data URLs are all valid (but not third-party-authenticated URLs). + uneditedPhotoUrl: + type: string + format: url + description: The original photo URL of the person's avatar before any edits they made are applied + bannerUrl: + type: string + format: url + description: The URL of the person's banner photo. + reports: + type: array + items: + $ref: "#/components/schemas/Person" + startDate: + type: string + description: The date when the employee started. + format: date + endDate: + type: string + format: date + description: If a former employee, the last date of employment. + bio: + type: string + description: Short biography or mission statement of the employee. + pronoun: + type: string + description: She/her, He/his or other pronoun. + orgSizeCount: + type: integer + description: The total recursive size of the people reporting to this person, or 1 + directReportsCount: + type: integer + description: The total number of people who directly report to this person, or 0 + preferredName: + type: string + description: The preferred name of the person, or a nickname. + socialNetwork: + description: List of social network profiles. + type: array + items: + $ref: "#/components/schemas/SocialNetwork" + datasourceProfile: + type: array + description: List of profiles this user has in different datasources / tools that they use. + items: + $ref: "#/components/schemas/DatasourceProfile" + querySuggestions: + $ref: "#/components/schemas/QuerySuggestionList" + peopleDistance: + type: array + items: + $ref: "#/components/schemas/PersonDistance" + description: List of people and distances to those people from this person. Optionally with metadata. + inviteInfo: + $ref: "#/components/schemas/InviteInfo" + isSignedUp: + type: boolean + description: Whether the user has signed into Glean at least once. + lastExtensionUse: + type: string + format: date-time + description: The last time the user has used the Glean extension in ISO 8601 format. + permissions: + $ref: "#/components/schemas/Permissions" + customFields: + type: array + description: User customizable fields for additional people information. + items: + $ref: "#/components/schemas/CustomFieldData" + loggingId: + type: string + description: The logging id of the person used in scrubbed logs, tracking GA metrics. + startDatePercentile: + type: number + format: float + description: Percentage of the company that started strictly after this person. Between [0,100). + busyEvents: + type: array + items: + $ref: "#/components/schemas/AnonymousEvent" + description: Intervals of busy time for this person, along with the type of event they're busy with. + profileBoolSettings: + type: object + additionalProperties: + type: boolean + description: flag settings to indicate user profile settings for certain items + badges: + type: array + items: + $ref: "#/components/schemas/Badge" + description: The badges that a user has earned over their lifetime. + isOrgRoot: + type: boolean + description: Whether this person is a "root" node in their organization's hierarchy. + example: + department: Movies + email: george@example.com + location: Hollywood, CA + phone: 6505551234 + photoUrl: https://example.com/george.jpg + startDate: "2000-01-23" + title: Actor + DocumentVisibility: + type: string + description: The level of visibility of the document as understood by our system. + x-enumDescriptions: + PRIVATE: Only one person is able to see the document. + SPECIFIC_PEOPLE_AND_GROUPS: Only specific people and/or groups can see the document. + DOMAIN_LINK: Anyone in the domain with the link can see the document. + DOMAIN_VISIBLE: Anyone in the domain can search for the document. + PUBLIC_LINK: Anyone with the link can see the document. + PUBLIC_VISIBLE: Anyone on the internet can search for the document. + enum: + - PRIVATE + - SPECIFIC_PEOPLE_AND_GROUPS + - DOMAIN_LINK + - DOMAIN_VISIBLE + - PUBLIC_LINK + - PUBLIC_VISIBLE + Reaction: + properties: + type: + type: string + count: + type: integer + description: The count of the reaction type on the document. + reactors: + type: array + items: + $ref: "#/components/schemas/Person" + reactedByViewer: + type: boolean + description: Whether the user in context reacted with this type to the document. + Share: + description: Search endpoint will only fill out numDays ago since that's all we need to display shared badge; docmetadata endpoint will fill out all the fields so that we can display shared badge tooltip + required: + - numDaysAgo + properties: + numDaysAgo: + type: integer + description: The number of days that has passed since the share happened + sharer: + $ref: "#/components/schemas/Person" + sharingDocument: + $ref: "#/components/schemas/Document" + DocumentInteractions: + properties: + numComments: + type: integer + description: The count of comments (thread replies in the case of slack). + numReactions: + type: integer + description: The count of reactions on the document. + reactions: + type: array + description: To be deprecated in favor of reacts. A (potentially non-exhaustive) list of reactions for the document. + deprecated: true + items: + type: string + reacts: + type: array + items: + $ref: "#/components/schemas/Reaction" + shares: + type: array + items: + $ref: "#/components/schemas/Share" + description: Describes instances of someone posting a link to this document in one of our indexed datasources. + visitorCount: + $ref: "#/components/schemas/CountInfo" + ViewerInfo: + properties: + role: + type: string + enum: + - ANSWER_MODERATOR + - OWNER + - VIEWER + description: DEPRECATED - use permissions instead. Viewer's role on the specific document. + deprecated: true + lastViewedTime: + type: string + format: date-time + IndexStatus: + properties: + lastCrawledTime: + description: When the document was last crawled + type: string + format: date-time + lastIndexedTime: + description: When the document was last indexed + type: string + format: date-time + DocumentMetadata: + properties: + datasource: + type: string + datasourceInstance: + type: string + description: The datasource instance from which the document was extracted. + objectType: + type: string + description: The type of the result. Interpretation is specific to each datasource. (e.g. for Jira issues, this is the issue type such as Bug or Feature Request). + container: + type: string + description: The name of the container (higher level parent, not direct parent) of the result. Interpretation is specific to each datasource (e.g. Channels for Slack, Project for Jira). cf. parentId + containerId: + type: string + description: The Glean Document ID of the container. Uniquely identifies the container. + superContainerId: + type: string + description: The Glean Document ID of the super container. Super container represents a broader abstraction that contains many containers. For example, whereas container might refer to a folder, super container would refer to a drive. + parentId: + type: string + description: The id of the direct parent of the result. Interpretation is specific to each datasource (e.g. parent issue for Jira). cf. container + mimeType: + type: string + documentId: + type: string + description: The index-wide unique identifier. + loggingId: + type: string + description: A unique identifier used to represent the document in any logging or feedback requests in place of documentId. + documentIdHash: + type: string + description: Hash of the Glean Document ID. + createTime: + type: string + format: date-time + updateTime: + type: string + format: date-time + author: + $ref: "#/components/schemas/Person" + owner: + $ref: "#/components/schemas/Person" + mentionedPeople: + type: array + items: + $ref: "#/components/schemas/Person" + description: A list of people mentioned in the document. + visibility: + $ref: "#/components/schemas/DocumentVisibility" + components: + type: array + description: A list of components this result is associated with. Interpretation is specific to each datasource. (e.g. for Jira issues, these are [components](https://confluence.atlassian.com/jirasoftwarecloud/organizing-work-with-components-764478279.html).) + items: + type: string + status: + type: string + description: The status or disposition of the result. Interpretation is specific to each datasource. (e.g. for Jira issues, this is the issue status such as Done, In Progress or Will Not Fix). + statusCategory: + type: string + description: The status category of the result. Meant to be more general than status. Interpretation is specific to each datasource. + pins: + type: array + description: A list of stars associated with this result. "Pin" is an older name. + items: + $ref: "#/components/schemas/PinDocument" + priority: + type: string + description: The document priority. Interpretation is datasource specific. + assignedTo: + $ref: "#/components/schemas/Person" + updatedBy: + $ref: "#/components/schemas/Person" + labels: + type: array + description: A list of tags for the document. Interpretation is datasource specific. + items: + type: string + collections: + type: array + description: A list of collections that the document belongs to. + items: + $ref: "#/components/schemas/Collection" + datasourceId: + type: string + description: The user-visible datasource specific id (e.g. Salesforce case number for example, GitHub PR number). + interactions: + $ref: "#/components/schemas/DocumentInteractions" + verification: + $ref: "#/components/schemas/Verification" + viewerInfo: + $ref: "#/components/schemas/ViewerInfo" + permissions: + $ref: "#/components/schemas/ObjectPermissions" + visitCount: + $ref: "#/components/schemas/CountInfo" + shortcuts: + type: array + description: A list of shortcuts of which destination URL is for the document. + items: + $ref: "#/components/schemas/Shortcut" + path: + type: string + description: For file datasources like onedrive/github etc this has the path to the file + customData: + $ref: "#/components/schemas/CustomData" + documentCategory: + type: string + description: The document's document_category(.proto). + contactPerson: + $ref: "#/components/schemas/Person" + thumbnail: + $ref: "#/components/schemas/Thumbnail" + description: A thumbnail image representing this document. + indexStatus: + $ref: "#/components/schemas/IndexStatus" + ancestors: + type: array + description: A list of documents that are ancestors of this document in the hierarchy of the document's datasource, for example parent folders or containers. Ancestors can be of different types and some may not be indexed. Higher level ancestors appear earlier in the list. + items: + $ref: "#/components/schemas/Document" + example: + container: container + parentId: JIRA_EN-1337 + createTime: "2000-01-23T04:56:07.000Z" + datasource: datasource + author: + name: name + documentId: documentId + updateTime: "2000-01-23T04:56:07.000Z" + mimeType: mimeType + objectType: Feature Request + components: + - Backend + - Networking + status: + - Done + customData: + someCustomField: someCustomValue + DocumentSection: + type: object + properties: + title: + type: string + description: The title of the document section (e.g. the section header). + url: + type: string + description: The permalink of the document section. + StructuredTextItem: + properties: + link: + type: string + example: https://en.wikipedia.org/wiki/Diffuse_sky_radiation + document: + deprecated: true + description: Deprecated. To be gradually migrated to structuredResult. + $ref: "#/components/schemas/Document" + text: + type: string + example: Because its wavelengths are shorter, blue light is more strongly scattered than the longer-wavelength lights, red or green. Hence the result that when looking at the sky away from the direct incident sunlight, the human eye perceives the sky to be blue. + structuredResult: + $ref: "#/components/schemas/StructuredResult" + AnnouncementMutableProperties: + properties: + startTime: + type: string + format: date-time + description: The date and time at which the announcement becomes active. + endTime: + type: string + format: date-time + description: The date and time at which the announcement expires. + title: + type: string + description: The headline of the announcement. + body: + $ref: "#/components/schemas/StructuredText" + emoji: + type: string + description: An emoji used to indicate the nature of the announcement. + thumbnail: + $ref: "#/components/schemas/Thumbnail" + banner: + $ref: "#/components/schemas/Thumbnail" + description: Optional variant of thumbnail cropped for header background. + audienceFilters: + type: array + description: Filters which restrict who should see the announcement. Values are taken from the corresponding filters in people search. + items: + $ref: "#/components/schemas/FacetFilter" + sourceDocumentId: + type: string + description: The Glean Document ID of the source document this Announcement was created from (e.g. Slack thread). + hideAttribution: + type: boolean + description: Whether or not to hide an author attribution. + channel: + type: string + enum: + - MAIN + - SOCIAL_FEED + description: This determines whether this is a Social Feed post or a regular announcement. + postType: + type: string + enum: + - TEXT + - LINK + description: This determines whether this is an external-link post or a regular announcement post. TEXT - Regular announcement that can contain rich text. LINK - Announcement that is linked to an external site. + isPrioritized: + type: boolean + description: Used by the Social Feed to pin posts to the front of the feed. + viewUrl: + type: string + description: URL for viewing the announcement. It will be set to document URL for announcements from other datasources e.g. simpplr. Can only be written when channel="SOCIAL_FEED". + CreateAnnouncementRequest: + allOf: + - $ref: "#/components/schemas/AnnouncementMutableProperties" + - type: object + required: + - title + - startTime + - endTime + DraftProperties: + properties: + draftId: + type: integer + description: The opaque id of the associated draft. + example: + draftId: 342 + Announcement: + allOf: + - $ref: "#/components/schemas/AnnouncementMutableProperties" + - $ref: "#/components/schemas/DraftProperties" + - $ref: "#/components/schemas/PermissionedObject" + - type: object + properties: + id: + type: integer + description: The opaque id of the announcement. + author: + $ref: "#/components/schemas/Person" + createTimestamp: + type: integer + description: Server Unix timestamp of the creation time (in seconds since epoch UTC). + lastUpdateTimestamp: + type: integer + description: Server Unix timestamp of the last update time (in seconds since epoch UTC). + updatedBy: + $ref: "#/components/schemas/Person" + viewerInfo: + type: object + properties: + isDismissed: + type: boolean + description: Whether the viewer has dismissed the announcement. + isRead: + type: boolean + description: Whether the viewer has read the announcement. + sourceDocument: + $ref: "#/components/schemas/Document" + description: The source document if the announcement is created from one. + isPublished: + type: boolean + description: Whether or not the announcement is published. + DeleteAnnouncementRequest: + required: + - id + properties: + id: + type: integer + description: The opaque id of the announcement to be deleted. + UpdateAnnouncementRequest: + allOf: + - $ref: "#/components/schemas/AnnouncementMutableProperties" + - type: object + required: + - id + - title + - startTime + - endTime + properties: + id: + type: integer + description: The opaque id of the announcement. + AddedCollections: + properties: + addedCollections: + type: array + items: + type: integer + description: IDs of Collections to which a document is added. + AnswerCreationData: + allOf: + - $ref: "#/components/schemas/AnswerMutableProperties" + - $ref: "#/components/schemas/AddedCollections" + - type: object + properties: + combinedAnswerText: + $ref: "#/components/schemas/StructuredTextMutableProperties" + CreateAnswerRequest: + required: + - data + properties: + data: + $ref: "#/components/schemas/AnswerCreationData" + DeleteAnswerRequest: + allOf: + - $ref: "#/components/schemas/AnswerId" + - $ref: "#/components/schemas/AnswerDocId" + - type: object + required: + - id + RemovedCollections: + properties: + removedCollections: + type: array + items: + type: integer + description: IDs of Collections from which a document is removed. + EditAnswerRequest: + allOf: + - $ref: "#/components/schemas/AnswerId" + - $ref: "#/components/schemas/AnswerDocId" + - $ref: "#/components/schemas/AnswerMutableProperties" + - $ref: "#/components/schemas/AddedCollections" + - $ref: "#/components/schemas/RemovedCollections" + - type: object + required: + - id + properties: + combinedAnswerText: + $ref: "#/components/schemas/StructuredTextMutableProperties" + GetAnswerRequest: + allOf: + - $ref: "#/components/schemas/AnswerId" + - $ref: "#/components/schemas/AnswerDocId" + AnswerResult: + required: + - answer + properties: + answer: + $ref: "#/components/schemas/Answer" + trackingToken: + type: string + description: An opaque token that represents this particular Answer. To be used for `/feedback` reporting. + GetAnswerError: + properties: + errorType: + type: string + enum: + - NO_PERMISSION + - INVALID_ID + answerAuthor: + $ref: "#/components/schemas/Person" + GetAnswerResponse: + properties: + answerResult: + $ref: "#/components/schemas/AnswerResult" + error: + $ref: "#/components/schemas/GetAnswerError" + ListAnswersRequest: + properties: + boardId: + type: integer + description: The Answer Board Id to list answers on. + ListAnswersResponse: + required: + - answers + - answerResults + properties: + answerResults: + type: array + items: + $ref: "#/components/schemas/AnswerResult" + description: List of answers with tracking tokens. + CreateAuthTokenResponse: + required: + - token + - expirationTime + properties: + token: + type: string + description: An authentication token that can be passed to any endpoint via Bearer Authentication + expirationTime: + description: Unix timestamp for when this token expires (in seconds since epoch UTC). + type: integer + format: int64 + AgentConfig: + description: Describes the agent that executes the request. + properties: + agent: + type: string + description: Name of the agent. + x-enumDescriptions: + DEFAULT: Integrates with your company's knowledge. + GPT: Communicates directly with the LLM. + enum: + - DEFAULT + - GPT + mode: + type: string + description: Top level modes to run GleanChat in. + x-enumDescriptions: + DEFAULT: Used if no mode supplied. + QUICK: Deprecated. + enum: + - DEFAULT + - QUICK + ChatFileStatus: + type: string + description: Current status of the file. + x-include-enum-class-prefix: true + enum: + - PROCESSING + - PROCESSED + - FAILED + - DELETED + ChatFileFailureReason: + type: string + description: Reason for failed status. + x-include-enum-class-prefix: true + enum: + - PARSE_FAILED + - AV_SCAN_FAILED + - FILE_TOO_SMALL + - FILE_TOO_LARGE + - FILE_EXTENSION_UNSUPPORTED + - FILE_METADATA_VALIDATION_FAIL + - FILE_PROCESSING_TIMED_OUT + ChatFileMetadata: + type: object + description: Metadata of a file uploaded by a user for Chat. + properties: + status: + $ref: "#/components/schemas/ChatFileStatus" + uploadTime: + type: integer + format: int64 + description: Upload time, in epoch seconds. + processedSize: + type: integer + format: int64 + description: Size of the processed file in bytes. + failureReason: + $ref: "#/components/schemas/ChatFileFailureReason" + mimeType: + description: MIME type of the file. + type: string + ChatFile: + type: object + description: Structure for file uploaded by a user for Chat. + properties: + id: + type: string + description: Unique identifier of the file. + example: FILE_1234 + url: + type: string + description: Url of the file. + example: www.google.com + name: + type: string + description: Name of the uploaded file. + example: sample.pdf + metadata: + $ref: "#/components/schemas/ChatFileMetadata" + ReferenceRange: + description: Each text range from the response can correspond to an array of snippets from the citation source. + properties: + textRange: + $ref: "#/components/schemas/TextRange" + snippets: + type: array + items: + $ref: "#/components/schemas/SearchResultSnippet" + ChatMessageCitation: + description: Information about the source for a ChatMessage. + properties: + trackingToken: + type: string + description: An opaque token that represents this particular result in this particular ChatMessage. To be used for /feedback reporting. + sourceDocument: + $ref: "#/components/schemas/Document" + sourceFile: + $ref: "#/components/schemas/ChatFile" + sourcePerson: + $ref: "#/components/schemas/Person" + referenceRanges: + description: Each reference range and its corresponding snippets + type: array + items: + $ref: "#/components/schemas/ReferenceRange" + displayName: + description: Human understandable name of the tool. Max 50 characters. + type: string + logoUrl: + type: string + description: URL used to fetch the logo. + objectName: + type: string + description: Name of the generated object. This will be used to indicate to the end user what the generated object contains. + example: + - HR ticket + - Email + - Chat message + PersonObject: + required: + - name + - obfuscatedId + properties: + name: + type: string + description: The display name. + obfuscatedId: + type: string + description: An opaque identifier that can be used to request metadata for a Person. + AuthConfig: + description: Config for tool's authentication method. + type: object + properties: + isOnPrem: + type: boolean + description: Whether or not this tool is hosted on-premise. + usesCentralAuth: + type: boolean + description: Whether or not this uses central auth. + type: + type: string + enum: + - NONE + - OAUTH_USER + - OAUTH_ADMIN + - API_KEY + - BASIC_AUTH + - DWD + description: | + The type of authentication being used. + Use 'OAUTH_*' when Glean calls an external API (e.g., Jira) on behalf of a user to obtain an OAuth token. + 'OAUTH_ADMIN' utilizes an admin token for external API calls on behalf all users. + 'OAUTH_USER' uses individual user tokens for external API calls. + 'DWD' refers to domain wide delegation. + grantType: + type: string + enum: + - AUTH_CODE + - CLIENT_CREDENTIALS + description: The type of grant type being used. + status: + type: string + description: Auth status of the tool. + enum: + - AWAITING_AUTH + - AUTHORIZED + client_url: + type: string + format: url + description: The URL where users will be directed to start the OAuth flow. + scopes: + type: array + items: + type: string + description: A list of strings denoting the different scopes or access levels required by the tool. + audiences: + type: array + items: + type: string + description: A list of strings denoting the different audience which can access the tool. + authorization_url: + type: string + format: url + description: The OAuth provider's endpoint, where access tokens are requested. + lastAuthorizedAt: + type: string + format: date-time + description: The time the tool was last authorized in ISO format (ISO 8601). + ToolMetadata: + description: The manifest for a tool that can be used to augment Glean Assistant. + required: + - type + - name + - displayName + - displayDescription + properties: + type: + description: The type of tool. + type: string + enum: + - RETRIEVAL + - ACTION + name: + description: Unique identifier for the tool. Name should be understandable by the LLM, and will be used to invoke a tool. + type: string + displayName: + $ref: "#/components/schemas/displayName" + toolId: + type: string + description: An opaque id which is unique identifier for the tool. + displayDescription: + description: Description of the tool meant for a human. + type: string + logoUrl: + $ref: "#/components/schemas/logoUrl" + objectName: + $ref: "#/components/schemas/objectName" + knowledgeType: + type: string + description: Indicates the kind of knowledge a tool would access or modify. + enum: + - NEUTRAL_KNOWLEDGE + - COMPANY_KNOWLEDGE + - WORLD_KNOWLEDGE + createdBy: + $ref: "#/components/schemas/PersonObject" + lastUpdatedBy: + $ref: "#/components/schemas/PersonObject" + createdAt: + type: string + format: date-time + description: The time the tool was created in ISO format (ISO 8601) + lastUpdatedAt: + type: string + format: date-time + description: The time the tool was last updated in ISO format (ISO 8601) + writeActionType: + type: string + description: Valid only for write actions. Represents the type of write action. REDIRECT - The client renders the URL which contains information for carrying out the action. EXECUTION - Send a request to an external server and execute the action. + enum: + - REDIRECT + - EXECUTION + authType: + type: string + enum: + - NONE + - OAUTH_USER + - OAUTH_ADMIN + - API_KEY + - BASIC_AUTH + - DWD + description: | + The type of authentication being used. + Use 'OAUTH_*' when Glean calls an external API (e.g., Jira) on behalf of a user to obtain an OAuth token. + 'OAUTH_ADMIN' utilizes an admin token for external API calls on behalf all users. + 'OAUTH_USER' uses individual user tokens for external API calls. + 'DWD' refers to domain wide delegation. + auth: + deprecated: true + $ref: "#/components/schemas/AuthConfig" + permissions: + deprecated: true + $ref: "#/components/schemas/ObjectPermissions" + usageInstructions: + description: Usage instructions for the LLM to use this action. + type: string + isSetupFinished: + type: boolean + description: Whether this action has been fully configured and validated. + PossibleValue: + type: object + description: Possible value of a specific parameter + properties: + value: + type: string + description: Possible value + label: + type: string + description: User-friendly label associated with the value + WriteActionParameter: + type: object + properties: + type: + type: string + description: The type of the value (e.g., integer, string, boolean, etc.) + enum: + - UNKNOWN + - INTEGER + - STRING + - BOOLEAN + displayName: + type: string + description: Human readable display name for the key. + value: + type: string + description: The value of the field. + isRequired: + type: boolean + description: Is the parameter a required field. + description: + type: string + description: Description of the parameter. + possibleValues: + type: array + items: + $ref: "#/components/schemas/PossibleValue" + description: Possible values that the parameter can take. + ToolInfo: + type: object + properties: + metadata: + $ref: "#/components/schemas/ToolMetadata" + parameters: + type: object + description: Parameters supported by the tool. + additionalProperties: + $ref: "#/components/schemas/WriteActionParameter" + ChatMessageFragment: + description: Represents a part of a ChatMessage that originates from a single action/tool. It is designed to support rich data formats beyond simple text, allowing for a more dynamic and interactive chat experience. Each fragment can include various types of content, such as text, search queries, action information, and more. Also, each ChatMessageFragment should only have one of structuredResults, querySuggestion, writeAction, followupAction, or file. + allOf: + - $ref: "#/components/schemas/Result" + - type: object + properties: + text: + type: string + querySuggestion: + description: The search queries issued while responding. + $ref: "#/components/schemas/QuerySuggestion" + file: + description: Files referenced in the message fragment. This is used to construct rich-text messages with file references. + $ref: "#/components/schemas/ChatFile" + action: + description: Basic information about an action. This can be used to construct rich-text messages with action references. + $ref: "#/components/schemas/ToolInfo" + ChatMessage: + description: A message that is rendered as one coherent unit with one given sender. + properties: + agentConfig: + $ref: "#/components/schemas/AgentConfig" + description: Describes the agent config that generated this message. Populated on responses and not required on requests. + author: + default: USER + enum: + - USER + - GLEAN_AI + citations: + type: array + items: + $ref: "#/components/schemas/ChatMessageCitation" + description: A list of Citations that were used to generate the response. + uploadedFileIds: + type: array + items: + type: string + description: IDs of files uploaded in the message that are referenced to generate the answer. + fragments: + type: array + description: A list of rich data used to represent the response or formulate a request. These are linearly stitched together to support richer data formats beyond simple text. + items: + $ref: "#/components/schemas/ChatMessageFragment" + ts: + type: string + description: Response timestamp of the message. + messageId: + type: string + description: A unique server-side generated ID used to identify a message, automatically populated for any USER authored messages. + messageTrackingToken: + type: string + description: Opaque tracking token generated server-side. + messageType: + type: string + default: CONTENT + description: Semantically groups content of a certain type. It can be used for purposes such as differential UI treatment. USER authored messages should be of type CONTENT and do not need `messageType` specified. + x-enumDescriptions: + UPDATE: An intermediate state message for progress updates. + CONTENT: A user query or response message. + CONTEXT: A message providing context in addition to the user query. + DEBUG: A debug message. Strictly used internally. + DEBUG_EXTERNAL: A debug message to be used while debugging Action creation. + ERROR: A message that describes an error while processing the request. + HEADING: A heading message used to distinguish different sections of the holistic response. + WARNING: A warning message to be shown to the user. + enum: + - UPDATE + - CONTENT + - CONTEXT + - DEBUG + - DEBUG_EXTERNAL + - ERROR + - HEADING + - WARNING + hasMoreFragments: + deprecated: true + type: boolean + description: Signals there are additional response fragments incoming. + ChatRestrictionFilters: + allOf: + - $ref: "#/components/schemas/RestrictionFilters" + - type: object + properties: + documentSpecs: + type: array + items: + $ref: "#/components/schemas/DocumentSpec" + datasourceInstances: + type: array + items: + type: string + ChatRequest: + required: + - messages + properties: + saveChat: + type: boolean + description: Save the current interaction as a Chat for the user to access and potentially continue later. + chatId: + type: string + description: The id of the Chat that context should be retrieved from and messages added to. An empty id starts a new Chat, and the Chat is saved if saveChat is true. + messages: + type: array + description: A list of chat messages, from most recent to least recent. It can be assumed that the first chat message in the list is the user's most recent query. + items: + $ref: "#/components/schemas/ChatMessage" + agentConfig: + $ref: "#/components/schemas/AgentConfig" + description: Describes the agent that will execute the request. + inclusions: + $ref: "#/components/schemas/ChatRestrictionFilters" + description: A list of filters which only allows chat to access certain content. + exclusions: + $ref: "#/components/schemas/ChatRestrictionFilters" + description: A list of filters which disallows chat from accessing certain content. If content is in both inclusions and exclusions, it'll be excluded. + timeoutMillis: + type: integer + description: Timeout in milliseconds for the request. A `408` error will be returned if handling the request takes longer. + example: 30000 + applicationId: + type: string + description: The ID of the application this request originates from, used to determine the configuration of underlying chat processes. This should correspond to the ID set during admin setup. If not specified, the default chat experience will be used. + stream: + type: boolean + description: If set, response lines will be streamed one-by-one as they become available. Each will be a ChatResponse, formatted as JSON, and separated by a new line. If false, the entire response will be returned at once. Note that if this is set and the model being used does not support streaming, the model's response will not be streamed, but other messages from the endpoint still will be. + ChatResponse: + description: A single response from the /chat backend. + properties: + messages: + type: array + items: + $ref: "#/components/schemas/ChatMessage" + chatId: + type: string + description: The id of the associated Chat the messages belong to, if one exists. + followUpPrompts: + type: array + items: + type: string + description: Follow-up prompts for the user to potentially use + backendTimeMillis: + type: integer + format: int64 + description: Time in milliseconds the backend took to respond to the request. + example: 1100 + chatSessionTrackingToken: + type: string + description: A token that is used to track the session. + DeleteChatsRequest: + required: + - ids + properties: + ids: + type: array + items: + type: string + description: A non-empty list of ids of the Chats to be deleted. + GetChatRequest: + required: + - id + properties: + id: + type: string + description: The id of the Chat to be retrieved. + ChatMetadata: + description: Metadata of a Chat a user had with Glean Assistant. This contains no actual conversational content. + properties: + id: + type: string + description: The opaque id of the Chat. + createTime: + type: integer + description: Server Unix timestamp of the creation time (in seconds since epoch UTC). + createdBy: + $ref: "#/components/schemas/Person" + description: The user who created this Chat. + updateTime: + type: integer + description: Server Unix timestamp of the update time (in seconds since epoch UTC). + name: + type: string + description: The name of the Chat. + applicationId: + type: string + description: The ID of the AI App that this Chat is associated to. + applicationName: + type: string + description: The display name of the AI App that this Chat is associated to. + icon: + $ref: "#/components/schemas/IconConfig" + Chat: + description: A historical representation of a series of chat messages a user had with Glean Assistant. + allOf: + - $ref: "#/components/schemas/ChatMetadata" + properties: + messages: + type: array + items: + $ref: "#/components/schemas/ChatMessage" + description: The chat messages within a Chat. + ChatResult: + properties: + chat: + $ref: "#/components/schemas/Chat" + trackingToken: + type: string + description: An opaque token that represents this particular Chat. To be used for `/feedback` reporting. + GetChatResponse: + properties: + chatResult: + $ref: "#/components/schemas/ChatResult" + ChatMetadataResult: + properties: + chat: + $ref: "#/components/schemas/ChatMetadata" + trackingToken: + type: string + description: An opaque token that represents this particular Chat. To be used for `/feedback` reporting. + ListChatsResponse: + properties: + chatResults: + type: array + items: + $ref: "#/components/schemas/ChatMetadataResult" + x-includeEmpty: true + GetChatApplicationRequest: + required: + - id + properties: + id: + type: string + description: The id of the Chat application to be retrieved. + ChatApplicationDetails: {} + GetChatApplicationResponse: + properties: + application: + $ref: "#/components/schemas/ChatApplicationDetails" + UploadChatFilesRequest: + required: + - files + properties: + files: + type: array + items: + type: string + format: binary + description: Raw files to be uploaded for chat in binary format. + UploadChatFilesResponse: + properties: + files: + type: array + items: + $ref: "#/components/schemas/ChatFile" + description: Files uploaded for chat. + GetChatFilesRequest: + required: + - fileIds + properties: + fileIds: + type: array + items: + type: string + description: IDs of files to fetch. + GetChatFilesResponse: + properties: + files: + description: A map of file IDs to ChatFile structs. + type: object + additionalProperties: + $ref: "#/components/schemas/ChatFile" + DeleteChatFilesRequest: + required: + - fileIds + properties: + fileIds: + type: array + items: + type: string + description: IDs of files to delete. + Agent: + title: Agent + type: object + required: + - agent_id + - name + - capabilities + properties: + agent_id: + type: string + title: Agent Id + description: The ID of the agent. + name: + type: string + title: Agent Name + description: The name of the agent + description: + type: string + title: Description + description: The description of the agent. + metadata: + type: object + title: Metadata + description: The agent metadata. + capabilities: + type: object + title: Agent Capabilities + description: Describes which protocol features the agent supports. In addition to the standard capabilities (prefixed with ap.), implementations can declare custom capabilities, named in reverse domain notation (eg. com.example.some.capability). + properties: + ap.io.messages: + type: boolean + title: Messages + description: Whether the agent supports Messages as input/output/state. If true, the agent uses the `messages` key in threads/runs endpoints. + ap.io.streaming: + type: boolean + title: Streaming + description: Whether the agent supports streaming output. + additionalProperties: true + ErrorResponse: + type: string + title: ErrorResponse + description: Error message returned from the server + AgentSchemas: + properties: + agent_id: + type: string + title: Agent Id + description: The ID of the agent. + input_schema: + type: object + title: Input Schema + description: The schema for the agent input. In JSON Schema format. + output_schema: + type: object + title: Output Schema + description: The schema for the agent output. In JSON Schema format. + type: object + required: + - agent_id + - input_schema + - output_schema + title: AgentSchemas + description: Defines the structure and properties of an agent. + SearchAgentsRequest: + type: object + properties: + name: + type: string + description: Filters on the name of the agent. If empty, acts as no filter. + SearchAgentsResponse: + type: object + title: Response Search Agents + properties: + agents: + type: array + items: + $ref: "#/components/schemas/Agent" + ContentType: + type: string + enum: + - text + Message: + type: object + properties: + role: + type: string + title: Role + description: The role of the message. + content: + title: Content + description: The content of the message. + type: array + items: + type: object + properties: + text: + type: string + type: + $ref: "#/components/schemas/ContentType" + required: + - text + - type + title: MessageTextBlock + AgentRunCreate: + description: Payload for creating a run. + type: object + properties: + agent_id: + type: string + title: Agent Id + description: The ID of the agent to run. + input: + type: object + title: Input + description: The input to the agent. + additionalProperties: true + messages: + type: array + items: + $ref: "#/components/schemas/Message" + title: Messages + description: The messages to pass an input to the agent. + AgentExecutionStatus: + description: The status of the run. One of 'error', 'success'. + type: string + enum: + - error + - success + title: AgentExecutionStatus + AgentRun: + allOf: + - $ref: "#/components/schemas/AgentRunCreate" + - type: object + properties: + status: + $ref: "#/components/schemas/AgentExecutionStatus" + AgentRunWaitResponse: + type: object + properties: + run: + $ref: "#/components/schemas/AgentRun" + title: Run + description: The run information. + messages: + type: array + items: + $ref: "#/components/schemas/Message" + title: Messages + description: The messages returned by the run. + CollectionItemDescriptor: + allOf: + - $ref: "#/components/schemas/CollectionItemMutableProperties" + properties: + url: + type: string + description: The URL of the item being added. + documentId: + type: string + description: The Glean Document ID of the item being added if it's an indexed document. + newNextItemId: + type: string + description: The (optional) ItemId of the next CollectionItem in sequence. If omitted, will be added to the end of the Collection + itemType: + type: string + enum: + - DOCUMENT + - TEXT + - URL + AddCollectionItemsRequest: + required: + - collectionId + properties: + collectionId: + type: number + description: The ID of the Collection to add items to. + addedCollectionItemDescriptors: + type: array + items: + $ref: "#/components/schemas/CollectionItemDescriptor" + description: The CollectionItemDescriptors of the items being added. + AddCollectionItemsError: + properties: + errorType: + type: string + enum: + - EXISTING_ITEM + AddCollectionItemsResponse: + properties: + collection: + $ref: "#/components/schemas/Collection" + description: The modified Collection. Only CollectionItemMutableProperties are set for each item. + error: + $ref: "#/components/schemas/AddCollectionItemsError" + CreateCollectionRequest: + allOf: + - $ref: "#/components/schemas/CollectionMutableProperties" + - type: object + properties: + newNextItemId: + type: string + description: The (optional) ItemId of the next CollectionItem in sequence. If omitted, will be added to the end of the Collection. Only used if parentId is specified. + CollectionError: + required: + - errorCode + properties: + errorCode: + type: string + enum: + - NAME_EXISTS + - NOT_FOUND + - COLLECTION_PINNED + - CONCURRENT_HIERARCHY_EDIT + - HEIGHT_VIOLATION + - WIDTH_VIOLATION + - NO_PERMISSIONS + CreateCollectionResponse: + allOf: + - $ref: "#/components/schemas/Collection" + - $ref: "#/components/schemas/CollectionError" + - type: object + properties: + collection: + $ref: "#/components/schemas/Collection" + error: + $ref: "#/components/schemas/CollectionError" + DeleteCollectionRequest: + required: + - ids + properties: + ids: + type: array + items: + type: integer + description: The IDs of the Collections to delete. + allowedDatasource: + type: string + description: The datasource allowed in the Collection to be deleted. + DeleteCollectionItemRequest: + required: + - collectionId + - itemId + properties: + collectionId: + type: number + description: The ID of the Collection to remove an item in. + itemId: + type: string + description: The item ID of the CollectionItem to remove from this Collection. + documentId: + type: string + description: The (optional) Glean Document ID of the CollectionItem to remove from this Collection if this is an indexed document. + DeleteCollectionItemResponse: + properties: + collection: + $ref: "#/components/schemas/Collection" + description: The modified Collection. Only CollectionItemMutableProperties are set for each item. + EditCollectionRequest: + allOf: + - $ref: "#/components/schemas/CollectionMutableProperties" + - type: object + required: + - id + properties: + id: + type: integer + description: The ID of the Collection to modify. + EditCollectionResponse: + allOf: + - $ref: "#/components/schemas/Collection" + - $ref: "#/components/schemas/CollectionError" + - type: object + properties: + collection: + $ref: "#/components/schemas/Collection" + error: + $ref: "#/components/schemas/CollectionError" + EditCollectionItemRequest: + required: + - collectionId + - itemId + allOf: + - $ref: "#/components/schemas/CollectionItemMutableProperties" + - type: object + properties: + collectionId: + type: integer + description: The ID of the Collection to edit CollectionItems in. + itemId: + type: string + description: The ID of the CollectionItem to edit. + EditCollectionItemResponse: + properties: + collection: + $ref: "#/components/schemas/Collection" + description: The modified Collection. Only CollectionItemMutableProperties are set for each item. + GetCollectionRequest: + required: + - id + properties: + id: + type: integer + description: The ID of the Collection to be retrieved. + withItems: + type: boolean + description: Whether or not to include the Collection Items in this Collection. Only request if absolutely required, as this is expensive. + withHierarchy: + type: boolean + description: Whether or not to include the top level Collection in this Collection's hierarchy. + allowedDatasource: + type: string + description: The datasource allowed in the Collection returned. + GetCollectionResponse: + properties: + collection: + $ref: "#/components/schemas/Collection" + rootCollection: + $ref: "#/components/schemas/Collection" + trackingToken: + type: string + description: An opaque token that represents this particular Collection. To be used for `/feedback` reporting. + error: + $ref: "#/components/schemas/CollectionError" + ListCollectionsRequest: + properties: + includeAudience: + type: boolean + description: Whether to include the audience filters with the listed Collections. + includeRoles: + type: boolean + description: Whether to include the editor roles with the listed Collections. + allowedDatasource: + type: string + description: |- + The datasource type this Collection can hold. + ANSWERS - for Collections representing answer boards + ListCollectionsResponse: + required: + - collections + properties: + collections: + type: array + items: + $ref: "#/components/schemas/Collection" + description: List of all Collections, no Collection items are fetched. + GetDocPermissionsRequest: + type: object + properties: + documentId: + type: string + description: The Glean Document ID to retrieve permissions for. + GetDocPermissionsResponse: + type: object + properties: + allowedUserEmails: + type: array + items: + type: string + description: A list of emails of users who have access to the document. If the document is visible to all Glean users, a list with only a single value of 'VISIBLE_TO_ALL'. + GetDocumentsRequest: + required: + - documentSpecs + properties: + documentSpecs: + type: array + items: + $ref: "#/components/schemas/DocumentSpec" + description: The specification for the documents to be retrieved. + includeFields: + description: List of Document fields to return (that aren't returned by default) + type: array + items: + type: string + enum: + - LAST_VIEWED_AT + - VISITORS_COUNT + - RECENT_SHARES + - DOCUMENT_CONTENT + DocumentOrError: + oneOf: + - $ref: "#/components/schemas/Document" + - type: object + properties: + error: + type: string + description: The text for error, reason. + GetDocumentsResponse: + properties: + documents: + type: object + additionalProperties: + $ref: "#/components/schemas/DocumentOrError" + description: The document details or the error if document is not found. + GetDocumentsByFacetsRequest: + required: + - filterSets + properties: + datasourcesFilter: + type: array + items: + type: string + description: Filter results to one or more datasources (e.g. gmail, slack). All results are returned if missing. + filterSets: + type: array + items: + $ref: "#/components/schemas/FacetFilterSet" + description: A list of facet filter sets that will be OR'ed together. An AND is assumed between different filters in each set. + cursor: + type: string + description: Pagination cursor. A previously received opaque token representing the position in the overall results at which to start. + GetDocumentsByFacetsResponse: + properties: + documents: + type: array + items: + $ref: "#/components/schemas/Document" + description: The document details, ordered by score. + hasMoreResults: + type: boolean + description: Whether more results are available. Use cursor to retrieve them. + cursor: + type: string + description: Cursor that indicates the start of the next page of results. To be passed in "more" requests for this query. + InsightsAiAppRequestOptions: + type: object + properties: + aiAppIds: + type: array + items: + type: string + description: IDs of the AI Apps for which Insights should be returned. An empty array signifies all. + InsightsAgentsRequestOptions: + type: object + properties: + agentIds: + type: array + items: + type: string + description: IDs of the Agents for which Insights should be returned. An empty array signifies all. + DownloadInsightsRequest: + required: + - categories + properties: + categories: + type: array + items: + type: string + enum: + - AGENTS + - AI + - AI_APPS + - ANNOUNCEMENTS + - ANSWERS + - COLLECTIONS + - CONTENT + - GLEAN_ASSIST + - QUERIES + - SHORTCUTS + - USERS + description: Categories of data requested. Request can include single or multiple types. + departments: + type: array + items: + type: string + description: Departments that the data is requested for. If this is empty, corresponds to whole company. + dayRange: + $ref: "#/components/schemas/Period" + aiAppRequestOptions: + $ref: "#/components/schemas/InsightsAiAppRequestOptions" + agentsRequestOptions: + $ref: "#/components/schemas/InsightsAgentsRequestOptions" + InsightsRequest: + allOf: + - $ref: "#/components/schemas/DownloadInsightsRequest" + - type: object + properties: + assistantActivityTypes: + type: array + items: + type: string + enum: + - GLEAN_CHAT + - AI_SUMMARY + - AI_ANSWER + - GLEANBOT_RESPONSE + description: Types of activity that should count in the definition of an Assistant Active User. Affects only insights for AI category. + disablePerUserInsights: + type: boolean + description: If true, suppresses the generation of per-user Insights in the response. Default is false. + LabeledCountInfo: + required: + - label + properties: + label: + type: string + description: Label for the included count information. + countInfo: + type: array + items: + $ref: "#/components/schemas/CountInfo" + description: List of data points for counts for a given date period. + UserActivityInsight: + required: + - user + - activity + properties: + user: + $ref: "#/components/schemas/Person" + activity: + type: string + enum: + - ALL + - SEARCH + description: Activity e.g. search, home page visit or all. + lastActivityTimestamp: + type: integer + description: Unix timestamp of the last activity (in seconds since epoch UTC). + activityCount: + $ref: "#/components/schemas/CountInfo" + activeDayCount: + $ref: "#/components/schemas/CountInfo" + UserInsightsResponse: + properties: + lastLogTimestamp: + type: integer + description: Unix timestamp of the last activity processed to make the response (in seconds since epoch UTC). + activityInsights: + type: array + items: + $ref: "#/components/schemas/UserActivityInsight" + description: Insights for all active users with respect to set of actions. + inactiveInsights: + type: array + items: + $ref: "#/components/schemas/UserActivityInsight" + description: Insights for all in inactive users with respect to set of actions and time period. Activity count will be set to 0. + totalTeammates: + type: integer + description: Total number of teammates that have logged in to the product, that are still valid teammates. + totalActiveUsers: + type: integer + description: Total number of active users in the requested period. + departments: + type: array + items: + type: string + description: list of departments applicable for users tab. + DocumentInsight: + required: + - document + properties: + document: + $ref: "#/components/schemas/Document" + viewCount: + $ref: "#/components/schemas/CountInfo" + visitorCount: + $ref: "#/components/schemas/CountInfo" + ContentInsightsResponse: + properties: + lastLogTimestamp: + type: integer + description: Unix timestamp of the last activity processed to make the response (in seconds since epoch UTC). + documentInsights: + type: array + items: + $ref: "#/components/schemas/DocumentInsight" + description: Insights for documents. + departments: + type: array + items: + type: string + description: list of departments applicable for contents tab. + minDepartmentSizeThreshold: + type: integer + description: Min threshold in size of departments while populating results, otherwise 0. + minVisitorThreshold: + type: integer + description: Minimum number of visitors to a document required to be included in insights. + QueryInsight: + required: + - query + properties: + query: + type: string + description: The query string the information is about. + searchCount: + $ref: "#/components/schemas/CountInfo" + searchorCount: + $ref: "#/components/schemas/CountInfo" + searchWithClickCount: + $ref: "#/components/schemas/CountInfo" + clickCount: + $ref: "#/components/schemas/CountInfo" + similarQueries: + type: array + items: + $ref: "#/components/schemas/QueryInsight" + description: list of similar queries to current one. + QueryInsightsResponse: + properties: + lastLogTimestamp: + type: integer + description: Unix timestamp of the last activity processed to make the response (in seconds since epoch UTC). + queryInsights: + type: array + items: + $ref: "#/components/schemas/QueryInsight" + description: Insights for queries. + lowPerformingQueryInsights: + type: array + items: + $ref: "#/components/schemas/QueryInsight" + description: Insights for low performing queries without good results. + departments: + type: array + items: + type: string + description: list of departments applicable for queries tab. + minVisitorThreshold: + type: integer + description: Min threshold in number of visitors while populating results, otherwise 0. + ShortcutInsight: + required: + - shortcut + properties: + shortcut: + $ref: "#/components/schemas/Shortcut" + visitCount: + $ref: "#/components/schemas/CountInfo" + visitorCount: + $ref: "#/components/schemas/CountInfo" + ShortcutInsightsResponse: + properties: + lastLogTimestamp: + type: integer + description: Unix timestamp of the last activity processed to make the response (in seconds since epoch UTC). + shortcutInsights: + type: array + items: + $ref: "#/components/schemas/ShortcutInsight" + description: Insights for shortcuts. + departments: + type: array + items: + type: string + description: list of departments applicable for shortcuts tab. + minVisitorThreshold: + type: integer + description: Min threshold in number of visitors while populating results, otherwise 0. + AiInsightsResponse: + properties: + lastLogTimestamp: + type: integer + description: Unix timestamp of the last activity processed to make the response (in seconds since epoch UTC). + assistantInsights: + type: array + items: + $ref: "#/components/schemas/UserActivityInsight" + totalActiveAssistantUsers: + type: integer + description: Total number of Active Assistant users (chat, summary, AIA) in requested period. + totalChatMessages: + type: integer + description: Total number of Chat messages sent in requested period. + totalAiSummarizations: + type: integer + description: Total number of AI Document Summarizations invoked in the requested period. + totalAiAnswers: + type: integer + description: Total number of AI Answers generated in the requested period. + totalUpvotes: + type: integer + description: Total number of Chat messages which received upvotes by the user. + totalDownvotes: + type: integer + description: Total number of Chat messages which received downvotes by the user. + totalGleanbotResponses: + type: integer + description: Total number of Gleanbot responses, both proactive and reactive. + totalGleanbotResponsesShared: + type: integer + description: Total number of Gleanbot responses shared publicly (upvoted). + totalGleanbotResponsesNotHelpful: + type: integer + description: Total number of Glean responses rejected as not helpful (downvoted). + departments: + type: array + items: + type: string + description: list of departments applicable for users tab. + AiAppActionCounts: + type: object + additionalProperties: + type: integer + description: Map from action to frequency. + properties: + totalSlackbotResponses: + type: integer + description: Total number of Slackbot responses, both proactive and reactive. + totalSlackbotResponsesShared: + type: integer + description: Total number of Slackbot responses shared publicly (upvoted). + totalSlackbotResponsesNotHelpful: + type: integer + description: Total number of Slackbot responses rejected as not helpful (downvoted). + totalChatMessages: + type: integer + description: Total number of Chat messages sent in requested period. + totalUpvotes: + type: integer + description: Total number of Chat messages which received upvotes by the user. + totalDownvotes: + type: integer + description: Total number of Chat messages which received downvotes by the user. + AiAppsInsightsResponse: + properties: + lastLogTimestamp: + type: integer + description: Unix timestamp of the last activity processed to make the response (in seconds since epoch UTC). + aiAppInsights: + type: array + items: + $ref: "#/components/schemas/UserActivityInsight" + totalActiveUsers: + type: integer + description: Total number of active users on the Ai App in the requested period. + actionCounts: + $ref: "#/components/schemas/AiAppActionCounts" + departments: + type: array + items: + type: string + description: list of departments applicable for users tab. + GleanAssistInsightsResponse: + properties: + lastLogTimestamp: + type: integer + description: Unix timestamp of the last activity processed to make the response (in seconds since epoch UTC). + activityInsights: + type: array + items: + $ref: "#/components/schemas/UserActivityInsight" + description: Insights for all active users with respect to set of actions. + totalActiveUsers: + type: integer + description: Total number of active users in the requested period. + datasourceInstances: + type: array + items: + type: string + description: List of datasource instances for which glean assist is enabled. + departments: + type: array + items: + type: string + description: List of departments applicable for users tab. + InsightsResponse: + properties: + timeseries: + type: array + items: + $ref: "#/components/schemas/LabeledCountInfo" + description: List of timeseries to make charts (if applicable). + users: + $ref: "#/components/schemas/UserInsightsResponse" + content: + $ref: "#/components/schemas/ContentInsightsResponse" + queries: + $ref: "#/components/schemas/QueryInsightsResponse" + collections: + $ref: "#/components/schemas/ContentInsightsResponse" + collectionsV2: + $ref: "#/components/schemas/ContentInsightsResponse" + shortcuts: + $ref: "#/components/schemas/ShortcutInsightsResponse" + announcements: + $ref: "#/components/schemas/ContentInsightsResponse" + answers: + $ref: "#/components/schemas/ContentInsightsResponse" + ai: + $ref: "#/components/schemas/AiInsightsResponse" + aiApps: + $ref: "#/components/schemas/AiAppsInsightsResponse" + gleanAssist: + $ref: "#/components/schemas/GleanAssistInsightsResponse" + departments: + type: array + items: + type: string + description: list of all departments. + MessagesRequest: + required: + - id + - idType + properties: + idType: + type: string + enum: + - CHANNEL_NAME + - THREAD_ID + - CONVERSATION_ID + description: Type of the id in the incoming request. + id: + type: string + description: ID corresponding to the requested idType. Note that channel and threads are represented by the underlying datasource's ID and conversations are represented by their document's ID. + workspaceId: + type: string + description: Id for the for the workspace in case of multiple workspaces. + direction: + type: string + enum: + - OLDER + - NEWER + description: The direction of the results asked with respect to the reference timestamp. Missing field defaults to OLDER. Only applicable when using a message_id. + timestampMillis: + type: integer + format: int64 + description: Timestamp in millis of the reference message. Only applicable when using a message_id. + includeRootMessage: + type: boolean + description: Whether to include root message in response. + datasource: + type: string + enum: + - SLACK + - MICROSOFTTEAMS + - FACEBOOKWORKPLACE + description: The type of the data source. Missing field defaults to SLACK. + datasourceInstanceDisplayName: + type: string + description: The datasource instance display name from which the document was extracted. This is used for appinstance facet filter for datasources that support multiple instances. + FollowupAction: + description: A follow-up action that can be invoked by the user after a response. The action parameters are not included and need to be predicted/filled separately. + properties: + actionRunId: + type: string + description: Unique identifier for this actionRun recommendation event. + actionInstanceId: + type: string + description: The ID of the action instance that will be invoked. + actionId: + type: string + description: The ID of the associated action. + recommendationText: + type: string + description: Text to be displayed to the user when recommending the action instance. + actionLabel: + type: string + description: The label to be used when displaying a button to execute this action instance. + userConfirmationRequired: + type: boolean + description: Whether user confirmation is needed before executing this action instance. + GeneratedQna: + properties: + question: + type: string + description: Search query rephrased into a question. + answer: + type: string + description: Answer generated for the given query or the generated question. + followUpPrompts: + type: array + items: + type: string + description: List of all follow-up prompts generated for the given query or the generated question. + followupActions: + description: List of follow-up actions generated for the given query or the generated question. + type: array + items: + $ref: "#/components/schemas/FollowupAction" + ranges: + type: array + items: + $ref: "#/components/schemas/TextRange" + description: Answer subsections to mark with special formatting (citations, bolding etc) + status: + type: string + enum: + - COMPUTING + - DISABLED + - FAILED + - NO_ANSWER + - SKIPPED + - STREAMING + - SUCCEEDED + - TIMEOUT + description: Status of backend generating the answer + cursor: + type: string + description: An opaque cursor representing the search request + trackingToken: + type: string + description: An opaque token that represents this particular result in this particular query. To be used for /feedback reporting. + InvalidOperatorValueError: + properties: + key: + description: The operator key that has an invalid value. + type: string + value: + description: The invalid operator value. + type: string + ErrorMessage: + properties: + source: + description: The datasource this message relates to. + type: string + errorMessage: + type: string + ErrorInfo: + properties: + badGmailToken: + type: boolean + description: Indicates the gmail results could not be fetched due to bad token. + badOutlookToken: + type: boolean + description: Indicates the outlook results could not be fetched due to bad token. + invalidOperators: + type: array + description: Indicates results could not be fetched due to invalid operators in the query. + items: + $ref: "#/components/schemas/InvalidOperatorValueError" + errorMessages: + type: array + items: + $ref: "#/components/schemas/ErrorMessage" + x-speakeasy-name-override: GleanDataError + ResultsResponse: + properties: + trackingToken: + type: string + description: A token that should be passed for additional requests related to this request (such as more results requests). + sessionInfo: + $ref: "#/components/schemas/SessionInfo" + results: + type: array + items: + $ref: "#/components/schemas/SearchResult" + structuredResults: + type: array + items: + $ref: "#/components/schemas/StructuredResult" + generatedQnaResult: + $ref: "#/components/schemas/GeneratedQna" + errorInfo: + $ref: "#/components/schemas/ErrorInfo" + requestID: + type: string + description: A platform-generated request ID to correlate backend logs. + backendTimeMillis: + type: integer + format: int64 + description: Time in milliseconds the backend took to respond to the request. + example: 1100 + BackendExperimentsContext: + properties: + experimentIds: + type: array + items: + type: integer + format: int64 + description: List of experiment ids for the corresponding request. + SearchWarning: + required: + - warningType + properties: + warningType: + type: string + enum: + - LONG_QUERY + - QUOTED_PUNCTUATION + - PUNCTUATION_ONLY + - COPYPASTED_QUOTES + - INVALID_OPERATOR + - MAYBE_INVALID_FACET_QUERY + description: The type of the warning. + lastUsedTerm: + type: string + description: The last term we considered in the user's long query. + quotesIgnoredQuery: + type: string + description: The query after ignoring/removing quotes. + ignoredTerms: + type: array + items: + type: string + description: A list of query terms that were ignored when generating search results, if any. For example, terms containing invalid filters such as "updated:invalid_date" will be ignored. + SearchResponseMetadata: + properties: + rewrittenQuery: + type: string + description: A cleaned up or updated version of the query to be displayed in the query box. Useful for mapping visual facets to search operators. + searchedQuery: + type: string + description: The actual query used to perform search and return results. + searchedQueryRanges: + type: array + items: + $ref: "#/components/schemas/TextRange" + description: The bolded ranges within the searched query. + originalQuery: + type: string + description: The query text sent by the client in the request. + querySuggestion: + $ref: "#/components/schemas/QuerySuggestion" + description: An alternative query to the one provided that may give better results, e.g. a spelling suggestion. + additionalQuerySuggestions: + $ref: "#/components/schemas/QuerySuggestionList" + description: Other alternative queries that may provide better or more specific results than the original query. + negatedTerms: + type: array + items: + type: string + description: A list of terms that were negated when processing the query. + modifiedQueryWasUsed: + type: boolean + description: A different query was performed than the one requested. + originalQueryHadNoResults: + type: boolean + description: No results were found for the original query. The usage of this bit in conjunction with modifiedQueryWasUsed will dictate whether the full page replacement is 0-result or few-result based. + searchWarning: + $ref: "#/components/schemas/SearchWarning" + triggeredExpertDetection: + type: boolean + description: Whether the query triggered expert detection results in the People tab. + isNoQuotesSuggestion: + type: boolean + description: Whether the query was modified to remove quotes + FacetValue: + properties: + stringValue: + type: string + example: engineering + description: The value that should be set in the FacetFilter when applying this filter to a search request. + integerValue: + type: integer + example: 5 + displayLabel: + type: string + example: engineering + description: An optional user-friendly label to display in place of the facet value. + iconConfig: + $ref: "#/components/schemas/IconConfig" + FacetBucket: + properties: + count: + type: integer + description: Estimated number of results in this facet. + example: 1 + datasource: + type: string + example: jira + description: The datasource the value belongs to. This will be used by the all tab to show types across all datasources. + percentage: + type: integer + description: Estimated percentage of results in this facet. + example: 5 + value: + $ref: "#/components/schemas/FacetValue" + FacetResult: + properties: + sourceName: + type: string + description: The source of this facet (e.g. container_name, type, last_updated_at). + example: container_name + operatorName: + type: string + description: How to display this facet. Currently supportes 'SelectSingle' and 'SelectMultiple'. + example: SelectMultiple + buckets: + type: array + description: A list of unique buckets that exist within this result set. + items: + $ref: "#/components/schemas/FacetBucket" + hasMoreBuckets: + type: boolean + description: Returns true if more buckets exist than those returned. Additional buckets can be retrieve by requesting again with a higher facetBucketSize. + example: false + groupName: + type: string + description: For most facets this will be the empty string, meaning the facet is high-level and applies to all documents for the datasource. When non-empty, this is used to group facets together (i.e. group facets for each doctype for a certain datasource) + example: Service Cloud + ResultTab: + properties: + id: + type: string + description: The unique ID of the tab. Can be passed in a search request to get results for that tab. + count: + type: integer + description: The number of results in this tab for the current query. + datasource: + type: string + description: The datasource associated with the tab, if any. + datasourceInstance: + type: string + description: The datasource instance associated with the tab, if any. + ResultsDescription: + properties: + text: + type: string + description: Textual description of the results. Can be shown at the top of SERP, e.g. 'People who write about this topic' for experts in people tab. + iconConfig: + $ref: "#/components/schemas/IconConfig" + description: The config for the icon that's displayed with this description + SearchResponse: + allOf: + - $ref: "#/components/schemas/ResultsResponse" + - $ref: "#/components/schemas/BackendExperimentsContext" + - type: object + properties: + metadata: + $ref: "#/components/schemas/SearchResponseMetadata" + facetResults: + type: array + items: + $ref: "#/components/schemas/FacetResult" + resultTabs: + type: array + items: + $ref: "#/components/schemas/ResultTab" + description: All result tabs available for the current query. Populated if QUERY_METADATA is specified in the request. + resultTabIds: + type: array + items: + type: string + description: The unique IDs of the result tabs to which this response belongs. + resultsDescription: + $ref: "#/components/schemas/ResultsDescription" + rewrittenFacetFilters: + type: array + items: + $ref: "#/components/schemas/FacetFilter" + description: The actual applied facet filters based on the operators and facetFilters in the query. Useful for mapping typed operators to visual facets. + cursor: + type: string + description: Cursor that indicates the start of the next page of results. To be passed in "more" requests for this query. + hasMoreResults: + type: boolean + description: Whether more results are available. Use cursor to retrieve them. + example: + trackingToken: trackingToken + suggestedSpellCorrectedQuery: suggestedSpellCorrectedQuery + hasMoreResults: true + errorInfo: + errorMessages: + - source: gmail + errorMessage: invalid token + - source: slack + errorMessage: expired token + requestID: 5e345ae500ff0befa2b9d1a3ba0001737e7363696f312d323535323137000171756572792d656e64706f696e743a323032303031333074313830343032000100 + results: + - snippets: + - snippet: snippet + mimeType: mimeType + metadata: + container: container + createTime: "2000-01-23T04:56:07.000Z" + datasource: datasource + author: + name: name + documentId: documentId + updateTime: "2000-01-23T04:56:07.000Z" + mimeType: mimeType + objectType: objectType + title: title + url: https://www.example.com/ + - snippets: + - snippet: snippet + mimeType: mimeType + metadata: + container: container + createTime: "2000-01-23T04:56:07.000Z" + datasource: datasource + author: + name: name + documentId: documentId + updateTime: "2000-01-23T04:56:07.000Z" + mimeType: mimeType + objectType: objectType + title: title + url: https://www.example.com/ + facetResults: + - buckets: + - percentage: 5 + count: 1 + value: + stringValue: stringValue + integerValue: 5 + - percentage: 5 + count: 1 + value: + stringValue: stringValue + integerValue: 5 + sourceName: sourceName + operatorName: operatorName + objectType: objectType + - buckets: + - percentage: 5 + count: 1 + value: + stringValue: stringValue + integerValue: 5 + - percentage: 5 + count: 1 + value: + stringValue: stringValue + integerValue: 5 + sourceName: sourceName + operatorName: operatorName + objectType: objectType + rewrittenQuery: rewrittenQuery + rewrittenFacetFilters: + - fieldName: fieldName + values: + - fieldValues + - fieldValues + - fieldName: fieldName + values: + - fieldValues + - fieldValues + MessagesResponse: + required: + - hasMore + properties: + hasMore: + type: boolean + description: Whether there are more results for client to continue requesting. + searchResponse: + $ref: "#/components/schemas/SearchResponse" + rootMessage: + $ref: "#/components/schemas/SearchResult" + EditPinRequest: + allOf: + - $ref: "#/components/schemas/PinDocumentMutableProperties" + - type: object + properties: + id: + type: string + description: The opaque id of the pin to be edited. + GetPinRequest: + properties: + id: + type: string + description: The opaque id of the pin to be fetched. + GetPinResponse: + properties: + pin: + $ref: "#/components/schemas/PinDocument" + ListPinsResponse: + required: + - pins + properties: + pins: + type: array + items: + $ref: "#/components/schemas/PinDocument" + description: List of pinned documents. + PinRequest: + allOf: + - $ref: "#/components/schemas/PinDocumentMutableProperties" + - type: object + properties: + documentId: + type: string + description: The document to be pinned. + Unpin: + properties: + id: + type: string + description: The opaque id of the pin to be unpinned. + ResultsRequest: + properties: + timestamp: + type: string + description: The ISO 8601 timestamp associated with the client request. + format: date-time + trackingToken: + type: string + description: A previously received trackingToken for a search associated with the same query. Useful for more requests and requests for other tabs. + sessionInfo: + $ref: "#/components/schemas/SessionInfo" + sourceDocument: + $ref: "#/components/schemas/Document" + description: The document from which the ResultsRequest is issued, if any. + pageSize: + type: integer + example: 100 + description: Hint to the server about how many results to send back. Server may return less or more. Structured results and clustered results don't count towards pageSize. + maxSnippetSize: + type: integer + description: Hint to the server about how many characters long a snippet may be. Server may return less or more. + example: 400 + SearchRequest: + required: + - query + allOf: + - $ref: "#/components/schemas/ResultsRequest" + - type: object + properties: + query: + type: string + description: The search terms. + example: vacation policy + cursor: + type: string + description: Pagination cursor. A previously received opaque token representing the position in the overall results at which to start. + resultTabIds: + type: array + items: + type: string + description: The unique IDs of the result tabs for which to fetch results. This will have precedence over datasource filters if both are specified and in conflict. + inputDetails: + $ref: "#/components/schemas/SearchRequestInputDetails" + requestOptions: + $ref: "#/components/schemas/SearchRequestOptions" + timeoutMillis: + type: integer + description: Timeout in milliseconds for the request. A `408` error will be returned if handling the request takes longer. + example: 5000 + people: + type: array + description: People associated with the search request. Hints to the server to fetch additional information for these people. Note that in this request, an email may be used as a person's obfuscatedId value. + items: + $ref: "#/components/schemas/Person" + disableSpellcheck: + type: boolean + description: Whether or not to disable spellcheck. + example: + trackingToken: trackingToken + query: vacation policy + pageSize: 10 + requestOptions: + facetFilters: + - fieldName: type + values: + - value: article + relationType: EQUALS + - value: document + relationType: EQUALS + - fieldName: department + values: + - value: engineering + relationType: EQUALS + AutocompleteRequest: + type: object + properties: + trackingToken: + type: string + sessionInfo: + $ref: "#/components/schemas/SessionInfo" + query: + type: string + description: Partially typed query. + example: San Fra + datasourcesFilter: + type: array + items: + type: string + description: Filter results to only those relevant to one or more datasources (e.g. jira, gdrive). Results are unfiltered if missing. + datasource: + type: string + description: Filter to only return results relevant to the given datasource. + resultTypes: + type: array + description: Filter to only return results of the given type(s). All types may be returned if omitted. + items: + type: string + enum: + - ADDITIONAL_DOCUMENT + - APP + - BROWSER_HISTORY + - DATASOURCE + - DOCUMENT + - ENTITY + - GOLINK + - HISTORY + - NEW_CHAT + - OPERATOR + - OPERATOR_VALUE + - QUICKLINK + - SUGGESTION + resultSize: + type: integer + description: | + Maximum number of results to be returned. If no value is provided, the backend will cap at 200. + example: 10 + authTokens: + type: array + description: Auth tokens which may be used for federated results. + items: + $ref: "#/components/schemas/AuthToken" + example: + trackingToken: trackingToken + query: what is a que + datasource: GDRIVE + resultSize: 10 + OperatorScope: + properties: + datasource: + type: string + docType: + type: string + OperatorMetadata: + required: + - name + properties: + name: + type: string + isCustom: + type: boolean + description: Whether this operator is supported by default or something that was created within a workplace app (e.g. custom jira field). + operatorType: + type: string + enum: + - TEXT + - DOUBLE + - DATE + - USER + helpText: + type: string + scopes: + type: array + items: + $ref: "#/components/schemas/OperatorScope" + value: + type: string + description: Raw/canonical value of the operator. Only applies when result is an operator value. + displayValue: + type: string + description: Human readable value of the operator that can be shown to the user. Only applies when result is an operator value. + example: + name: Last Updated + operatorType: DATE + scopes: + - datasource: GDRIVE + docType: Document + - datasource: ZENDESK + Quicklink: + description: An action for a specific datasource that will show up in autocomplete and app card, e.g. "Create new issue" for jira. + properties: + name: + type: string + description: Full action name. Used in autocomplete. + shortName: + type: string + description: Shortened name. Used in app cards. + url: + type: string + description: The URL of the action. + iconConfig: + $ref: "#/components/schemas/IconConfig" + description: The config for the icon for this quicklink + id: + type: string + description: Unique identifier of this quicklink + scopes: + type: array + description: The scopes for which this quicklink is applicable + items: + type: string + enum: + - APP_CARD + - AUTOCOMPLETE_EXACT_MATCH + - AUTOCOMPLETE_FUZZY_MATCH + - AUTOCOMPLETE_ZERO_QUERY + - NEW_TAB_PAGE + AutocompleteResult: + required: + - result + - result_type + properties: + result: + type: string + keywords: + type: array + items: + type: string + description: A list of all possible keywords for given result. + resultType: + type: string + enum: + - ADDITIONAL_DOCUMENT + - APP + - BROWSER_HISTORY + - DATASOURCE + - DOCUMENT + - ENTITY + - GOLINK + - HISTORY + - NEW_CHAT + - OPERATOR + - OPERATOR_VALUE + - QUICKLINK + - SUGGESTION + score: + type: number + description: Higher indicates a more confident match. + operatorMetadata: + $ref: "#/components/schemas/OperatorMetadata" + quicklink: + $ref: "#/components/schemas/Quicklink" + document: + $ref: "#/components/schemas/Document" + url: + type: string + structuredResult: + $ref: "#/components/schemas/StructuredResult" + trackingToken: + type: string + description: A token to be passed in /feedback events associated with this autocomplete result. + ranges: + type: array + items: + $ref: "#/components/schemas/TextRange" + description: Subsections of the result string to which some special formatting should be applied (eg. bold) + example: + result: sample result + resultType: DOCUMENT + score: 4.56 + url: https://www.example.com/ + trackingToken: abcd + metadata: + - datasource: confluence + - objectType: page + AutocompleteResultGroup: + description: A subsection of the results list from which distinct sections should be created. + properties: + startIndex: + type: integer + description: The inclusive start index of the range. + endIndex: + type: integer + description: The exclusive end index of the range. + title: + type: string + description: The title of the result group to be displayed. Empty means no title. + AutocompleteResponse: + allOf: + - $ref: "#/components/schemas/BackendExperimentsContext" + - type: object + properties: + trackingToken: + type: string + description: An opaque token that represents this particular set of autocomplete results. To be used for /feedback reporting. + sessionInfo: + $ref: "#/components/schemas/SessionInfo" + results: + type: array + items: + $ref: "#/components/schemas/AutocompleteResult" + groups: + type: array + items: + $ref: "#/components/schemas/AutocompleteResultGroup" + description: Subsections of the results list from which distinct sections should be created. + errorInfo: + $ref: "#/components/schemas/ErrorInfo" + backendTimeMillis: + type: integer + format: int64 + description: Time in milliseconds the backend took to respond to the request. + example: 1100 + example: + trackingToken: trackingToken + ChatZeroStateSuggestionOptions: + properties: + applicationId: + type: string + description: The Chat Application ID this feed request should be scoped to. Empty means there is no Chat Application ID.. + FeedRequestOptions: + required: + - resultSize + properties: + resultSize: + type: integer + description: Number of results asked in response. If a result is a collection, counts as one. + timezoneOffset: + type: integer + description: The offset of the client's timezone in minutes from UTC. e.g. PDT is -420 because it's 7 hours behind UTC. + categoryToResultSize: + type: object + additionalProperties: + type: object + properties: + resultSize: + type: integer + description: Mapping from category to number of results asked for the category. + datasourceFilter: + type: array + items: + type: string + description: Datasources for which content should be included. Empty is for all. + chatZeroStateSuggestionOptions: + $ref: "#/components/schemas/ChatZeroStateSuggestionOptions" + FeedRequest: + required: + - refreshType + properties: + categories: + type: array + items: + type: string + enum: + - DOCUMENT_SUGGESTION + - DOCUMENT_SUGGESTION_SCENARIO + - TRENDING_DOCUMENT + - VERIFICATION_REMINDER + - EVENT + - ANNOUNCEMENT + - MENTION + - DATASOURCE_AFFINITY + - RECENT + - COMPANY_RESOURCE + - EXPERIMENTAL + - PEOPLE_CELEBRATIONS + - DISPLAYABLE_LIST + - SOCIAL_LINK + - EXTERNAL_TASKS + - ZERO_STATE_CHAT_SUGGESTION + - ZERO_STATE_CHAT_TOOL_SUGGESTION + - ZERO_STATE_WORKFLOW_CREATED_BY_ME + - ZERO_STATE_WORKFLOW_FAVORITES + - ZERO_STATE_WORKFLOW_POPULAR + - ZERO_STATE_WORKFLOW_SUGGESTION + description: Categories of content requested. An allowlist gives flexibility to request content separately or together. + requestOptions: + $ref: "#/components/schemas/FeedRequestOptions" + timeoutMillis: + type: integer + description: Timeout in milliseconds for the request. A `408` error will be returned if handling the request takes longer. + example: 5000 + sessionInfo: + $ref: "#/components/schemas/SessionInfo" + DisplayableListFormat: + properties: + format: + type: string + enum: + - LIST + description: defines how to render this particular displayable list card + DisplayableListItemUIConfig: + type: object + description: UI configurations for each item of the list + properties: + showNewIndicator: + type: boolean + description: show a "New" pill next to the item + ConferenceData: + required: + - provider + - uri + properties: + provider: + type: string + enum: + - ZOOM + - HANGOUTS + uri: + type: string + description: A permalink for the conference. + source: + type: string + enum: + - NATIVE_CONFERENCE + - LOCATION + - DESCRIPTION + EventClassificationName: + description: The name for a generated classification of an event. + type: string + enum: + - External Event + EventStrategyName: + type: string + description: The name of method used to surface relevant data for a given calendar event. + enum: + - customerCard + - news + - call + - email + - meetingNotes + - linkedIn + - relevantDocuments + - chatFollowUps + - conversations + EventClassification: + description: A generated classification of a given event. + properties: + name: + $ref: "#/components/schemas/EventClassificationName" + strategies: + type: array + items: + $ref: "#/components/schemas/EventStrategyName" + StructuredLink: + description: The display configuration for a link. + properties: + name: + type: string + description: The display name for the link + url: + type: string + description: The URL for the link. + iconConfig: + $ref: "#/components/schemas/IconConfig" + GeneratedAttachmentContent: + description: Content that has been generated or extrapolated from the documents present in the document field. + properties: + displayHeader: + description: The header describing the generated content. + type: string + text: + description: The content that has been generated. + type: string + example: + displayHeader: Action Items + content: You said you'd send over the design document after the meeting. + GeneratedAttachment: + description: These are attachments that aren't natively present on the event, and have been smartly suggested. + properties: + strategyName: + $ref: "#/components/schemas/EventStrategyName" + documents: + type: array + items: + $ref: "#/components/schemas/Document" + person: + $ref: "#/components/schemas/Person" + customer: + $ref: "#/components/schemas/Customer" + externalLinks: + description: A list of links to external sources outside of Glean. + type: array + items: + $ref: "#/components/schemas/StructuredLink" + content: + type: array + items: + $ref: "#/components/schemas/GeneratedAttachmentContent" + CalendarEvent: + required: + - id + - url + allOf: + - $ref: "#/components/schemas/AnonymousEvent" + - type: object + properties: + id: + type: string + description: The calendar event id + url: + type: string + description: A permalink for this calendar event + attendees: + $ref: "#/components/schemas/CalendarAttendees" + location: + type: string + description: The location that this event is taking place at. + conferenceData: + $ref: "#/components/schemas/ConferenceData" + description: + type: string + description: The HTML description of the event. + datasource: + type: string + description: The app or other repository type from which the event was extracted + hasTranscript: + type: boolean + description: The event has a transcript associated with it enabling features like summarization + transcriptUrl: + type: string + description: A link to the transcript of the event + classifications: + type: array + items: + $ref: "#/components/schemas/EventClassification" + generatedAttachments: + type: array + items: + $ref: "#/components/schemas/GeneratedAttachment" + PromptTemplateMutableProperties: + required: + - template + properties: + name: + type: string + description: The user-given identifier for this prompt template. + template: + type: string + description: The actual template string. + applicationId: + type: string + description: The Application Id the prompt template should be created under. Empty for default assistant. + inclusions: + $ref: "#/components/schemas/ChatRestrictionFilters" + description: A list of filters which only allows the prompt template to access certain content. + addedRoles: + type: array + description: A list of added user roles for the Workflow. + items: + $ref: "#/components/schemas/UserRoleSpecification" + removedRoles: + type: array + description: A list of removed user roles for the Workflow. + items: + $ref: "#/components/schemas/UserRoleSpecification" + AttributionProperties: {} + PromptTemplate: + allOf: + - $ref: "#/components/schemas/PromptTemplateMutableProperties" + - $ref: "#/components/schemas/PermissionedObject" + - $ref: "#/components/schemas/AttributionProperties" + - type: object + properties: + id: + type: string + description: Opaque id for this prompt template + author: + $ref: "#/components/schemas/Person" + createTimestamp: + type: integer + description: Server Unix timestamp of the creation time. + lastUpdateTimestamp: + type: integer + description: Server Unix timestamp of the last update time. + lastUpdatedBy: + $ref: "#/components/schemas/Person" + roles: + type: array + description: A list of roles for this prompt template explicitly granted. + items: + $ref: "#/components/schemas/UserRoleSpecification" + UgcType: + enum: + - ANNOUNCEMENTS_TYPE + - ANSWERS_TYPE + - COLLECTIONS_TYPE + - SHORTCUTS_TYPE + - WORKFLOWS_TYPE + - PROMPT_TEMPLATES_TYPE + FavoriteInfo: + type: object + properties: + ugcType: + $ref: "#/components/schemas/UgcType" + id: + type: string + description: Opaque id of the UGC. + count: + type: integer + x-includeEmpty: true + description: Number of users this object has been favorited by. + favoritedByUser: + type: boolean + x-includeEmpty: true + description: If the requesting user has favorited this object. + PromptTemplateResult: + properties: + promptTemplate: + $ref: "#/components/schemas/PromptTemplate" + trackingToken: + type: string + description: An opaque token that represents this prompt template + favoriteInfo: + $ref: "#/components/schemas/FavoriteInfo" + runCount: + $ref: "#/components/schemas/CountInfo" + description: This tracks how many times this prompt template was run. If user runs a prompt template after modifying the original one, it still counts as a run for the original template. + WorkflowMutableProperties: + properties: + name: + type: string + description: The name of the workflow. + WorkflowMetadata: + allOf: + - type: object + properties: + author: + $ref: "#/components/schemas/Person" + createTimestamp: + type: integer + description: Server Unix timestamp of the creation time. + lastUpdateTimestamp: + type: integer + description: Server Unix timestamp of the last update time. + lastUpdatedBy: + $ref: "#/components/schemas/Person" + Workflow: + allOf: + - $ref: "#/components/schemas/PermissionedObject" + - $ref: "#/components/schemas/WorkflowMutableProperties" + - $ref: "#/components/schemas/WorkflowMetadata" + - $ref: "#/components/schemas/AttributionProperties" + - type: object + properties: + id: + type: string + description: The ID of the workflow. + WorkflowResult: + type: object + required: + - workflow + properties: + workflow: + $ref: "#/components/schemas/Workflow" + UserActivity: + properties: + actor: + $ref: "#/components/schemas/Person" + timestamp: + type: integer + description: Unix timestamp of the activity (in seconds since epoch UTC). + action: + type: string + enum: + - ADD + - ADD_REMINDER + - CLICK + - COMMENT + - DELETE + - DISMISS + - EDIT + - MENTION + - MOVE + - OTHER + - RESTORE + - UNKNOWN + - VERIFY + - VIEW + description: The action for the activity + aggregateVisitCount: + $ref: "#/components/schemas/CountInfo" + FeedEntry: + required: + - title + properties: + entryId: + type: string + description: optional ID associated with a single feed entry (displayable_list_id) + title: + type: string + description: Title for the result. Can be document title, event title and so on. + thumbnail: + $ref: "#/components/schemas/Thumbnail" + createdBy: + $ref: "#/components/schemas/Person" + uiConfig: + allOf: + - $ref: "#/components/schemas/DisplayableListFormat" + - type: object + properties: + additionalFlags: + $ref: "#/components/schemas/DisplayableListItemUIConfig" + justificationType: + type: string + enum: + - FREQUENTLY_ACCESSED + - RECENTLY_ACCESSED + - TRENDING_DOCUMENT + - VERIFICATION_REMINDER + - SUGGESTED_DOCUMENT + - EMPTY_STATE_SUGGESTION + - FRECENCY_SCORED + - SERVER_GENERATED + - USE_CASE + - UPDATE_SINCE_LAST_VIEW + - RECENTLY_STARTED + - EVENT + - USER_MENTION + - ANNOUNCEMENT + - EXTERNAL_ANNOUNCEMENT + - POPULARITY_BASED_TRENDING + - COMPANY_RESOURCE + - EVENT_DOCUMENT_FROM_CONTENT + - EVENT_DOCUMENT_FROM_SEARCH + - VISIT_AFFINITY_SCORED + - SUGGESTED_APP + - SUGGESTED_PERSON + - ACTIVITY_HIGHLIGHT + - SAVED_SEARCH + - SUGGESTED_CHANNEL + - PEOPLE_CELEBRATIONS + - SOCIAL_LINK + - ZERO_STATE_CHAT_SUGGESTION + - ZERO_STATE_CHAT_TOOL_SUGGESTION + - ZERO_STATE_PROMPT_TEMPLATE_SUGGESTION + - ZERO_STATE_STATIC_WORKFLOW_SUGGESTION + - ZERO_STATE_AGENT_SUGGESTION + description: Type of the justification. + justification: + type: string + description: Server side generated justification string if server provides one. + trackingToken: + type: string + description: An opaque token that represents this particular feed entry in this particular response. To be used for /feedback reporting. + viewUrl: + type: string + description: View URL for the entry if based on links that are not documents in Glean. + document: + $ref: "#/components/schemas/Document" + event: + $ref: "#/components/schemas/CalendarEvent" + announcement: + $ref: "#/components/schemas/Announcement" + collection: + $ref: "#/components/schemas/Collection" + collectionItem: + $ref: "#/components/schemas/CollectionItem" + person: + $ref: "#/components/schemas/Person" + app: + $ref: "#/components/schemas/AppResult" + promptTemplate: + $ref: "#/components/schemas/PromptTemplateResult" + workflow: + $ref: "#/components/schemas/WorkflowResult" + activities: + type: array + items: + $ref: "#/components/schemas/UserActivity" + description: List of activity where each activity has user, action, timestamp. + documentVisitorCount: + $ref: "#/components/schemas/CountInfo" + FeedResult: + required: + - category + - primaryEntry + properties: + category: + type: string + enum: + - DOCUMENT_SUGGESTION + - DOCUMENT_SUGGESTION_SCENARIO + - TRENDING_DOCUMENT + - USE_CASE + - VERIFICATION_REMINDER + - EVENT + - ANNOUNCEMENT + - MENTION + - DATASOURCE_AFFINITY + - RECENT + - COMPANY_RESOURCE + - EXPERIMENTAL + - PEOPLE_CELEBRATIONS + - SOCIAL_LINK + - EXTERNAL_TASKS + - DISPLAYABLE_LIST + - ZERO_STATE_CHAT_SUGGESTION + - ZERO_STATE_CHAT_TOOL_SUGGESTION + - ZERO_STATE_WORKFLOW_CREATED_BY_ME + - ZERO_STATE_WORKFLOW_FAVORITES + - ZERO_STATE_WORKFLOW_POPULAR + - ZERO_STATE_WORKFLOW_SUGGESTION + description: Category of the result, one of the requested categories in incoming request. + primaryEntry: + $ref: "#/components/schemas/FeedEntry" + secondaryEntries: + type: array + items: + $ref: "#/components/schemas/FeedEntry" + description: Secondary entries for the result e.g. suggested docs for the calendar, carousel. + rank: + type: integer + description: Rank of the result. Rank is suggested by server. Client side rank may differ. + FeedResponse: + required: + - serverTimestamp + allOf: + - $ref: "#/components/schemas/BackendExperimentsContext" + - type: object + properties: + trackingToken: + type: string + description: An opaque token that represents this particular feed response. + serverTimestamp: + type: integer + description: Server unix timestamp (in seconds since epoch UTC). + results: + type: array + items: + $ref: "#/components/schemas/FeedResult" + facetResults: + type: object + additionalProperties: + type: array + items: + $ref: "#/components/schemas/FacetResult" + description: Map from category to the list of facets that can be used to filter the entry's content. + mentionsTimeWindowInHours: + type: integer + description: The time window (in hours) used for generating user mentions. + RecommendationsRequestOptions: + properties: + datasourceFilter: + type: string + description: Filter results to a single datasource name (e.g. gmail, slack). All results are returned if missing. + datasourcesFilter: + type: array + items: + type: string + description: Filter results to only those relevant to one or more datasources (e.g. jira, gdrive). All results are returned if missing. + facetFilterSets: + type: array + items: + $ref: "#/components/schemas/FacetFilterSet" + description: A list of facet filter sets that will be OR'ed together. + context: + $ref: "#/components/schemas/Document" + description: Content for either a new or unindexed document, or additional content for an indexed document, which may be used to generate recommendations. + resultProminence: + description: The types of prominence wanted in results returned. Default is any type. + type: array + items: + $ref: "#/components/schemas/SearchResultProminenceEnum" + RecommendationsRequest: + allOf: + - $ref: "#/components/schemas/ResultsRequest" + - type: object + properties: + recommendationDocumentSpec: + $ref: "#/components/schemas/DocumentSpec" + description: Retrieve recommendations for this document. Glean Document ID is preferred over URL. + requestOptions: + $ref: "#/components/schemas/RecommendationsRequestOptions" + description: Options for adjusting the request for recommendations. + RecommendationsResponse: + allOf: + - $ref: "#/components/schemas/ResultsResponse" + SortOptions: + type: object + properties: + orderBy: + type: string + enum: + - ASC + - DESC + sortBy: + type: string + ListEntitiesRequest: + type: object + properties: + filter: + type: array + items: + $ref: "#/components/schemas/FacetFilter" + sort: + description: Use EntitiesSortOrder enum for SortOptions.sortBy + type: array + items: + $ref: "#/components/schemas/SortOptions" + entityType: + type: string + default: PEOPLE + enum: + - PEOPLE + - TEAMS + - CUSTOM_ENTITIES + datasource: + type: string + description: The datasource associated with the entity type, most commonly used with CUSTOM_ENTITIES + query: + type: string + description: A query string to search for entities that each entity in the response must conform to. An empty query does not filter any entities. + includeFields: + description: List of entity fields to return (that aren't returned by default) + type: array + items: + type: string + enum: + - PEOPLE + - TEAMS + - PEOPLE_DISTANCE + - PERMISSIONS + - FACETS + - INVITE_INFO + - LAST_EXTENSION_USE + - MANAGEMENT_DETAILS + - UNPROCESSED_TEAMS + pageSize: + type: integer + example: 100 + description: Hint to the server about how many results to send back. Server may return less. + cursor: + type: string + description: Pagination cursor. A previously received opaque token representing the position in the overall results at which to start. + source: + type: string + description: A string denoting the search surface from which the endpoint is called. + EntitiesSortOrder: + type: string + description: Different ways of sorting entities + enum: + - ENTITY_NAME + - FIRST_NAME + - LAST_NAME + - ORG_SIZE_COUNT + - START_DATE + - TEAM_SIZE + - RELEVANCE + ListEntitiesResponse: + type: object + properties: + results: + type: array + items: + $ref: "#/components/schemas/Person" + teamResults: + type: array + items: + $ref: "#/components/schemas/Team" + customEntityResults: + type: array + items: + $ref: "#/components/schemas/CustomEntity" + facetResults: + type: array + items: + $ref: "#/components/schemas/FacetResult" + cursor: + type: string + description: Pagination cursor. A previously received opaque token representing the position in the overall results at which to start. + totalCount: + type: integer + description: The total number of entities available + hasMoreResults: + type: boolean + description: Whether or not more entities can be fetched. + sortOptions: + type: array + description: Sort options from EntitiesSortOrder supported for this response. Default is empty list. + items: + $ref: "#/components/schemas/EntitiesSortOrder" + customFacetNames: + type: array + description: list of Person attributes that are custom setup by deployment + items: + type: string + PeopleRequest: + type: object + properties: + timezoneOffset: + type: integer + description: The offset of the client's timezone in minutes from UTC. e.g. PDT is -420 because it's 7 hours behind UTC. + obfuscatedIds: + type: array + items: + type: string + description: The Person IDs to retrieve. If no IDs are requested, the current user's details are returned. + emailIds: + type: array + items: + type: string + description: The email IDs to retrieve. The result is the deduplicated union of emailIds and obfuscatedIds. + includeFields: + description: List of PersonMetadata fields to return (that aren't returned by default) + type: array + items: + type: string + enum: + - BADGES + - BUSY_EVENTS + - DOCUMENT_ACTIVITY + - INVITE_INFO + - PEOPLE_DISTANCE + - PERMISSIONS + - PEOPLE_DETAILS + - MANAGEMENT_DETAILS + - PEOPLE_PROFILE_SETTINGS + - PEOPLE_WITHOUT_MANAGER + includeTypes: + description: The types of people entities to include in the response in addition to those returned by default. + x-enumDescriptions: + PEOPLE_WITHOUT_MANAGER: Returns all people without a manager apart from the requested IDs. + INVALID_ENTITIES: Includes invalid entities in the response if any of the requested IDs are invalid. + type: array + items: + type: string + enum: + - PEOPLE_WITHOUT_MANAGER + - INVALID_ENTITIES + source: + type: string + description: A string denoting the search surface from which the endpoint is called. + example: + obfuscatedIds: + - abc123 + - abc456 + PeopleResponse: + properties: + results: + type: array + items: + $ref: "#/components/schemas/Person" + description: A Person for each ID in the request, each with PersonMetadata populated. + relatedDocuments: + type: array + items: + $ref: "#/components/schemas/RelatedDocuments" + description: A list of documents related to this people response. This is only included if DOCUMENT_ACTIVITY is requested and only 1 person is included in the request. + errors: + type: array + items: + type: string + description: A list of IDs that could not be found. + CreateShortcutRequest: + required: + - data + properties: + data: + $ref: "#/components/schemas/ShortcutMutableProperties" + ShortcutError: + properties: + errorType: + type: string + enum: + - NO_PERMISSION + - INVALID_ID + - EXISTING_SHORTCUT + - INVALID_CHARS + CreateShortcutResponse: + properties: + shortcut: + $ref: "#/components/schemas/Shortcut" + error: + $ref: "#/components/schemas/ShortcutError" + DeleteShortcutRequest: + allOf: + - $ref: "#/components/schemas/UserGeneratedContentId" + - type: object + required: + - id + GetShortcutRequest: + oneOf: + - $ref: "#/components/schemas/UserGeneratedContentId" + - type: object + required: + - alias + properties: + alias: + type: string + description: The alias for the shortcut, including any arguments for variable shortcuts. + GetShortcutResponse: + properties: + shortcut: + $ref: "#/components/schemas/Shortcut" + description: Shortcut given the input alias with any provided arguments substituted into the destination URL. + error: + $ref: "#/components/schemas/ShortcutError" + ListShortcutsPaginatedRequest: + required: + - pageSize + properties: + includeFields: + description: Array of fields/data to be included in response that are not included by default + type: array + items: + type: string + enum: + - FACETS + - PEOPLE_DETAILS + pageSize: + type: integer + example: 10 + cursor: + type: string + description: A token specifying the position in the overall results to start at. Received from the endpoint and iterated back. Currently being used as page no (as we implement offset pagination) + filters: + type: array + items: + $ref: "#/components/schemas/FacetFilter" + description: A list of filters for the query. An AND is assumed between different filters. We support filters on Go Link name, author, department and type. + sort: + $ref: "#/components/schemas/SortOptions" + description: Specifies fieldname to sort on and order (ASC|DESC) to sort in + query: + type: string + description: Search query that should be a substring in atleast one of the fields (alias , inputAlias, destinationUrl, description). Empty query does not filter shortcuts. + ShortcutsPaginationMetadata: + properties: + cursor: + type: string + description: Cursor indicates the start of the next page of results + hasNextPage: + type: boolean + totalItemCount: + type: integer + ListShortcutsPaginatedResponse: + required: + - shortcuts + - meta + properties: + shortcuts: + type: array + items: + $ref: "#/components/schemas/Shortcut" + description: List of all shortcuts accessible to the user + facetResults: + type: array + items: + $ref: "#/components/schemas/FacetResult" + meta: + $ref: "#/components/schemas/ShortcutsPaginationMetadata" + description: Contains metadata like total item count and whether next page exists + UpdateShortcutRequest: + allOf: + - $ref: "#/components/schemas/UserGeneratedContentId" + - $ref: "#/components/schemas/ShortcutMutableProperties" + - type: object + required: + - id + UpdateShortcutResponse: + properties: + shortcut: + $ref: "#/components/schemas/Shortcut" + error: + $ref: "#/components/schemas/ShortcutError" + SummarizeRequest: + description: Summary of the document + required: + - documentSpecs + properties: + timestamp: + type: string + description: The ISO 8601 timestamp associated with the client request. + format: date-time + query: + type: string + description: Optional query that the summary should be about + preferredSummaryLength: + type: integer + description: Optional length of summary output. If not given, defaults to 500 chars. + documentSpecs: + type: array + items: + $ref: "#/components/schemas/DocumentSpec" + description: Specifications of documents to summarize + trackingToken: + type: string + description: An opaque token that represents this particular result. To be used for /feedback reporting. + Summary: + properties: + text: + type: string + followUpPrompts: + type: array + items: + type: string + description: Follow-up prompts based on the summarized doc + SummarizeResponse: + properties: + error: + type: object + properties: + message: + type: string + summary: + $ref: "#/components/schemas/Summary" + trackingToken: + type: string + description: An opaque token that represents this summary in this particular query. To be used for /feedback reporting. + ReminderRequest: + required: + - documentId + properties: + documentId: + type: string + description: The document which the verification is for new reminders and/or update. + assignee: + type: string + description: The obfuscated id of the person this verification is assigned to. + remindInDays: + type: integer + description: Reminder for the next verifications in terms of days. For deletion, this will be omitted. + reason: + type: string + description: An optional free-text reason for the reminder. This is particularly useful when a reminder is used to ask for verification from another user (for example, "Duplicate", "Incomplete", "Incorrect"). + VerificationFeed: + properties: + documents: + type: array + items: + $ref: "#/components/schemas/Verification" + description: List of document infos that include verification related information for them. + VerifyRequest: + required: + - documentId + properties: + documentId: + type: string + description: The document which is verified. + action: + type: string + enum: + - VERIFY + - DEPRECATE + - UNVERIFY + description: The verification action requested. + ToolParameter: + type: object + properties: + type: + type: string + description: Parameter type (string, number, boolean, object, array) + enum: + - string + - number + - boolean + - object + - array + name: + type: string + description: The name of the parameter + description: + type: string + description: The description of the parameter + isRequired: + type: boolean + description: Whether the parameter is required + possibleValues: + type: array + description: The possible values for the parameter. Can contain only primitive values or arrays of primitive values. + items: + type: string + items: + type: object + description: When type is 'array', this describes the structure of the item in the array. + $ref: "#/components/schemas/ToolParameter" + properties: + type: object + description: When type is 'object', this describes the structure of the object. + additionalProperties: + $ref: "#/components/schemas/ToolParameter" + Tool: + type: object + properties: + type: + type: string + description: Type of tool (READ, WRITE) + enum: + - READ + - WRITE + name: + type: string + description: Unique identifier for the tool + displayName: + type: string + description: Human-readable name + description: + type: string + description: LLM friendly description of the tool + parameters: + type: object + description: The parameters for the tool. Each key is the name of the parameter and the value is the parameter object. + additionalProperties: + $ref: "#/components/schemas/ToolParameter" + ToolsListResponse: + type: object + properties: + tools: + type: array + items: + $ref: "#/components/schemas/Tool" + ToolsCallParameter: + type: object + required: + - name + - value + properties: + name: + type: string + description: The name of the parameter + value: + type: string + description: The value of the parameter (for primitive types) + items: + type: array + description: The value of the parameter (for array types) + items: + $ref: "#/components/schemas/ToolsCallParameter" + properties: + type: object + description: The value of the parameter (for object types) + additionalProperties: + $ref: "#/components/schemas/ToolsCallParameter" + ToolsCallRequest: + type: object + required: + - name + - parameters + properties: + name: + type: string + description: Required name of the tool to execute + parameters: + type: object + description: The parameters for the tool. Each key is the name of the parameter and the value is the parameter object. + additionalProperties: + $ref: "#/components/schemas/ToolsCallParameter" + ToolsCallResponse: + type: object + properties: + rawResponse: + additionalProperties: true + type: object + description: The raw response from the tool + error: + type: string + description: The error message if applicable + SensitiveInfoType: + properties: + likelihoodThreshold: + deprecated: true + type: string + enum: + - LIKELY + - VERY_LIKELY + infoType: + description: Text representation of an info-type to scan for. + type: string + TimeRange: + properties: + startTime: + type: string + description: start time of the time range, applicable for the CUSTOM type. + format: date-time + endTime: + type: string + description: end time of the time range, applicable for the CUSTOM type. + format: date-time + InputOptions: + description: Controls which data-sources and what time-range to include in scans. + properties: + urlGreenlist: + deprecated: true + type: array + description: list of url regex matching documents excluded from report + items: + type: string + datasourcesType: + type: string + description: The types of datasource for which to run the report/policy. + enum: + - ALL + - CUSTOM + datasources: + deprecated: true + type: array + description: List of datasources to consider for report. DEPRECATED - use datasourceInstances instead. + items: + type: string + datasourceInstances: + type: array + description: List of datasource instances to consider for report/policy. + items: + type: string + timePeriodType: + type: string + description: Type of time period for which to run the report/policy. PAST_DAY is deprecated. + enum: + - ALL_TIME + - PAST_YEAR + - PAST_DAY + - CUSTOM + customTimeRange: + $ref: "#/components/schemas/TimeRange" + SharingOptions: + description: Controls how "shared" a document must be to get picked for scans. + properties: + enabled: + deprecated: true + type: boolean + threshold: + description: The minimum number of users the document is shared with. + type: integer + thresholdEnabled: + description: Documents will be filtered based on how many people have access to it. + type: boolean + anyoneWithLinkEnabled: + deprecated: true + type: boolean + anyoneInternalEnabled: + description: Only users within the organization can access the document. + type: boolean + anonymousAccessEnabled: + description: Anyone on the internet can access the document. + type: boolean + userAccessEnabled: + description: Enable user access check + type: boolean + userIds: + type: array + description: Any one of the specified users can access the document. + items: + type: string + ExternalSharingOptions: + deprecated: true + allOf: + - description: DEPRECATED - use `broadSharingOptions` instead. + - $ref: "#/components/schemas/SharingOptions" + - type: object + properties: + domainAccessEnabled: + type: boolean + HotwordProximity: + properties: + windowBefore: + type: integer + windowAfter: + type: integer + Hotword: + properties: + regex: + type: string + proximity: + $ref: "#/components/schemas/HotwordProximity" + SensitiveExpression: + properties: + expression: + description: Sensitive word, phrase, or regular expression. + type: string + hotwords: + description: Zero to three proximate regular expressions necessary to consider an expression as sensitive content. + type: array + items: + $ref: "#/components/schemas/Hotword" + SensitiveContentOptions: + description: Options for defining sensitive content within scanned documents. + properties: + sensitiveInfoTypes: + description: Predefined categories of terms to consider as sensitive content. See https://cloud.google.com/dlp/docs/infotypes-reference for available types. + type: array + items: + $ref: "#/components/schemas/SensitiveInfoType" + sensitiveTerms: + description: list of words and phrases to consider as sensitive content + type: array + items: + $ref: "#/components/schemas/SensitiveExpression" + sensitiveRegexes: + description: list of regular expressions to consider as sensitive content + type: array + items: + $ref: "#/components/schemas/SensitiveExpression" + DlpPersonMetadata: + properties: + firstName: + type: string + description: The first name of the person + email: + type: string + description: The user's primary email address + DlpPerson: + description: Details about the person who created this report/policy. + required: + - name + - obfuscatedId + properties: + name: + type: string + description: The display name. + obfuscatedId: + type: string + description: An opaque identifier that can be used to request metadata for a Person. + metadata: + $ref: "#/components/schemas/DlpPersonMetadata" + AllowlistOptions: + description: Terms that are allow-listed during the scans. If any finding picked up by a rule exactly matches a term in the allow-list, it will not be counted as a violation. + properties: + terms: + type: array + description: list of words and phrases to consider as whitelisted content + items: + type: string + DlpConfig: + description: Detailed configuration of what documents and sensitive content will be scanned. + properties: + version: + description: Synonymous with report/policy id. + type: integer + format: int64 + sensitiveInfoTypes: + deprecated: true + description: DEPRECATED - use `sensitiveContentOptions` instead. + type: array + items: + $ref: "#/components/schemas/SensitiveInfoType" + inputOptions: + description: Options for documents to include or exclude in a report + $ref: "#/components/schemas/InputOptions" + externalSharingOptions: + deprecated: true + description: DEPRECATED - use `broadSharingOptions` instead. + $ref: "#/components/schemas/ExternalSharingOptions" + broadSharingOptions: + description: Options for defining documents to scan for sensitive content. + $ref: "#/components/schemas/SharingOptions" + sensitiveContentOptions: + description: Options for defining sensitive content within scanned documents. + $ref: "#/components/schemas/SensitiveContentOptions" + reportName: + type: string + frequency: + description: Interval between scans. + type: string + createdBy: + description: Person who created this report/policy. + $ref: "#/components/schemas/DlpPerson" + createdAt: + description: Timestamp at which this configuration was created. + type: string + format: iso-date-time + redactQuote: + description: redact quote in findings of the report + type: boolean + autoHideDocs: + description: auto hide documents with findings in the report + type: boolean + allowlistOptions: + description: Options for defining whitelisting content within scanned documents + $ref: "#/components/schemas/AllowlistOptions" + DlpFrequency: + type: string + description: Interval between scans. DAILY is deprecated. + x-include-enum-class-prefix: true + enum: + - ONCE + - DAILY + - WEEKLY + - CONTINUOUS + - NONE + DlpReportStatus: + type: string + description: The status of the policy/report. Only ACTIVE status will be picked for scans. + x-include-enum-class-prefix: true + enum: + - ACTIVE + - INACTIVE + - CANCELLED + - NONE + DlpReport: + description: Full policy information that will be used for scans. + properties: + id: + type: string + name: + type: string + config: + description: All details of the policy that is needed for a scan. + $ref: "#/components/schemas/DlpConfig" + frequency: + description: The interval between scans. + $ref: "#/components/schemas/DlpFrequency" + status: + description: The status of the policy. + $ref: "#/components/schemas/DlpReportStatus" + createdBy: + description: Person who created this report. + $ref: "#/components/schemas/DlpPerson" + createdAt: + description: Timestamp at which the policy was created. + type: string + format: iso-date-time + lastUpdatedAt: + description: Timestamp at which the policy was last updated. + type: string + format: iso-date-time + autoHideDocs: + description: Auto hide documents with findings in the policy. + type: boolean + lastScanStatus: + type: string + enum: + - PENDING + - SUCCESS + - FAILURE + - CANCELLED + - CANCELLING + - ACTIVE + lastScanStartTime: + description: The timestamp at which the report's last run/scan began. + type: string + format: iso-date-time + updatedBy: + description: Person who last updated this report. + $ref: "#/components/schemas/DlpPerson" + GetDlpReportResponse: + properties: + report: + $ref: "#/components/schemas/DlpReport" + UpdateDlpReportRequest: + properties: + config: + description: The new configuration the policy will follow if provided. + $ref: "#/components/schemas/DlpConfig" + frequency: + description: The new frequency the policy will follow if provided. + $ref: "#/components/schemas/DlpFrequency" + status: + description: The new status the policy will be updated to if provided. + $ref: "#/components/schemas/DlpReportStatus" + autoHideDocs: + description: The new autoHideDoc boolean the policy will be updated to if provided. + type: boolean + reportName: + description: The new name of the policy if provided. + type: string + DlpSimpleResult: + type: string + enum: + - SUCCESS + - FAILURE + UpdateDlpReportResponse: + properties: + result: + $ref: "#/components/schemas/DlpSimpleResult" + ListDlpReportsResponse: + properties: + reports: + type: array + items: + $ref: "#/components/schemas/DlpReport" + CreateDlpReportRequest: + properties: + name: + description: Name of the policy being created. + type: string + config: + description: Details on the configuration used in the scans. + $ref: "#/components/schemas/DlpConfig" + frequency: + description: Interval between scans. + $ref: "#/components/schemas/DlpFrequency" + autoHideDocs: + description: Controls whether the policy should hide documents with violations. + type: boolean + CreateDlpReportResponse: + properties: + report: + $ref: "#/components/schemas/DlpReport" + UpdateDlpConfigRequest: + properties: + config: + $ref: "#/components/schemas/DlpConfig" + frequency: + description: Only "ONCE" is supported for reports. + type: string + UpdateDlpConfigResponse: + properties: + result: + $ref: "#/components/schemas/DlpSimpleResult" + reportId: + description: The id of the report that was just created and run. + type: string + ReportStatusResponse: + properties: + status: + type: string + enum: + - PENDING + - SUCCESS + - FAILURE + - CANCELLED + - CANCELLING + - ACTIVE + startTime: + description: The timestamp at which the report's run/scan began. + type: string + format: iso-date-time + DocumentVisibilityOverride: + properties: + docId: + type: string + override: + description: The visibility-override state of the document. + type: string + enum: + - NONE + - HIDE_FROM_ALL + - HIDE_FROM_GROUPS + - HIDE_FROM_ALL_EXCEPT_OWNER + GetDocumentVisibilityOverridesResponse: + properties: + visibilityOverrides: + type: array + items: + $ref: "#/components/schemas/DocumentVisibilityOverride" + UpdateDocumentVisibilityOverridesRequest: + properties: + visibilityOverrides: + type: array + items: + $ref: "#/components/schemas/DocumentVisibilityOverride" + DocumentVisibilityUpdateResult: + allOf: + - $ref: "#/components/schemas/DocumentVisibilityOverride" + - type: object + properties: + success: + description: Whether this document was successfully set to its desired visibility state. + type: boolean + UpdateDocumentVisibilityOverridesResponse: + properties: + results: + description: The documents and whether their visibility was successfully updated. + type: array + items: + $ref: "#/components/schemas/DocumentVisibilityUpdateResult" + ChatRequestStream: + required: + - messages + properties: + saveChat: + type: boolean + description: Save the current interaction as a Chat for the user to access and potentially continue later. + chatId: + type: string + description: The id of the Chat that context should be retrieved from and messages added to. An empty id starts a new Chat, and the Chat is saved if saveChat is true. + messages: + type: array + description: A list of chat messages, from most recent to least recent. It can be assumed that the first chat message in the list is the user's most recent query. + items: + $ref: "#/components/schemas/ChatMessage" + agentConfig: + $ref: "#/components/schemas/AgentConfig" + description: Describes the agent that will execute the request. + inclusions: + $ref: "#/components/schemas/ChatRestrictionFilters" + description: A list of filters which only allows chat to access certain content. + exclusions: + $ref: "#/components/schemas/ChatRestrictionFilters" + description: A list of filters which disallows chat from accessing certain content. If content is in both inclusions and exclusions, it'll be excluded. + timeoutMillis: + type: integer + description: Timeout in milliseconds for the request. A `408` error will be returned if handling the request takes longer. + example: 30000 + applicationId: + type: string + description: The ID of the application this request originates from, used to determine the configuration of underlying chat processes. This should correspond to the ID set during admin setup. If not specified, the default chat experience will be used. + stream: + type: boolean + description: If set, response lines will be streamed one-by-one as they become available. Each will be a ChatResponse, formatted as JSON, and separated by a new line. If false, the entire response will be returned at once. Note that if this is set and the model being used does not support streaming, the model's response will not be streamed, but other messages from the endpoint still will be. + default: true + parameters: + timezoneOffset: + name: timezoneOffset + in: query + description: The offset of the client's timezone in minutes from UTC. e.g. PDT is -420 because it's 7 hours behind UTC. + schema: + type: integer +x-tagGroups: + - name: Search & Generative AI + tags: + - Chat + - Search + - Summarize + - Tools + - name: Connected Content + tags: + - Calendar + - Documents + - Entities + - Messages + - name: User Generated Content + tags: + - Announcements + - Answers + - Collections + - Displayable Lists + - Images + - Pins + - Shortcuts + - Verification + - name: General + tags: + - Activity + - Authentication + - Insights + - User diff --git a/modified_code_samples_specs/indexing.yaml b/modified_code_samples_specs/indexing.yaml new file mode 100644 index 0000000..cfd456f --- /dev/null +++ b/modified_code_samples_specs/indexing.yaml @@ -0,0 +1,5692 @@ +openapi: 3.0.0 +info: + version: 0.9.0 + title: Glean API + contact: + email: support@glean.com + description: | + # Introduction + In addition to the data sources that Glean has built-in support for, Glean also provides a REST API that enables customers to put arbitrary content in the search index. This is useful, for example, for doing permissions-aware search over content in internal tools that reside on-prem as well as for searching over applications that Glean does not currently support first class. In addition these APIs allow the customer to push organization data (people info, organization structure etc) into Glean. + + # Usage guidelines + This API is evolving fast. Glean will provide advance notice of any planned backwards incompatible changes along + with a 6-month sunset period for anything that requires developers to adopt the new versions. + + # API Clients + Official API clients for the Glean Indexing API are available in multiple languages: + + - [Python](https://github.com/gleanwork/api-client-python) + - [TypeScript](https://github.com/gleanwork/api-client-typescript) + - [Go](https://github.com/gleanwork/api-client-go) + - [Java](https://github.com/gleanwork/api-client-java) + + These API clients provide type-safe, idiomatic interfaces for working with Glean IndexingAPIs in your language of choice. + x-logo: + url: https://app.glean.com/images/glean-text2.svg + x-speakeasy-name: Glean API +servers: + - url: https://{instance}-be.glean.com + variables: + instance: + default: instance-name + description: The instance name (typically the email domain without the TLD) that determines the deployment backend. +security: + - APIToken: [] +tags: + - name: Datasources + description: Manage datasources. + - name: Documents + description: Index documents from a datasource. + - name: People + description: Index employee people data. + - name: Permissions + description: Manage users, groups and membership. + - name: Authentication + description: Manage indexing API tokens. +paths: + /api/index/v1/indexdocument: + post: + summary: Index document + description: Adds a document to the index or updates an existing document. + tags: + - Documents + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/IndexDocumentRequest" + required: true + x-exportParamName: IndexDocumentRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + "429": + description: Too Many Requests + x-speakeasy-name-override: addOrUpdate + x-speakeasy-group: indexing.documents + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.documents.add_or_update(document=models.DocumentDefinition( + datasource="", + )) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.documents.addOrUpdate({ + document: { + datasource: "", + }, + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DocumentDefinition; + import com.glean.api_client.glean_api_client.models.components.IndexDocumentRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1IndexdocumentResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + IndexDocumentRequest req = IndexDocumentRequest.builder() + .document(DocumentDefinition.builder() + .datasource("") + .build()) + .build(); + + PostApiIndexV1IndexdocumentResponse res = sdk.indexing().documents().addOrUpdate() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Documents.AddOrUpdate(ctx, components.IndexDocumentRequest{\n Document: components.DocumentDefinition{\n Datasource: \"\",\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/indexdocuments: + post: + summary: Index documents + description: Adds or updates multiple documents in the index. Please refer to the [bulk indexing](https://developers.glean.com/docs/indexing_api_bulk_indexing/#choosing-indexdocuments-vs-bulkindexdocuments) documentation for an explanation of when to use this endpoint. + tags: + - Documents + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/IndexDocumentsRequest" + required: true + x-exportParamName: IndexDocumentsRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + "429": + description: Too Many Requests + x-speakeasy-name-override: index + x-speakeasy-group: indexing.documents + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.documents.index(datasource="", documents=[]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.documents.index({ + datasource: "", + documents: [], + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.IndexDocumentsRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1IndexdocumentsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + IndexDocumentsRequest req = IndexDocumentsRequest.builder() + .datasource("") + .documents(List.of()) + .build(); + + PostApiIndexV1IndexdocumentsResponse res = sdk.indexing().documents().index() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Documents.Index(ctx, components.IndexDocumentsRequest{\n Datasource: \"\",\n Documents: []components.DocumentDefinition{},\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/bulkindexdocuments: + post: + summary: Bulk index documents + description: Replaces the documents in a datasource using paginated batch API calls. Please refer to the [bulk indexing](https://developers.glean.com/docs/indexing_api_bulk_indexing/#bulk-upload-model) documentation for an explanation of how to use bulk endpoints. + tags: + - Documents + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/BulkIndexDocumentsRequest" + required: true + x-exportParamName: BulkIndexDocumentsRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: bulkIndex + x-speakeasy-group: indexing.documents + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.documents.bulk_index(upload_id="", datasource="", documents=[]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.documents.bulkIndex({ + uploadId: "", + datasource: "", + documents: [], + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.BulkIndexDocumentsRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1BulkindexdocumentsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + BulkIndexDocumentsRequest req = BulkIndexDocumentsRequest.builder() + .uploadId("") + .datasource("") + .documents(List.of()) + .build(); + + PostApiIndexV1BulkindexdocumentsResponse res = sdk.indexing().documents().bulkIndex() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Documents.BulkIndex(ctx, components.BulkIndexDocumentsRequest{\n UploadID: \"\",\n Datasource: \"\",\n Documents: []components.DocumentDefinition{},\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/updatepermissions: + post: + summary: Update document permissions + description: Updates the permissions for a given document without modifying document content. + tags: + - Documents + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/UpdatePermissionsRequest" + required: true + x-exportParamName: UpdatePermissionsRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + "429": + description: Too Many Requests + x-speakeasy-name-override: updatePermissions + x-speakeasy-group: indexing.permissions + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.permissions.update_permissions(datasource="", permissions={}) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.permissions.updatePermissions({ + datasource: "", + permissions: {}, + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DocumentPermissionsDefinition; + import com.glean.api_client.glean_api_client.models.components.UpdatePermissionsRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1UpdatepermissionsResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + UpdatePermissionsRequest req = UpdatePermissionsRequest.builder() + .datasource("") + .permissions(DocumentPermissionsDefinition.builder() + .build()) + .build(); + + PostApiIndexV1UpdatepermissionsResponse res = sdk.indexing().permissions().updatePermissions() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Permissions.UpdatePermissions(ctx, components.UpdatePermissionsRequest{\n Datasource: \"\",\n Permissions: components.DocumentPermissionsDefinition{},\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/processalldocuments: + post: + summary: Schedules the processing of uploaded documents + description: | + Schedules the immediate processing of documents uploaded through the indexing API. By default the uploaded documents will be processed asynchronously but this API can be used to schedule processing of all documents on demand. + + If a `datasource` parameter is specified, processing is limited to that custom datasource. Without it, processing applies to all documents across all custom datasources. + #### Rate Limits + This endpoint is rate-limited to one usage every 3 hours. Exceeding this limit results in a 429 response code. Here's how the rate limit works: + 1. Calling `/processalldocuments` for datasource `foo` prevents another call for `foo` for 3 hours. + 2. Calling `/processalldocuments` for datasource `foo` doesn't affect immediate calls for `bar`. + 3. Calling `/processalldocuments` for all datasources prevents any datasource calls for 3 hours. + 4. Calling `/processalldocuments` for datasource `foo` doesn't affect immediate calls for all datasources. + + For more frequent document processing, contact Glean support. + tags: + - Documents + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/ProcessAllDocumentsRequest" + x-exportParamName: ProcessAllDocumentsRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: processAll + x-speakeasy-group: indexing.documents + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.documents.process_all() + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.documents.processAll(); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.ProcessAllDocumentsRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1ProcessalldocumentsResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ProcessAllDocumentsRequest req = ProcessAllDocumentsRequest.builder() + .build(); + + PostApiIndexV1ProcessalldocumentsResponse res = sdk.indexing().documents().processAll() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Documents.ProcessAll(ctx, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/deletedocument: + post: + summary: Delete document + description: Deletes the specified document from the index. Succeeds if document is not present. + tags: + - Documents + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteDocumentRequest" + required: true + x-exportParamName: DeleteDocumentRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: delete + x-speakeasy-group: indexing.documents + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.documents.delete(datasource="", object_type="", id="") + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.documents.delete({ + datasource: "", + objectType: "", + id: "", + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DeleteDocumentRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1DeletedocumentResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeleteDocumentRequest req = DeleteDocumentRequest.builder() + .datasource("") + .objectType("") + .id("") + .build(); + + PostApiIndexV1DeletedocumentResponse res = sdk.indexing().documents().delete() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Documents.Delete(ctx, components.DeleteDocumentRequest{\n Datasource: \"\",\n ObjectType: \"\",\n ID: \"\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/indexuser: + post: + summary: Index user + description: Adds a datasource user or updates an existing user. + tags: + - Permissions + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/IndexUserRequest" + required: true + x-exportParamName: IndexUserRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: indexUser + x-speakeasy-group: indexing.permissions + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.permissions.index_user(datasource="", user={ + "email": "Art.Schaden@hotmail.com", + "name": "", + }) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.permissions.indexUser({ + datasource: "", + user: { + email: "Art.Schaden@hotmail.com", + name: "", + }, + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DatasourceUserDefinition; + import com.glean.api_client.glean_api_client.models.components.IndexUserRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1IndexuserResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + IndexUserRequest req = IndexUserRequest.builder() + .datasource("") + .user(DatasourceUserDefinition.builder() + .email("Art.Schaden@hotmail.com") + .name("") + .build()) + .build(); + + PostApiIndexV1IndexuserResponse res = sdk.indexing().permissions().indexUser() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Permissions.IndexUser(ctx, components.IndexUserRequest{\n Datasource: \"\",\n User: components.DatasourceUserDefinition{\n Email: \"Art.Schaden@hotmail.com\",\n Name: \"\",\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/bulkindexusers: + post: + summary: Bulk index users + description: Replaces the users in a datasource using paginated batch API calls. Please refer to the [bulk indexing](https://developers.glean.com/docs/indexing_api_bulk_indexing/#bulk-upload-model) documentation for an explanation of how to use bulk endpoints. + tags: + - Permissions + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/BulkIndexUsersRequest" + required: true + x-exportParamName: BulkIndexUsersRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: bulkIndexUsers + x-speakeasy-group: indexing.permissions + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.permissions.bulk_index_users(upload_id="", datasource="", users=[ + { + "email": "Ivory_Cummerata@hotmail.com", + "name": "", + }, + { + "email": "Ivory_Cummerata@hotmail.com", + "name": "", + }, + { + "email": "Ivory_Cummerata@hotmail.com", + "name": "", + }, + ]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.permissions.bulkIndexUsers({ + uploadId: "", + datasource: "", + users: [ + { + email: "Ivory_Cummerata@hotmail.com", + name: "", + }, + { + email: "Ivory_Cummerata@hotmail.com", + name: "", + }, + { + email: "Ivory_Cummerata@hotmail.com", + name: "", + }, + ], + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.BulkIndexUsersRequest; + import com.glean.api_client.glean_api_client.models.components.DatasourceUserDefinition; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1BulkindexusersResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + BulkIndexUsersRequest req = BulkIndexUsersRequest.builder() + .uploadId("") + .datasource("") + .users(List.of( + DatasourceUserDefinition.builder() + .email("Ivory_Cummerata@hotmail.com") + .name("") + .build(), + DatasourceUserDefinition.builder() + .email("Ivory_Cummerata@hotmail.com") + .name("") + .build(), + DatasourceUserDefinition.builder() + .email("Ivory_Cummerata@hotmail.com") + .name("") + .build())) + .build(); + + PostApiIndexV1BulkindexusersResponse res = sdk.indexing().permissions().bulkIndexUsers() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Permissions.BulkIndexUsers(ctx, components.BulkIndexUsersRequest{\n UploadID: \"\",\n Datasource: \"\",\n Users: []components.DatasourceUserDefinition{\n components.DatasourceUserDefinition{\n Email: \"Ivory_Cummerata@hotmail.com\",\n Name: \"\",\n },\n components.DatasourceUserDefinition{\n Email: \"Ivory_Cummerata@hotmail.com\",\n Name: \"\",\n },\n components.DatasourceUserDefinition{\n Email: \"Ivory_Cummerata@hotmail.com\",\n Name: \"\",\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/indexgroup: + post: + summary: Index group + description: Add or update a group in the datasource. + tags: + - Permissions + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/IndexGroupRequest" + required: true + x-exportParamName: IndexGroupRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: indexGroup + x-speakeasy-group: indexing.permissions + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.permissions.index_group(datasource="", group={ + "name": "", + }) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.permissions.indexGroup({ + datasource: "", + group: { + name: "", + }, + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DatasourceGroupDefinition; + import com.glean.api_client.glean_api_client.models.components.IndexGroupRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1IndexgroupResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + IndexGroupRequest req = IndexGroupRequest.builder() + .datasource("") + .group(DatasourceGroupDefinition.builder() + .name("") + .build()) + .build(); + + PostApiIndexV1IndexgroupResponse res = sdk.indexing().permissions().indexGroup() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Permissions.IndexGroup(ctx, components.IndexGroupRequest{\n Datasource: \"\",\n Group: components.DatasourceGroupDefinition{\n Name: \"\",\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/bulkindexgroups: + post: + summary: Bulk index groups + description: Replaces the groups in a datasource using paginated batch API calls. Please refer to the [bulk indexing](https://developers.glean.com/docs/indexing_api_bulk_indexing/#bulk-upload-model) documentation for an explanation of how to use bulk endpoints. + tags: + - Permissions + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/BulkIndexGroupsRequest" + required: true + x-exportParamName: BulkIndexGroupsRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: bulkIndexGroups + x-speakeasy-group: indexing.permissions + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.permissions.bulk_index_groups(upload_id="", datasource="", groups=[ + { + "name": "", + }, + { + "name": "", + }, + ]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.permissions.bulkIndexGroups({ + uploadId: "", + datasource: "", + groups: [ + { + name: "", + }, + { + name: "", + }, + ], + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.BulkIndexGroupsRequest; + import com.glean.api_client.glean_api_client.models.components.DatasourceGroupDefinition; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1BulkindexgroupsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + BulkIndexGroupsRequest req = BulkIndexGroupsRequest.builder() + .uploadId("") + .datasource("") + .groups(List.of( + DatasourceGroupDefinition.builder() + .name("") + .build(), + DatasourceGroupDefinition.builder() + .name("") + .build())) + .build(); + + PostApiIndexV1BulkindexgroupsResponse res = sdk.indexing().permissions().bulkIndexGroups() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Permissions.BulkIndexGroups(ctx, components.BulkIndexGroupsRequest{\n UploadID: \"\",\n Datasource: \"\",\n Groups: []components.DatasourceGroupDefinition{\n components.DatasourceGroupDefinition{\n Name: \"\",\n },\n components.DatasourceGroupDefinition{\n Name: \"\",\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/indexmembership: + post: + summary: Index membership + description: Add the memberships of a group in the datasource. + tags: + - Permissions + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/IndexMembershipRequest" + required: true + x-exportParamName: IndexMembershipRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: indexMembership + x-speakeasy-group: indexing.permissions + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.permissions.index_membership(datasource="", membership={ + "group_name": "", + }) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.permissions.indexMembership({ + datasource: "", + membership: { + groupName: "", + }, + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DatasourceMembershipDefinition; + import com.glean.api_client.glean_api_client.models.components.IndexMembershipRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1IndexmembershipResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + IndexMembershipRequest req = IndexMembershipRequest.builder() + .datasource("") + .membership(DatasourceMembershipDefinition.builder() + .groupName("") + .build()) + .build(); + + PostApiIndexV1IndexmembershipResponse res = sdk.indexing().permissions().indexMembership() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Permissions.IndexMembership(ctx, components.IndexMembershipRequest{\n Datasource: \"\",\n Membership: components.DatasourceMembershipDefinition{\n GroupName: \"\",\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/bulkindexmemberships: + post: + summary: Bulk index memberships for a group + description: Replaces the memberships for a group in a datasource using paginated batch API calls. Please refer to the [bulk indexing](https://developers.glean.com/docs/indexing_api_bulk_indexing/#bulk-upload-model) documentation for an explanation of how to use bulk endpoints. + tags: + - Permissions + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/BulkIndexMembershipsRequest" + required: true + x-exportParamName: BulkIndexMembershipsRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: bulkIndexMemberships + x-speakeasy-group: indexing.permissions + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.permissions.bulk_index_memberships(upload_id="", datasource="", memberships=[ + {}, + {}, + {}, + ]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.permissions.bulkIndexMemberships({ + uploadId: "", + datasource: "", + memberships: [ + {}, + {}, + {}, + ], + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.BulkIndexMembershipsRequest; + import com.glean.api_client.glean_api_client.models.components.DatasourceBulkMembershipDefinition; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1BulkindexmembershipsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + BulkIndexMembershipsRequest req = BulkIndexMembershipsRequest.builder() + .uploadId("") + .datasource("") + .memberships(List.of( + DatasourceBulkMembershipDefinition.builder() + .build(), + DatasourceBulkMembershipDefinition.builder() + .build(), + DatasourceBulkMembershipDefinition.builder() + .build())) + .build(); + + PostApiIndexV1BulkindexmembershipsResponse res = sdk.indexing().permissions().bulkIndexMemberships() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Permissions.BulkIndexMemberships(ctx, components.BulkIndexMembershipsRequest{\n UploadID: \"\",\n Datasource: \"\",\n Memberships: []components.DatasourceBulkMembershipDefinition{\n components.DatasourceBulkMembershipDefinition{},\n components.DatasourceBulkMembershipDefinition{},\n components.DatasourceBulkMembershipDefinition{},\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/processallmemberships: + post: + summary: Schedules the processing of group memberships + description: | + Schedules the immediate processing of all group memberships uploaded through the indexing API. By default the uploaded group memberships will be processed asynchronously but this API can be used to schedule processing of all memberships on demand. + tags: + - Permissions + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/ProcessAllMembershipsRequest" + x-exportParamName: ProcessAllMembershipsRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + x-speakeasy-name-override: processMemberships + x-speakeasy-group: indexing.permissions + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.permissions.process_memberships() + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.permissions.processMemberships(); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.ProcessAllMembershipsRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1ProcessallmembershipsResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + ProcessAllMembershipsRequest req = ProcessAllMembershipsRequest.builder() + .build(); + + PostApiIndexV1ProcessallmembershipsResponse res = sdk.indexing().permissions().processMemberships() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Permissions.ProcessMemberships(ctx, nil)\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/deleteuser: + post: + summary: Delete user + description: Delete the user from the datasource. Silently succeeds if user is not present. + tags: + - Permissions + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteUserRequest" + required: true + x-exportParamName: DeleteUserRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: deleteUser + x-speakeasy-group: indexing.permissions + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.permissions.delete_user(datasource="", email="Ed.Johnston@gmail.com") + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.permissions.deleteUser({ + datasource: "", + email: "Ed.Johnston@gmail.com", + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DeleteUserRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1DeleteuserResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeleteUserRequest req = DeleteUserRequest.builder() + .datasource("") + .email("Ed.Johnston@gmail.com") + .build(); + + PostApiIndexV1DeleteuserResponse res = sdk.indexing().permissions().deleteUser() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Permissions.DeleteUser(ctx, components.DeleteUserRequest{\n Datasource: \"\",\n Email: \"Ed.Johnston@gmail.com\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/deletegroup: + post: + summary: Delete group + description: Delete group from the datasource. Silently succeeds if group is not present. + tags: + - Permissions + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteGroupRequest" + required: true + x-exportParamName: DeleteGroupRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: deleteGroup + x-speakeasy-group: indexing.permissions + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.permissions.delete_group(datasource="", group_name="") + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.permissions.deleteGroup({ + datasource: "", + groupName: "", + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DeleteGroupRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1DeletegroupResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeleteGroupRequest req = DeleteGroupRequest.builder() + .datasource("") + .groupName("") + .build(); + + PostApiIndexV1DeletegroupResponse res = sdk.indexing().permissions().deleteGroup() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Permissions.DeleteGroup(ctx, components.DeleteGroupRequest{\n Datasource: \"\",\n GroupName: \"\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/deletemembership: + post: + summary: Delete membership + description: Delete membership to a group in the specified datasource. Silently succeeds if membership is not present. + tags: + - Permissions + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/DeleteMembershipRequest" + required: true + x-exportParamName: DeleteMembershipRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: deleteMembership + x-speakeasy-group: indexing.permissions + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.permissions.delete_membership(datasource="", membership={ + "group_name": "", + }) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.permissions.deleteMembership({ + datasource: "", + membership: { + groupName: "", + }, + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DatasourceMembershipDefinition; + import com.glean.api_client.glean_api_client.models.components.DeleteMembershipRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1DeletemembershipResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeleteMembershipRequest req = DeleteMembershipRequest.builder() + .datasource("") + .membership(DatasourceMembershipDefinition.builder() + .groupName("") + .build()) + .build(); + + PostApiIndexV1DeletemembershipResponse res = sdk.indexing().permissions().deleteMembership() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Permissions.DeleteMembership(ctx, components.DeleteMembershipRequest{\n Datasource: \"\",\n Membership: components.DatasourceMembershipDefinition{\n GroupName: \"\",\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/debug/{datasource}/status: + post: + x-beta: true + summary: | + Beta: Get datasource status + description: | + Gather information about the datasource's overall status. Currently in beta, might undergo breaking changes without prior notice. + + Tip: Refer to the [Troubleshooting tutorial](https://developers.glean.com/docs/indexing_api/indexing_api_troubleshooting/) for more information. + tags: + - Troubleshooting + parameters: + - name: datasource + in: path + description: The datasource to get debug status for. + required: true + schema: + type: string + responses: + "200": + description: OK + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/DebugDatasourceStatusResponse" + "400": + description: Bad Request + "401": + description: Not Authorized + x-speakeasy-name-override: status + x-speakeasy-group: indexing.datasource + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.indexing.datasource.status(datasource="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.indexing.datasource.status(""); + + // Handle the result + console.log(result); + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1DebugDatasourceStatusResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + PostApiIndexV1DebugDatasourceStatusResponse res = sdk.indexing().datasource().status() + .datasource("") + .call(); + + if (res.debugDatasourceStatusResponse().isPresent()) { + // handle response + } + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Datasource.Status(ctx, \"\")\n if err != nil {\n log.Fatal(err)\n }\n if res.DebugDatasourceStatusResponse != nil {\n // handle response\n }\n}" + /api/index/v1/debug/{datasource}/document: + post: + x-beta: true + summary: | + Beta: Get document information + description: | + Gives various information that would help in debugging related to a particular document. Currently in beta, might undergo breaking changes without prior notice. + + Tip: Refer to the [Troubleshooting tutorial](https://developers.glean.com/docs/indexing_api/indexing_api_troubleshooting/) for more information. + tags: + - Troubleshooting + parameters: + - name: datasource + in: path + description: The datasource to which the document belongs + required: true + schema: + type: string + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/DebugDocumentRequest" + required: true + x-exportParamName: DebugDocumentRequest + responses: + "200": + description: OK + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/DebugDocumentResponse" + "400": + description: Bad Request + "401": + description: Not Authorized + x-speakeasy-group: indexing.documents + x-speakeasy-name-override: debug + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.indexing.documents.debug(datasource="", object_type="Article", doc_id="art123") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.indexing.documents.debug({ + objectType: "Article", + docId: "art123", + }, ""); + + // Handle the result + console.log(result); + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DebugDocumentRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1DebugDatasourceDocumentResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + PostApiIndexV1DebugDatasourceDocumentResponse res = sdk.indexing().documents().debug() + .datasource("") + .debugDocumentRequest(DebugDocumentRequest.builder() + .objectType("Article") + .docId("art123") + .build()) + .call(); + + if (res.debugDocumentResponse().isPresent()) { + // handle response + } + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Documents.Debug(ctx, \"\", components.DebugDocumentRequest{\n ObjectType: \"Article\",\n DocID: \"art123\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.DebugDocumentResponse != nil {\n // handle response\n }\n}" + /api/index/v1/debug/{datasource}/documents: + post: + x-beta: true + summary: | + Beta: Get information of a batch of documents + description: | + Gives various information that would help in debugging related to a batch of documents. Currently in beta, might undergo breaking changes without prior notice. + + Tip: Refer to the [Troubleshooting tutorial](https://developers.glean.com/docs/indexing_api/indexing_api_troubleshooting/) for more information. + tags: + - Troubleshooting + parameters: + - name: datasource + in: path + description: The datasource to which the document belongs + required: true + schema: + type: string + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/DebugDocumentsRequest" + required: true + x-exportParamName: DebugDocumentsRequest + responses: + "200": + description: OK + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/DebugDocumentsResponse" + "400": + description: Bad Request + "401": + description: Not Authorized + x-speakeasy-group: indexing.documents + x-speakeasy-name-override: debugMany + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.indexing.documents.debug_many(datasource="", debug_documents=[ + { + "object_type": "Article", + "doc_id": "art123", + }, + ]) + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.indexing.documents.debugMany({ + debugDocuments: [ + { + objectType: "Article", + docId: "art123", + }, + ], + }, ""); + + // Handle the result + console.log(result); + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DebugDocumentRequest; + import com.glean.api_client.glean_api_client.models.components.DebugDocumentsRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1DebugDatasourceDocumentsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + PostApiIndexV1DebugDatasourceDocumentsResponse res = sdk.indexing().documents().debugMany() + .datasource("") + .debugDocumentsRequest(DebugDocumentsRequest.builder() + .debugDocuments(List.of( + DebugDocumentRequest.builder() + .objectType("Article") + .docId("art123") + .build())) + .build()) + .call(); + + if (res.debugDocumentsResponse().isPresent()) { + // handle response + } + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Documents.DebugMany(ctx, \"\", components.DebugDocumentsRequest{\n DebugDocuments: []components.DebugDocumentRequest{\n components.DebugDocumentRequest{\n ObjectType: \"Article\",\n DocID: \"art123\",\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.DebugDocumentsResponse != nil {\n // handle response\n }\n}" + /api/index/v1/debug/{datasource}/user: + post: + x-beta: true + summary: | + Beta: Get user information + description: | + Gives various information that would help in debugging related to a particular user. Currently in beta, might undergo breaking changes without prior notice. + + Tip: Refer to the [Troubleshooting tutorial](https://developers.glean.com/docs/indexing_api/indexing_api_troubleshooting/) for more information. + tags: + - Troubleshooting + parameters: + - name: datasource + in: path + description: The datasource to which the user belongs + required: true + schema: + type: string + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/DebugUserRequest" + required: true + x-exportParamName: DebugUserRequest + responses: + "200": + description: OK + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/DebugUserResponse" + "400": + description: Bad Request + "401": + description: Not Authorized + x-speakeasy-name-override: debug + x-speakeasy-group: indexing.people + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.indexing.people.debug(datasource="", email="u1@foo.com") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.indexing.people.debug({ + email: "u1@foo.com", + }, ""); + + // Handle the result + console.log(result); + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DebugUserRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1DebugDatasourceUserResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + PostApiIndexV1DebugDatasourceUserResponse res = sdk.indexing().people().debug() + .datasource("") + .debugUserRequest(DebugUserRequest.builder() + .email("u1@foo.com") + .build()) + .call(); + + if (res.debugUserResponse().isPresent()) { + // handle response + } + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.People.Debug(ctx, \"\", components.DebugUserRequest{\n Email: \"u1@foo.com\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.DebugUserResponse != nil {\n // handle response\n }\n}" + /api/index/v1/checkdocumentaccess: + post: + summary: Check document access + description: | + Check if a given user has access to access a document in a custom datasource + + Tip: Refer to the [Troubleshooting tutorial](https://developers.glean.com/docs/indexing_api/indexing_api_troubleshooting/) for more information. + tags: + - Troubleshooting + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CheckDocumentAccessRequest" + required: true + x-exportParamName: CheckDocumentAccessRequest + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/CheckDocumentAccessResponse" + "400": + description: Bad Request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-group: indexing.documents + x-speakeasy-name-override: checkAccess + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.indexing.documents.check_access(datasource="", object_type="", doc_id="", user_email="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.indexing.documents.checkAccess({ + datasource: "", + objectType: "", + docId: "", + userEmail: "", + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.CheckDocumentAccessRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1CheckdocumentaccessResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + CheckDocumentAccessRequest req = CheckDocumentAccessRequest.builder() + .datasource("") + .objectType("") + .docId("") + .userEmail("") + .build(); + + PostApiIndexV1CheckdocumentaccessResponse res = sdk.indexing().documents().checkAccess() + .request(req) + .call(); + + if (res.checkDocumentAccessResponse().isPresent()) { + // handle response + } + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Documents.CheckAccess(ctx, components.CheckDocumentAccessRequest{\n Datasource: \"\",\n ObjectType: \"\",\n DocID: \"\",\n UserEmail: \"\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.CheckDocumentAccessResponse != nil {\n // handle response\n }\n}" + /api/index/v1/getdocumentstatus: + post: + deprecated: true + summary: Get document upload and indexing status + description: | + Intended for debugging/validation. Fetches the current upload and indexing status of documents. + + Tip: Use [/debug/{datasource}/document](https://developers.glean.com/docs/indexing_api/indexing_api_troubleshooting/#debug-datasource-document) for richer information. + tags: + - Troubleshooting + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetDocumentStatusRequest" + required: true + x-exportParamName: GetDocumentStatusRequest + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetDocumentStatusResponse" + "400": + description: Bad Request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-group: indexing.documents + x-speakeasy-name-override: status + /api/index/v1/getdocumentcount: + post: + deprecated: true + summary: Get document count + description: | + Fetches document count for the specified custom datasource. + + Tip: Use [/debug/{datasource}/status](https://developers.glean.com/docs/indexing_api/indexing_api_troubleshooting/#debug-datasource-status) for richer information. + tags: + - Troubleshooting + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetDocumentCountRequest" + required: true + x-exportParamName: GetDocumentCountRequest + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetDocumentCountResponse" + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-group: indexing.documents + x-speakeasy-name-override: count + /api/index/v1/getusercount: + post: + deprecated: true + summary: Get user count + description: | + Fetches user count for the specified custom datasource. + + Tip: Use [/debug/{datasource}/status](https://developers.glean.com/docs/indexing_api/indexing_api_troubleshooting/#debug-datasource-status) for richer information. + tags: + - Troubleshooting + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetUserCountRequest" + required: true + x-exportParamName: GetUserCountRequest + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/GetUserCountResponse" + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: count + x-speakeasy-group: indexing.people + /api/index/v1/betausers: + post: + summary: Beta users + description: Allow the datasource be visible to the specified beta users. The default behaviour is datasource being visible to all users if it is enabled and not visible to any user if it is not enabled. + tags: + - Permissions + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GreenlistUsersRequest" + required: true + x-exportParamName: GreenlistUsersRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: authorizeBetaUsers + x-speakeasy-group: indexing.permissions + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.permissions.authorize_beta_users(datasource="", emails=[ + "Neil92@gmail.com", + "Alejandrin_Boyer4@hotmail.com", + "Shyanne_McLaughlin95@hotmail.com", + ]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.permissions.authorizeBetaUsers({ + datasource: "", + emails: [ + "Neil92@gmail.com", + "Alejandrin_Boyer4@hotmail.com", + "Shyanne_McLaughlin95@hotmail.com", + ], + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.GreenlistUsersRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1BetausersResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GreenlistUsersRequest req = GreenlistUsersRequest.builder() + .datasource("") + .emails(List.of( + "Neil92@gmail.com", + "Alejandrin_Boyer4@hotmail.com", + "Shyanne_McLaughlin95@hotmail.com")) + .build(); + + PostApiIndexV1BetausersResponse res = sdk.indexing().permissions().authorizeBetaUsers() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Permissions.AuthorizeBetaUsers(ctx, components.GreenlistUsersRequest{\n Datasource: \"\",\n Emails: []string{\n \"Neil92@gmail.com\",\n \"Alejandrin_Boyer4@hotmail.com\",\n \"Shyanne_McLaughlin95@hotmail.com\",\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/adddatasource: + post: + summary: Add or update datasource + description: Add or update a custom datasource and its schema. + tags: + - Datasources + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/CustomDatasourceConfig" + required: true + x-exportParamName: DatasourceConfig + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + x-speakeasy-name-override: add + x-speakeasy-group: indexing.datasources + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean, models + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.datasources.add(name="", url_regex="https://example-company.datasource.com/.*", quicklinks=[ + { + "icon_config": { + "color": "#343CED", + "key": "person_icon", + "icon_type": models.IconType.GLYPH, + "name": "user", + }, + }, + ]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.datasources.add({ + name: "", + urlRegex: "https://example-company.datasource.com/.*", + quicklinks: [ + { + iconConfig: { + color: "#343CED", + key: "person_icon", + iconType: "GLYPH", + name: "user", + }, + }, + ], + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1AdddatasourceResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + CustomDatasourceConfig req = CustomDatasourceConfig.builder() + .name("") + .urlRegex("https://example-company.datasource.com/.*") + .quicklinks(List.of( + Quicklink.builder() + .iconConfig(IconConfig.builder() + .color("#343CED") + .key("person_icon") + .iconType(IconType.GLYPH) + .name("user") + .build()) + .build())) + .build(); + + PostApiIndexV1AdddatasourceResponse res = sdk.indexing().datasources().add() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Datasources.Add(ctx, components.CustomDatasourceConfig{\n Name: \"\",\n URLRegex: apiclientgo.String(\"https://example-company.datasource.com/.*\"),\n Quicklinks: []components.Quicklink{\n components.Quicklink{\n IconConfig: &components.IconConfig{\n Color: apiclientgo.String(\"#343CED\"),\n Key: apiclientgo.String(\"person_icon\"),\n IconType: components.IconTypeGlyph.ToPointer(),\n Name: apiclientgo.String(\"user\"),\n },\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/getdatasourceconfig: + post: + summary: Get datasource config + description: Fetches the datasource config for the specified custom datasource. + tags: + - Datasources + requestBody: + content: + application/json: + schema: + $ref: "#/components/schemas/GetDatasourceConfigRequest" + required: true + x-exportParamName: GetDatasourceConfigRequest + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/CustomDatasourceConfig" + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: retrieveConfig + x-speakeasy-group: indexing.datasources + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.indexing.datasources.retrieve_config(datasource="") + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.indexing.datasources.retrieveConfig({ + datasource: "", + }); + + // Handle the result + console.log(result); + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.GetDatasourceConfigRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1GetdatasourceconfigResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + GetDatasourceConfigRequest req = GetDatasourceConfigRequest.builder() + .datasource("") + .build(); + + PostApiIndexV1GetdatasourceconfigResponse res = sdk.indexing().datasources().retrieveConfig() + .request(req) + .call(); + + if (res.customDatasourceConfig().isPresent()) { + // handle response + } + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Datasources.RetrieveConfig(ctx, components.GetDatasourceConfigRequest{\n Datasource: \"\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res.CustomDatasourceConfig != nil {\n // handle response\n }\n}" + /api/index/v1/rotatetoken: + post: + summary: Rotate token + description: Rotates the secret value inside the Indexing API token and returns the new raw secret. All other properties of the token are unchanged. In order to rotate the secret value, include the token as the bearer token in the `/rotatetoken` request. Please refer to [Token rotation](https://developers.glean.com/docs/indexing_api_token_rotation/) documentation for more information. + tags: + - Authentication + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: "#/components/schemas/RotateTokenResponse" + "400": + description: Bad Request + "401": + description: Not Authorized + x-speakeasy-name-override: rotateToken + x-speakeasy-group: indexing.authentication + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + res = g_client.indexing.authentication.rotate_token() + + # Handle response + print(res) + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + const result = await glean.indexing.authentication.rotateToken(); + + // Handle the result + console.log(result); + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1RotatetokenResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + PostApiIndexV1RotatetokenResponse res = sdk.indexing().authentication().rotateToken() + .call(); + + if (res.rotateTokenResponse().isPresent()) { + // handle response + } + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Authentication.RotateToken(ctx)\n if err != nil {\n log.Fatal(err)\n }\n if res.RotateTokenResponse != nil {\n // handle response\n }\n}" + /api/index/v1/indexemployee: + post: + summary: Index employee + description: Adds an employee or updates information about an employee + tags: + - People + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/IndexEmployeeRequest" + required: true + x-exportParamName: IndexEmployeeRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: index + x-speakeasy-group: indexing.people + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.people.index(employee={ + "email": "Jerrold_Hermann@hotmail.com", + "department": "", + "datasource_profiles": [ + { + "datasource": "github", + "handle": "", + }, + ], + }) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.people.index({ + employee: { + email: "Jerrold_Hermann@hotmail.com", + department: "", + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + ], + }, + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1IndexemployeeResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + IndexEmployeeRequest req = IndexEmployeeRequest.builder() + .employee(EmployeeInfoDefinition.builder() + .email("Jerrold_Hermann@hotmail.com") + .department("") + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build()) + .build(); + + PostApiIndexV1IndexemployeeResponse res = sdk.indexing().people().index() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.People.Index(ctx, components.IndexEmployeeRequest{\n Employee: components.EmployeeInfoDefinition{\n Email: \"Jerrold_Hermann@hotmail.com\",\n Department: \"\",\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/bulkindexemployees: + post: + summary: Bulk index employees + description: Replaces all the currently indexed employees using paginated batch API calls. Please refer to the [bulk indexing](https://developers.glean.com/docs/indexing_api_bulk_indexing/#bulk-upload-model) documentation for an explanation of how to use bulk endpoints. + tags: + - People + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/BulkIndexEmployeesRequest" + required: true + x-exportParamName: BulkIndexEmployeesRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: bulkIndex + x-speakeasy-group: indexing.people + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.people.bulk_index(upload_id="", employees=[ + { + "email": "Robin.Stoltenberg@yahoo.com", + "department": "", + "datasource_profiles": [ + { + "datasource": "github", + "handle": "", + }, + ], + }, + { + "email": "Robin.Stoltenberg@yahoo.com", + "department": "", + "datasource_profiles": [ + { + "datasource": "github", + "handle": "", + }, + ], + }, + { + "email": "Robin.Stoltenberg@yahoo.com", + "department": "", + "datasource_profiles": [ + { + "datasource": "github", + "handle": "", + }, + ], + }, + ]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.people.bulkIndex({ + uploadId: "", + employees: [ + { + email: "Robin.Stoltenberg@yahoo.com", + department: "", + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + ], + }, + { + email: "Robin.Stoltenberg@yahoo.com", + department: "", + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + ], + }, + { + email: "Robin.Stoltenberg@yahoo.com", + department: "", + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + ], + }, + ], + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1BulkindexemployeesResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + BulkIndexEmployeesRequest req = BulkIndexEmployeesRequest.builder() + .uploadId("") + .employees(List.of( + EmployeeInfoDefinition.builder() + .email("Robin.Stoltenberg@yahoo.com") + .department("") + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build(), + EmployeeInfoDefinition.builder() + .email("Robin.Stoltenberg@yahoo.com") + .department("") + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build(), + EmployeeInfoDefinition.builder() + .email("Robin.Stoltenberg@yahoo.com") + .department("") + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build())) + .build(); + + PostApiIndexV1BulkindexemployeesResponse res = sdk.indexing().people().bulkIndex() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.People.BulkIndex(ctx, components.BulkIndexEmployeesRequest{\n UploadID: \"\",\n Employees: []components.EmployeeInfoDefinition{\n components.EmployeeInfoDefinition{\n Email: \"Robin.Stoltenberg@yahoo.com\",\n Department: \"\",\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n },\n components.EmployeeInfoDefinition{\n Email: \"Robin.Stoltenberg@yahoo.com\",\n Department: \"\",\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n },\n components.EmployeeInfoDefinition{\n Email: \"Robin.Stoltenberg@yahoo.com\",\n Department: \"\",\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/indexemployeelist: {} + /api/index/v1/processallemployeesandteams: + post: + summary: Schedules the processing of uploaded employees and teams + description: | + Schedules the immediate processing of employees and teams uploaded through the indexing API. By default all uploaded people data will be processed asynchronously but this API can be used to schedule its processing on demand. + tags: + - People + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "429": + description: Too Many Requests + x-speakeasy-name-override: processAllEmployeesAndTeams + x-speakeasy-group: indexing.people + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.people.process_all_employees_and_teams() + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.people.processAllEmployeesAndTeams(); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1ProcessallemployeesandteamsResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + PostApiIndexV1ProcessallemployeesandteamsResponse res = sdk.indexing().people().processAllEmployeesAndTeams() + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.People.ProcessAllEmployeesAndTeams(ctx)\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/deleteemployee: + post: + summary: Delete employee + description: Delete an employee. Silently succeeds if employee is not present. + tags: + - People + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/DeleteEmployeeRequest" + required: true + x-exportParamName: DeleteEmployeeRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: delete + x-speakeasy-group: indexing.people + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.people.delete(employee_email="") + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.people.delete({ + employeeEmail: "", + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DeleteEmployeeRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1DeleteemployeeResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeleteEmployeeRequest req = DeleteEmployeeRequest.builder() + .employeeEmail("") + .build(); + + PostApiIndexV1DeleteemployeeResponse res = sdk.indexing().people().delete() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.People.Delete(ctx, components.DeleteEmployeeRequest{\n EmployeeEmail: \"\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/indexteam: + post: + summary: Index team + description: Adds a team or updates information about a team + tags: + - People + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/IndexTeamRequest" + required: true + x-exportParamName: IndexTeamRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: indexTeam + x-speakeasy-group: indexing.people + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.people.index_team(team={ + "id": "", + "name": "", + "datasource_profiles": [ + { + "datasource": "github", + "handle": "", + }, + { + "datasource": "github", + "handle": "", + }, + { + "datasource": "github", + "handle": "", + }, + ], + "members": [ + { + "email": "Nasir.Hilll73@hotmail.com", + }, + ], + }) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.people.indexTeam({ + team: { + id: "", + name: "", + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + ], + members: [ + { + email: "Nasir.Hilll73@hotmail.com", + }, + ], + }, + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1IndexteamResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + IndexTeamRequest req = IndexTeamRequest.builder() + .team(TeamInfoDefinition.builder() + .id("") + .name("") + .members(List.of( + TeamMember.builder() + .email("Nasir.Hilll73@hotmail.com") + .build())) + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build()) + .build(); + + PostApiIndexV1IndexteamResponse res = sdk.indexing().people().indexTeam() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.People.IndexTeam(ctx, components.IndexTeamRequest{\n Team: components.TeamInfoDefinition{\n ID: \"\",\n Name: \"\",\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n Members: []components.TeamMember{\n components.TeamMember{\n Email: \"Nasir.Hilll73@hotmail.com\",\n },\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/deleteteam: + post: + summary: Delete team + description: Delete a team based on provided id. + tags: + - People + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/DeleteTeamRequest" + required: true + x-exportParamName: DeleteTeamRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: deleteTeam + x-speakeasy-group: indexing.people + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.people.delete_team(id="") + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.people.deleteTeam({ + id: "", + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.DeleteTeamRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1DeleteteamResponse; + import java.lang.Exception; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + DeleteTeamRequest req = DeleteTeamRequest.builder() + .id("") + .build(); + + PostApiIndexV1DeleteteamResponse res = sdk.indexing().people().deleteTeam() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.People.DeleteTeam(ctx, components.DeleteTeamRequest{\n ID: \"\",\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/bulkindexteams: + post: + summary: Bulk index teams + description: Replaces all the currently indexed teams using paginated batch API calls. Please refer to the [bulk indexing](https://developers.glean.com/docs/indexing_api_bulk_indexing/#bulk-upload-model) documentation for an explanation of how to use bulk endpoints. + tags: + - People + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/BulkIndexTeamsRequest" + required: true + x-exportParamName: BulkIndexTeamsRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: bulkIndexTeams + x-speakeasy-group: indexing.people + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.people.bulk_index_teams(upload_id="", teams=[ + { + "id": "", + "name": "", + "datasource_profiles": [ + { + "datasource": "github", + "handle": "", + }, + { + "datasource": "github", + "handle": "", + }, + ], + "members": [], + }, + { + "id": "", + "name": "", + "datasource_profiles": [ + { + "datasource": "github", + "handle": "", + }, + { + "datasource": "github", + "handle": "", + }, + ], + "members": [], + }, + { + "id": "", + "name": "", + "datasource_profiles": [ + { + "datasource": "github", + "handle": "", + }, + { + "datasource": "github", + "handle": "", + }, + ], + "members": [], + }, + ]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.people.bulkIndexTeams({ + uploadId: "", + teams: [ + { + id: "", + name: "", + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + ], + members: [], + }, + { + id: "", + name: "", + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + ], + members: [], + }, + { + id: "", + name: "", + datasourceProfiles: [ + { + datasource: "github", + handle: "", + }, + { + datasource: "github", + handle: "", + }, + ], + members: [], + }, + ], + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.*; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1BulkindexteamsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + BulkIndexTeamsRequest req = BulkIndexTeamsRequest.builder() + .uploadId("") + .teams(List.of( + TeamInfoDefinition.builder() + .id("") + .name("") + .members(List.of()) + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build(), + TeamInfoDefinition.builder() + .id("") + .name("") + .members(List.of()) + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build(), + TeamInfoDefinition.builder() + .id("") + .name("") + .members(List.of()) + .datasourceProfiles(List.of( + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build(), + DatasourceProfile.builder() + .datasource("github") + .handle("") + .build())) + .build())) + .build(); + + PostApiIndexV1BulkindexteamsResponse res = sdk.indexing().people().bulkIndexTeams() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.People.BulkIndexTeams(ctx, components.BulkIndexTeamsRequest{\n UploadID: \"\",\n Teams: []components.TeamInfoDefinition{\n components.TeamInfoDefinition{\n ID: \"\",\n Name: \"\",\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n Members: []components.TeamMember{},\n },\n components.TeamInfoDefinition{\n ID: \"\",\n Name: \"\",\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n Members: []components.TeamMember{},\n },\n components.TeamInfoDefinition{\n ID: \"\",\n Name: \"\",\n DatasourceProfiles: []components.DatasourceProfile{\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n components.DatasourceProfile{\n Datasource: \"github\",\n Handle: \"\",\n },\n },\n Members: []components.TeamMember{},\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/bulkindexshortcuts: + post: + summary: Bulk index external shortcuts + description: Replaces all the currently indexed shortcuts using paginated batch API calls. Note that this endpoint is used for indexing shortcuts not hosted by Glean. If you want to upload shortcuts that would be hosted by Glean, please use the `/uploadshortcuts` endpoint. For information on what you can do with Golinks, which are Glean-hosted shortcuts, please refer to [this](https://help.glean.com/en/articles/5628838-how-go-links-work) page. + tags: + - Shortcuts + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/BulkIndexShortcutsRequest" + required: true + x-exportParamName: BulkIndexShortcutsRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: bulkIndex + x-speakeasy-group: indexing.shortcuts + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.shortcuts.bulk_index(upload_id="", shortcuts=[ + { + "input_alias": "", + "destination_url": "https://plump-tune-up.biz/", + "created_by": "", + "intermediate_url": "https://lean-sightseeing.net", + }, + { + "input_alias": "", + "destination_url": "https://plump-tune-up.biz/", + "created_by": "", + "intermediate_url": "https://lean-sightseeing.net", + }, + ]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.shortcuts.bulkIndex({ + uploadId: "", + shortcuts: [ + { + inputAlias: "", + destinationUrl: "https://plump-tune-up.biz/", + createdBy: "", + intermediateUrl: "https://lean-sightseeing.net", + }, + { + inputAlias: "", + destinationUrl: "https://plump-tune-up.biz/", + createdBy: "", + intermediateUrl: "https://lean-sightseeing.net", + }, + ], + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.BulkIndexShortcutsRequest; + import com.glean.api_client.glean_api_client.models.components.ExternalShortcut; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1BulkindexshortcutsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + BulkIndexShortcutsRequest req = BulkIndexShortcutsRequest.builder() + .uploadId("") + .shortcuts(List.of( + ExternalShortcut.builder() + .inputAlias("") + .destinationUrl("https://plump-tune-up.biz/") + .createdBy("") + .intermediateUrl("https://lean-sightseeing.net") + .build(), + ExternalShortcut.builder() + .inputAlias("") + .destinationUrl("https://plump-tune-up.biz/") + .createdBy("") + .intermediateUrl("https://lean-sightseeing.net") + .build())) + .build(); + + PostApiIndexV1BulkindexshortcutsResponse res = sdk.indexing().shortcuts().bulkIndex() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Shortcuts.BulkIndex(ctx, components.BulkIndexShortcutsRequest{\n UploadID: \"\",\n Shortcuts: []components.ExternalShortcut{\n components.ExternalShortcut{\n InputAlias: \"\",\n DestinationURL: \"https://plump-tune-up.biz/\",\n CreatedBy: \"\",\n IntermediateURL: \"https://lean-sightseeing.net\",\n },\n components.ExternalShortcut{\n InputAlias: \"\",\n DestinationURL: \"https://plump-tune-up.biz/\",\n CreatedBy: \"\",\n IntermediateURL: \"https://lean-sightseeing.net\",\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" + /api/index/v1/uploadshortcuts: + post: + summary: Upload shortcuts + description: Creates glean shortcuts for uploaded shortcuts info. Glean would host the shortcuts, and they can be managed in the knowledge tab once uploaded. + tags: + - Shortcuts + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: "#/components/schemas/UploadShortcutsRequest" + required: true + x-exportParamName: UploadShortcutsRequest + responses: + "200": + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: upload + x-speakeasy-group: indexing.shortcuts + x-codeSamples: + - lang: python + label: Python (API Client) + source: |- + from glean.api_client import Glean + import os + + + with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), + ) as g_client: + + g_client.indexing.shortcuts.upload(upload_id="", shortcuts=[ + { + "input_alias": "", + "destination_url": "https://majestic-pharmacopoeia.info/", + "created_by": "", + }, + { + "input_alias": "", + "destination_url": "https://majestic-pharmacopoeia.info/", + "created_by": "", + }, + { + "input_alias": "", + "destination_url": "https://majestic-pharmacopoeia.info/", + "created_by": "", + }, + ]) + + # Use the SDK ... + - lang: typescript + label: Typescript (API Client) + source: |- + import { Glean } from "@gleanwork/api-client"; + + const glean = new Glean({ + apiToken: process.env["GLEAN_API_TOKEN"] ?? "", + }); + + async function run() { + await glean.indexing.shortcuts.upload({ + uploadId: "", + shortcuts: [ + { + inputAlias: "", + destinationUrl: "https://majestic-pharmacopoeia.info/", + createdBy: "", + }, + { + inputAlias: "", + destinationUrl: "https://majestic-pharmacopoeia.info/", + createdBy: "", + }, + { + inputAlias: "", + destinationUrl: "https://majestic-pharmacopoeia.info/", + createdBy: "", + }, + ], + }); + + + } + + run(); + - lang: java + label: Java (API Client) + source: |- + package hello.world; + + import com.glean.api_client.glean_api_client.Glean; + import com.glean.api_client.glean_api_client.models.components.IndexingShortcut; + import com.glean.api_client.glean_api_client.models.components.UploadShortcutsRequest; + import com.glean.api_client.glean_api_client.models.operations.PostApiIndexV1UploadshortcutsResponse; + import java.lang.Exception; + import java.util.List; + + public class Application { + + public static void main(String[] args) throws Exception { + + Glean sdk = Glean.builder() + .apiToken("") + .build(); + + UploadShortcutsRequest req = UploadShortcutsRequest.builder() + .uploadId("") + .shortcuts(List.of( + IndexingShortcut.builder() + .inputAlias("") + .destinationUrl("https://majestic-pharmacopoeia.info/") + .createdBy("") + .build(), + IndexingShortcut.builder() + .inputAlias("") + .destinationUrl("https://majestic-pharmacopoeia.info/") + .createdBy("") + .build(), + IndexingShortcut.builder() + .inputAlias("") + .destinationUrl("https://majestic-pharmacopoeia.info/") + .createdBy("") + .build())) + .build(); + + PostApiIndexV1UploadshortcutsResponse res = sdk.indexing().shortcuts().upload() + .request(req) + .call(); + + // handle response + } + } + - lang: go + label: Go (API Client) + source: "package main\n\nimport(\n\t\"context\"\n\t\"os\"\n\tapiclientgo \"github.com/gleanwork/api-client-go\"\n\t\"github.com/gleanwork/api-client-go/models/components\"\n\t\"log\"\n)\n\nfunc main() {\n ctx := context.Background()\n\n s := apiclientgo.New(\n apiclientgo.WithSecurity(os.Getenv(\"GLEAN_API_TOKEN\")),\n )\n\n res, err := s.Indexing.Shortcuts.Upload(ctx, components.UploadShortcutsRequest{\n UploadID: \"\",\n Shortcuts: []components.IndexingShortcut{\n components.IndexingShortcut{\n InputAlias: \"\",\n DestinationURL: \"https://majestic-pharmacopoeia.info/\",\n CreatedBy: \"\",\n },\n components.IndexingShortcut{\n InputAlias: \"\",\n DestinationURL: \"https://majestic-pharmacopoeia.info/\",\n CreatedBy: \"\",\n },\n components.IndexingShortcut{\n InputAlias: \"\",\n DestinationURL: \"https://majestic-pharmacopoeia.info/\",\n CreatedBy: \"\",\n },\n },\n })\n if err != nil {\n log.Fatal(err)\n }\n if res != nil {\n // handle response\n }\n}" +components: + securitySchemes: + APIToken: + scheme: bearer + type: http + schemas: + IndexDocumentRequest: + type: object + description: Describes the request body of the /indexdocument API call + properties: + version: + type: integer + format: int64 + description: Version number for document for optimistic concurrency control. If absent or 0 then no version checks are done. + document: + description: Document being added/updated + $ref: "#/components/schemas/DocumentDefinition" + required: + - document + IndexDocumentsRequest: + type: object + description: Describes the request body of the /indexdocuments API call + properties: + uploadId: + type: string + description: Optional id parameter to identify and track a batch of documents. + datasource: + type: string + description: Datasource of the documents + documents: + description: Batch of documents being added/updated + type: array + items: + $ref: "#/components/schemas/DocumentDefinition" + required: + - documents + - datasource + UpdatePermissionsRequest: + type: object + description: Describes the request body of the /updatepermissions API call + properties: + datasource: + type: string + objectType: + type: string + description: The type of the document (Case, KnowledgeArticle for Salesforce for example). It cannot have spaces or _ + id: + type: string + description: The datasource specific id for the document. This field is case insensitive and should not be more than 200 characters in length. + viewURL: + type: string + description: | + The permalink for viewing the document. **Note: viewURL is a required field if id was not set when uploading the document.**' + permissions: + $ref: "#/components/schemas/DocumentPermissionsDefinition" + description: The permissions that define who can view this document in the search results. Please refer to [this](https://developers.glean.com/docs/indexing_api_permissions/) for more details. + required: + - permissions + - datasource + GetDocumentCountRequest: + type: object + description: Describes the request body of the /getdocumentcount API call + properties: + datasource: + type: string + description: Datasource name for which document count is needed. + required: + - datasource + GetDocumentCountResponse: + type: object + description: Describes the response body of the /getdocumentcount API call + properties: + documentCount: + type: integer + description: Number of documents corresponding to the specified custom datasource. + GetDocumentStatusRequest: + type: object + description: Describes the request body for /getdocumentstatus API call + properties: + datasource: + type: string + description: Datasource to get fetch document status for + objectType: + type: string + description: Object type of the document to get the status for + docId: + type: string + description: Glean Document ID within the datasource to get the status for. + required: + - datasource + - objectType + - docId + GetDocumentStatusResponse: + type: object + description: Describes the response body of the /getdocumentstatus API call + properties: + uploadStatus: + type: string + description: Upload status, enum of NOT_UPLOADED, UPLOADED, STATUS_UNKNOWN + lastUploadedAt: + type: integer + format: int64 + description: Time of last successful upload, in epoch seconds + indexingStatus: + type: string + description: Indexing status, enum of NOT_INDEXED, INDEXED, STATUS_UNKNOWN + lastIndexedAt: + type: integer + format: int64 + description: Time of last successful indexing, in epoch seconds + BulkIndexRequest: + type: object + description: Describes the request body of a bulk upload API call + required: + - uploadId + properties: + uploadId: + type: string + description: Unique id that must be used for this bulk upload instance + isFirstPage: + type: boolean + description: true if this is the first page of the upload. Defaults to false + isLastPage: + type: boolean + description: true if this is the last page of the upload. Defaults to false + forceRestartUpload: + type: boolean + description: Flag to discard previous upload attempts and start from scratch. Must be specified with isFirstPage=true + BulkIndexTeamsRequest: + type: object + description: Describes the request body of the /bulkindexteams API call + allOf: + - $ref: "#/components/schemas/BulkIndexRequest" + - type: object + properties: + teams: + description: Batch of team information + type: array + items: + $ref: "#/components/schemas/TeamInfoDefinition" + required: + - teams + BulkIndexEmployeesRequest: + type: object + description: Describes the request body of the /bulkindexemployees API call + allOf: + - $ref: "#/components/schemas/BulkIndexRequest" + - type: object + properties: + employees: + description: Batch of employee information + type: array + items: + $ref: "#/components/schemas/EmployeeInfoDefinition" + disableStaleDataDeletionCheck: + type: boolean + description: True if older employee data needs to be force deleted after the upload completes. Defaults to older data being deleted only if the percentage of data being deleted is less than 20%. This must only be set when `isLastPage = true` + required: + - employees + BulkIndexDocumentsRequest: + type: object + description: Describes the request body of the /bulkindexdocuments API call + allOf: + - $ref: "#/components/schemas/BulkIndexRequest" + - type: object + properties: + datasource: + type: string + description: Datasource of the documents + documents: + description: Batch of documents for the datasource + type: array + items: + $ref: "#/components/schemas/DocumentDefinition" + disableStaleDocumentDeletionCheck: + type: boolean + description: True if older documents need to be force deleted after the upload completes. Defaults to older documents being deleted asynchronously. This must only be set when `isLastPage = true` + required: + - datasource + - documents + ProcessAllDocumentsRequest: + type: object + description: Describes the request body of the /processalldocuments API call + properties: + datasource: + type: string + description: If provided, process documents only for this custom datasource. Otherwise all uploaded documents are processed. + DeleteDocumentRequest: + type: object + description: Describes the request body of the /deletedocument API call + properties: + version: + type: integer + format: int64 + description: Version number for document for optimistic concurrency control. If absent or 0 then no version checks are done. + datasource: + type: string + description: datasource of the document + objectType: + type: string + description: object type of the document + id: + type: string + description: The id of the document + required: + - datasource + - id + - objectType + IndexUserRequest: + type: object + description: Describes the request body of the /indexuser API call + properties: + version: + type: integer + format: int64 + description: Version number for document for optimistic concurrency control. If absent or 0 then no version checks are done. + datasource: + type: string + description: The datasource for which the user is added + user: + description: The user to be added or updated + $ref: "#/components/schemas/DatasourceUserDefinition" + required: + - datasource + - user + GetUserCountRequest: + type: object + description: Describes the request body of the /getusercount API call + properties: + datasource: + type: string + description: Datasource name for which user count is needed. + required: + - datasource + GetUserCountResponse: + type: object + description: Describes the response body of the /getusercount API call + properties: + userCount: + type: integer + description: Number of users corresponding to the specified custom datasource. + BulkIndexUsersRequest: + type: object + description: Describes the request body for the /bulkindexusers API call + properties: + uploadId: + type: string + description: Unique id that must be used for this instance of datasource users upload + isFirstPage: + type: boolean + description: true if this is the first page of the upload. Defaults to false + isLastPage: + type: boolean + description: true if this is the last page of the upload. Defaults to false + forceRestartUpload: + type: boolean + description: Flag to discard previous upload attempts and start from scratch. Must be specified with isFirstPage=true + datasource: + type: string + description: datasource of the users + users: + description: batch of users for the datasource + type: array + items: + $ref: "#/components/schemas/DatasourceUserDefinition" + disableStaleDataDeletionCheck: + type: boolean + description: True if older user data needs to be force deleted after the upload completes. Defaults to older data being deleted only if the percentage of data being deleted is less than a reasonable threshold. This must only be set when `isLastPage = true` + required: + - uploadId + - datasource + - users + GreenlistUsersRequest: + type: object + description: Describes the request body of the /betausers API call + properties: + datasource: + type: string + description: Datasource which needs to be made visible to users specified in the `emails` field. + emails: + type: array + description: The emails of the beta users + items: + type: string + format: email + required: + - datasource + - emails + DatasourceUserDefinition: + type: object + description: describes a user in the datasource + properties: + email: + type: string + userId: + description: To be supplied if the user id in the datasource is not the email + type: string + name: + type: string + isActive: + type: boolean + description: set to false if the user is a former employee or a bot + required: + - email + - name + IndexGroupRequest: + type: object + description: Describes the request body of the /indexgroup API call + properties: + version: + type: integer + format: int64 + description: Version number for document for optimistic concurrency control. If absent or 0 then no version checks are done. + datasource: + type: string + description: The datasource for which the group is added + group: + description: The group to be added or updated + $ref: "#/components/schemas/DatasourceGroupDefinition" + required: + - datasource + - group + BulkIndexGroupsRequest: + type: object + description: Describes the request body for the /bulkindexgroups API call + properties: + uploadId: + type: string + description: Unique id that must be used for this instance of datasource groups upload + isFirstPage: + type: boolean + description: true if this is the first page of the upload. Defaults to false + isLastPage: + type: boolean + description: true if this is the last page of the upload. Defaults to false + forceRestartUpload: + type: boolean + description: Flag to discard previous upload attempts and start from scratch. Must be specified with isFirstPage=true + datasource: + type: string + description: datasource of the groups + groups: + description: batch of groups for the datasource + type: array + items: + $ref: "#/components/schemas/DatasourceGroupDefinition" + disableStaleDataDeletionCheck: + type: boolean + description: True if older group data needs to be force deleted after the upload completes. Defaults to older data being deleted only if the percentage of data being deleted is less than a reasonable threshold. This must only be set when `isLastPage = true` + required: + - uploadId + - datasource + - groups + DatasourceGroupDefinition: + type: object + description: describes a group in the datasource + properties: + name: + type: string + description: name of the group. Should be unique among all groups for the datasource, and cannot have spaces. + required: + - name + IndexMembershipRequest: + type: object + description: Describes the request body of the /indexmembership API call + properties: + version: + type: integer + format: int64 + description: Version number for document for optimistic concurrency control. If absent or 0 then no version checks are done. + datasource: + type: string + description: The datasource for which the membership is added + membership: + description: The membership to be added or updated + $ref: "#/components/schemas/DatasourceMembershipDefinition" + required: + - datasource + - membership + BulkIndexMembershipsRequest: + type: object + description: Describes the request body for the /bulkindexmemberships API call + properties: + uploadId: + type: string + description: Unique id that must be used for this instance of datasource group memberships upload + isFirstPage: + type: boolean + description: true if this is the first page of the upload. Defaults to false + isLastPage: + type: boolean + description: true if this is the last page of the upload. Defaults to false + forceRestartUpload: + type: boolean + description: Flag to discard previous upload attempts and start from scratch. Must be specified with isFirstPage=true + datasource: + type: string + description: datasource of the memberships + group: + type: string + description: group who's memberships are specified + memberships: + description: batch of memberships for the group + type: array + items: + $ref: "#/components/schemas/DatasourceBulkMembershipDefinition" + required: + - uploadId + - datasource + - memberships + ProcessAllMembershipsRequest: + type: object + description: Describes the request body of the /processallmemberships API call + properties: + datasource: + type: string + description: If provided, process group memberships only for this custom datasource. Otherwise all uploaded memberships are processed. + DatasourceMembershipDefinition: + type: object + description: describes the membership row of a group. Only one of memberUserId and memberGroupName can be specified. + properties: + groupName: + description: The group for which the membership is specified + type: string + memberUserId: + description: If the member is a user, then the email or datasource id for the user + type: string + memberGroupName: + description: If the member is a group, then the name of the member group + type: string + required: + - groupName + DatasourceBulkMembershipDefinition: + type: object + description: describes the membership row of a group in the bulk uploaded. Only one of memberUserId and memberGroupName can be specified. + properties: + memberUserId: + description: If the member is a user, then the email or datasource id for the user + type: string + memberGroupName: + description: If the member is a group, then the name of the member group + type: string + DeleteUserRequest: + type: object + description: Describes the request body of the /deleteuser API call + properties: + version: + type: integer + format: int64 + description: Version number for document for optimistic concurrency control. If absent or 0 then no version checks are done. + datasource: + type: string + description: The datasource for which the user is removed + email: + description: The email of the user to be deleted + type: string + required: + - datasource + - email + DeleteGroupRequest: + type: object + description: Describes the request body of the /deletegroup API call + properties: + version: + type: integer + format: int64 + description: Version number for document for optimistic concurrency control. If absent or 0 then no version checks are done. + datasource: + type: string + description: The datasource for which the group is removed + groupName: + description: the name of the group to be deleted + type: string + required: + - datasource + - groupName + DeleteMembershipRequest: + type: object + description: Describes the request body of the /deletemembership API call + properties: + version: + type: integer + format: int64 + description: Version number for document for optimistic concurrency control. If absent or 0 then no version checks are done. + datasource: + type: string + description: The datasource for which the membership is removed + membership: + description: the name of the membership to be deleted + $ref: "#/components/schemas/DatasourceMembershipDefinition" + required: + - datasource + - membership + DeleteEmployeeRequest: + type: object + description: Describes the request body of the /deleteemployee API call + properties: + version: + type: integer + format: int64 + description: Version number for document for optimistic concurrency control. If absent or 0 then no version checks are done. + employeeEmail: + description: The deleted employee's email + type: string + required: + - employeeEmail + DeleteTeamRequest: + type: object + description: Describes the request body of the /deleteteam API call + properties: + id: + description: The deleted team's id + type: string + required: + - id + DocumentDefinition: + type: object + description: Indexable document structure + properties: + title: + type: string + description: Document title, in plain text, if present. If not present, the title would be attempted to be extracted from the content. + filename: + type: string + description: Source filename, in plain text, for the document. May be used as a fallback title for the document, if the title is not provided and cannot be extracted from the content. Populate this if there is no explicit title for the document and the content is sourced from a file. + container: + type: string + description: The container name for the content (Folder for example for file content). + containerDatasourceId: + type: string + description: This represents the datasource sepcific id of the container. + containerObjectType: + type: string + description: This represents the object type of the container. It cannot have spaces or _ + datasource: + type: string + objectType: + type: string + description: The type of the document (Case, KnowledgeArticle for Salesforce for example). It cannot have spaces or _ + viewURL: + type: string + description: | + The permalink for viewing the document. **Note: viewURL is a required field for non-entity datasources, but not required if the datasource is used to push custom entities (ie. datasources where isEntityDatasource is false).**' + id: + type: string + description: The datasource specific id for the document. This field is case insensitive and should not be more than 200 characters in length. + summary: + $ref: "#/components/schemas/ContentDefinition" + body: + $ref: "#/components/schemas/ContentDefinition" + author: + $ref: "#/components/schemas/UserReferenceDefinition" + owner: + $ref: "#/components/schemas/UserReferenceDefinition" + description: The current owner of the document, if not the author. + permissions: + $ref: "#/components/schemas/DocumentPermissionsDefinition" + description: The permissions that define who can view this document in the search results. Please refer to [this](https://developers.glean.com/docs/indexing_api_permissions/) for more details. + createdAt: + type: integer + format: int64 + description: The creation time, in epoch seconds. + updatedAt: + type: integer + format: int64 + description: The last update time, in epoch seconds. + updatedBy: + $ref: "#/components/schemas/UserReferenceDefinition" + tags: + type: array + items: + type: string + description: Labels associated with the document. + interactions: + $ref: "#/components/schemas/DocumentInteractionsDefinition" + status: + type: string + additionalUrls: + type: array + items: + type: string + description: Additional variations of the URL that this document points to. + comments: + type: array + items: + $ref: "#/components/schemas/CommentDefinition" + description: Comments associated with the document. + customProperties: + type: array + items: + $ref: "#/components/schemas/CustomProperty" + description: Additional metadata properties of the document. These can surface as [facets and operators](https://developers.glean.com/docs/facets_and_operators_for_custom_datasources/). + required: + - datasource + CommentDefinition: + type: object + description: Describes a comment on a document + properties: + id: + type: string + description: The document specific id for the comment. This field is case insensitive and should not be more than 200 characters in length. + author: + $ref: "#/components/schemas/UserReferenceDefinition" + description: The author of the comment. + content: + $ref: "#/components/schemas/ContentDefinition" + description: The content of the comment. + createdAt: + type: integer + format: int64 + description: The creation time, in epoch seconds. + updatedAt: + type: integer + format: int64 + description: The last updated time, in epoch seconds. + updatedBy: + $ref: "#/components/schemas/UserReferenceDefinition" + description: The user who last updated the comment. + required: + - id + ContentDefinition: + type: object + description: Describes text content or base64 encoded binary content + properties: + mimeType: + type: string + textContent: + type: string + description: text content. Only one of textContent or binary content can be specified + binaryContent: + type: string + description: base64 encoded binary content. Only one of textContent or binary content can be specified + required: + - mimeType + UserReferenceDefinition: + type: object + description: Describes how a user is referenced in a document. The user can be referenced by email or by a datasource specific id. + properties: + email: + type: string + datasourceUserId: + type: string + description: some datasources refer to the user by the datasource user id in the document + name: + type: string + PermissionsGroupIntersectionDefinition: + type: object + description: describes a list of groups that are all required in a permissions constraint + properties: + requiredGroups: + type: array + items: + type: string + DocumentPermissionsDefinition: + type: object + description: describes the access control details of the document + properties: + allowedUsers: + description: List of users who can view the document + type: array + items: + $ref: "#/components/schemas/UserReferenceDefinition" + allowedGroups: + description: List of groups that can view the document + type: array + items: + type: string + allowedGroupIntersections: + description: List of allowed group intersections. This describes a permissions constraint of the form ((GroupA AND GroupB AND GroupC) OR (GroupX AND GroupY) OR ... + type: array + items: + $ref: "#/components/schemas/PermissionsGroupIntersectionDefinition" + allowAnonymousAccess: + description: If true, then any Glean user can view the document + type: boolean + allowAllDatasourceUsersAccess: + description: If true, then any user who has an account in the datasource can view the document. + type: boolean + DocumentInteractionsDefinition: + type: object + description: describes the interactions on the document + properties: + numViews: + type: integer + numLikes: + type: integer + numComments: + type: integer + CheckDocumentAccessRequest: + type: object + description: Describes the request body of the /checkdocumentaccess API call + properties: + datasource: + type: string + description: Datasource of document to check access for. + objectType: + type: string + description: Object type of document to check access for. + docId: + type: string + description: Glean Document ID to check access for. + userEmail: + type: string + description: Email of user to check access for. + required: + - datasource + - objectType + - docId + - userEmail + CheckDocumentAccessResponse: + type: object + description: Describes the response body of the /checkdocumentaccess API call + properties: + hasAccess: + type: boolean + description: If true, user has access to document for search + CustomProperty: + type: object + description: Describes the custom properties of the object. + properties: + name: + type: string + value: + description: Must either be a string or an array of strings. An integer, boolean, etc. is not valid. When OpenAPI Generator supports `oneOf`, we can semantically enforce this. + DatasourceConfig: + $ref: "#/components/schemas/SharedDatasourceConfig" + GetDatasourceConfigRequest: + type: object + description: Describes the request body of the /getdatasourceconfig API call + properties: + datasource: + type: string + description: Datasource name for which config is needed. + required: + - datasource + DatasourceConfigList: + description: List of datasource configurations. + required: + - datasourceConfig + properties: + datasourceConfig: + type: array + description: Datasource configuration. + items: + $ref: "#/components/schemas/SharedDatasourceConfig" + RotateTokenResponse: + description: Describes the response body of the /rotatetoken API call + properties: + rawSecret: + type: string + description: New raw secret + createdAt: + type: integer + format: int64 + description: Unix timestamp in seconds when the new secret value is assigned to the token. The token needs to be rotated before `rotationPeriodMinutes` past the createdAt timestamp otherwise it would be rendered unusable. + rotationPeriodMinutes: + type: integer + format: int64 + description: Refers to the time period in minutes before which this token needs to be rotated. It is required to rotate the token within the specified `rotationPeriodMinutes` after each `/rotatetoken` call, otherwise the tokens would expire. Note that the token would still expire at `expiresAt` timestamp provided during token creation even if the token is being regularly rotated. `rotationPeriodMinutes` property is inherited from the parent token being rotated + IndexEmployeeRequest: + type: object + description: Info about an employee and optional version for that info + properties: + employee: + description: Info about the employee + $ref: "#/components/schemas/EmployeeInfoDefinition" + version: + description: Version number for the employee object. If absent or 0 then no version checks are done + type: integer + format: int64 + required: + - employee + IndexEmployeeListRequest: + type: object + description: Describes the request body of the /indexemployeelist API call + properties: + employees: + description: List of employee info and version. + type: array + items: + $ref: "#/components/schemas/IndexEmployeeRequest" + StructuredLocation: + type: object + description: Detailed location with information about country, state, city etc. + properties: + deskLocation: + type: string + description: Desk number. + timezone: + type: string + description: Location's timezone, e.g. UTC, PST. + address: + type: string + description: Office address or name. + city: + type: string + description: Name of the city. + state: + type: string + description: State code. + region: + type: string + description: Region information, e.g. NORAM, APAC. + zipCode: + type: string + description: ZIP Code for the address. + country: + type: string + description: Country name. + countryCode: + type: string + description: Alpha-2 or Alpha-3 ISO 3166 country code, e.g. US or USA. + SocialNetworkDefinition: + type: object + description: Employee's social network profile + properties: + name: + type: string + description: Possible values are "twitter", "linkedin". + profileName: + type: string + description: Human-readable profile name. + profileUrl: + type: string + description: Link to profile. + AdditionalFieldDefinition: + type: object + description: Additional information about the employee or team. + properties: + key: + type: string + description: Key to reference this field, e.g. "languages". Note that the key should be all lowercase alphabetic characters with no numbers, spaces, hyphens or underscores. + value: + type: array + description: | + List of type string or HypertextField. + + HypertextField is defined as + ``` + { + anchor: string, // Anchor text for the hypertext field. + hyperlink: string, // URL for the hypertext field. + } + ``` + Example: ```{"anchor":"Glean","hyperlink":"https://glean.com"}``` + + When OpenAPI Generator supports oneOf, we will semantically enforce this in the docs. + + **Note**: If using the Python SDK to pass in a list of strings, the value may need to be a list of dictionaries. In that case, the key in that dictionary will be ignored. + Example: ```"languages": [{"lang":"English","lang":"Spanish",...}]```. In this case, the key "lang" will be ignored and can even be passed in as an empty string. + items: + type: object + description: Either a string or HypertextField. When OpenAPI Generator supports oneOf, we can semantically enforce this in the docs. + HypertextField: + type: object + properties: + anchor: + type: string + description: Anchor text for the hypertext field. + hyperlink: + type: string + description: URL for the hypertext field. + EmployeeInfoDefinition: + type: object + description: Describes employee info + properties: + email: + type: string + description: The employee's email + firstName: + type: string + description: | + The first name of the employee. **Note**: The value cannot be empty + lastName: + type: string + description: | + The last name of the employee. **Note**: The value cannot be empty + preferredName: + type: string + description: The preferred name or nickname of the employee + id: + type: string + description: | + **[Advanced]** A unique universal internal identifier for the employee. This is solely used for understanding manager relationships along with `managerId`. + phoneNumber: + type: string + description: The employee's phone number. + location: + type: string + description: The employee's location (city/office name etc). + deprecated: true + structuredLocation: + description: Detailed location with information about country, state, city etc. + $ref: "#/components/schemas/StructuredLocation" + title: + type: string + description: The employee's role title. + photoUrl: + type: string + format: uri + description: The employee's profile pic + businessUnit: + type: string + description: Typically the highest level organizational unit; generally applies to bigger companies with multiple distinct businesses. + department: + type: string + description: An organizational unit where everyone has a similar task, e.g. `Engineering`. + datasourceProfiles: + type: array + description: The datasource profiles of the employee, e.g. `Slack`,`Github`. + items: + $ref: "#/components/schemas/DatasourceProfile" + teams: + type: array + description: Info about the employee's team(s) + items: + $ref: "#/components/schemas/EmployeeTeamInfo" + startDate: + type: string + format: date + description: The date when the employee started + endDate: + type: string + format: date + description: If a former employee, the last date of employment. + bio: + type: string + description: Short biography or mission statement of the employee. + pronoun: + type: string + description: She/her, He/his or other pronoun. + alsoKnownAs: + type: array + description: Other names associated with the employee. + items: + type: string + profileUrl: + type: string + description: Link to internal company person profile. + socialNetworks: + type: array + description: List of social network profiles. + items: + $ref: "#/components/schemas/SocialNetworkDefinition" + managerEmail: + type: string + description: The email of the employee's manager + managerId: + type: string + description: | + **[Advanced]** A unique universal internal identifier for the employee's manager. This is solely used in conjunction with `id`. + type: + type: string + description: The type of the employee, an enum of `FULL_TIME`, `CONTRACTOR`, `NON_EMPLOYEE` + default: FULL_TIME + relationships: + type: array + description: List of unidirectional relationships with other employees. E.g. this employee (`A`) is a CHIEF_OF_STAFF to another employee (`B`); or this employee (`A`) is an EXECUTIVE_ASSISTANT of another employee (`C`). The mapping should be attached to `A`'s profile. + items: + $ref: "#/components/schemas/EntityRelationship" + status: + type: string + description: The status of the employee, an enum of `CURRENT`, `FUTURE`, `EX` + default: CURRENT + additionalFields: + type: array + description: List of additional fields with more information about the employee. + items: + $ref: "#/components/schemas/AdditionalFieldDefinition" + required: + - department + - email + EmployeeAndVersionDefinition: + type: object + description: describes info about an employee and optional version for that info + properties: + employee: + description: Info about the employee + $ref: "#/components/schemas/EmployeeInfoDefinition" + version: + description: Version number for the employee object. If absent or 0 then no version checks are done + type: integer + format: int64 + required: + - info + EmployeeTeamInfo: + type: object + description: Information about which team an employee belongs to + properties: + id: + type: string + description: unique identifier for this team + name: + type: string + description: Team name + url: + type: string + format: uri + description: Link to internal company team page + EntityRelationship: + type: object + description: Describes a relationship edge between a source and destination entity + required: + - name + - email + properties: + name: + type: string + description: The title or type of relationship. Currently an enum of `CHIEF_OF_STAFF`, `EXECUTIVE_ASSISTANT` + email: + type: string + description: Email of the person with whom the relationship exists. Per the example above, either `B` or `C`'s email depending on the relationship. + TeamMember: + type: object + description: Information about a team's member + properties: + email: + type: string + description: The member's email + format: email + relationship: + type: string + description: The member's relationship to the team, an enum of `MEMBER`, `MANAGER`, `LEAD`, `POINT_OF_CONTACT`, `OTHER` + default: MEMBER + join_date: + type: string + format: date + description: The member's start date + required: + - email + TeamEmail: + type: object + description: Information about a team's email + properties: + email: + type: string + format: email + description: An email address + type: + type: string + description: An enum of `PRIMARY`, `SECONDARY`, `ONCALL`, `OTHER` + default: OTHER + required: + - email + - type + TeamInfoDefinition: + type: object + description: Information about an employee's team + properties: + id: + type: string + description: The unique ID of the team + name: + type: string + description: Human-readable team name + description: + type: string + description: The description of this team + businessUnit: + type: string + description: Typically the highest level organizational unit; generally applies to bigger companies with multiple distinct businesses. + department: + type: string + description: An organizational unit where everyone has a similar task, e.g. `Engineering`. + photoUrl: + type: string + format: uri + description: A link to the team's photo + externalLink: + type: string + format: uri + description: | + A link to an external team page. If set, team results will link to it. + emails: + type: array + description: The emails of the team + items: + $ref: "#/components/schemas/TeamEmail" + datasourceProfiles: + type: array + description: The datasource profiles of the team, e.g. `Slack`,`Github`. + items: + $ref: "#/components/schemas/DatasourceProfile" + members: + type: array + description: The members of the team + items: + $ref: "#/components/schemas/TeamMember" + additionalFields: + type: array + description: List of additional fields with more information about the team. + items: + $ref: "#/components/schemas/AdditionalFieldDefinition" + required: + - id + - members + - name + IndexTeamRequest: + type: object + description: Info about a team and optional version for that info + properties: + team: + description: Info about the team + $ref: "#/components/schemas/TeamInfoDefinition" + version: + description: Version number for the team object. If absent or 0 then no version checks are done + type: integer + format: int64 + required: + - team + BulkIndexShortcutsRequest: + type: object + description: Describes the request body of the /bulkindexshortcuts API call + allOf: + - $ref: "#/components/schemas/BulkIndexRequest" + - type: object + properties: + shortcuts: + description: Batch of shortcuts information + type: array + items: + $ref: "#/components/schemas/ExternalShortcut" + required: + - shortcuts + UploadShortcutsRequest: + type: object + description: Describes the request body of the /uploadshortcuts API call + allOf: + - $ref: "#/components/schemas/BulkIndexRequest" + - type: object + properties: + shortcuts: + description: Batch of shortcuts information + type: array + items: + $ref: "#/components/schemas/IndexingShortcut" + required: + - shortcuts + DebugDatasourceStatusResponse: + type: object + description: Describes the response body of the /debug/{datasource}/status API call + properties: + documents: + type: object + properties: + bulkUploadHistory: + type: object + $ref: "#/components/schemas/BulkUploadHistoryEventList" + counts: + type: object + properties: + uploaded: + type: array + items: + $ref: "#/components/schemas/DatasourceObjectTypeDocumentCountEntry" + description: A list of object types and corresponding upload counts + indexed: + type: array + description: The number of documents indexed, grouped by objectType + items: + $ref: "#/components/schemas/DatasourceObjectTypeDocumentCountEntry" + processingHistory: + $ref: "#/components/schemas/ProcessingHistoryEventList" + identity: + type: object + properties: + processingHistory: + $ref: "#/components/schemas/ProcessingHistoryEventList" + users: + $ref: "#/components/schemas/DebugDatasourceStatusIdentityResponseComponent" + groups: + $ref: "#/components/schemas/DebugDatasourceStatusIdentityResponseComponent" + memberships: + $ref: "#/components/schemas/DebugDatasourceStatusIdentityResponseComponent" + datasourceVisibility: + type: string + description: The visibility of the datasource, an enum of VISIBLE_TO_ALL, VISIBLE_TO_TEST_GROUP, NOT_VISIBLE + enum: + - ENABLED_FOR_ALL + - ENABLED_FOR_TEST_GROUP + - NOT_ENABLED + example: ENABLED_FOR_ALL + DebugDatasourceStatusIdentityResponseComponent: + type: object + properties: + bulkUploadHistory: + type: object + $ref: "#/components/schemas/BulkUploadHistoryEventList" + counts: + type: object + properties: + uploaded: + type: integer + description: The number of users/groups/memberships uploaded + example: 15 + DatasourceObjectTypeDocumentCountEntry: + type: object + properties: + objectType: + type: string + description: The object type of the document + example: Article + count: + type: integer + description: The number of documents of the corresponding objectType + example: 15 + BulkUploadHistoryEvent: + type: object + description: Information about a successful bulk upload + properties: + uploadId: + type: string + description: The unique ID of the upload + example: upload-id-content-1707403081 + startTime: + type: string + description: The start time of the upload in ISO 8601 format + example: "2021-08-06T17:58:01.000Z" + endTime: + type: string + description: The end time of the upload in ISO 8601 format, 'NA' if the upload is still active + example: "2021-08-06T18:58:01.000Z" + status: + type: string + description: The status of the upload, an enum of ACTIVE, SUCCESSFUL + enum: + - ACTIVE + - SUCCESSFUL + example: SUCCESSFUL + processingState: + type: string + description: The current state of the upload, an enum of UNAVAILABLE, UPLOAD STARTED, UPLOAD IN PROGRESS, UPLOAD COMPLETED, DELETION PAUSED, INDEXING COMPLETED + enum: + - UNAVAILABLE + - UPLOAD STARTED + - UPLOAD IN PROGRESS + - UPLOAD COMPLETED + - DELETION PAUSED + - INDEXING COMPLETED + example: UPLOAD COMPLETED + BulkUploadHistoryEventList: + description: Information about active and recent successful uploads for the datasource + type: array + items: + $ref: "#/components/schemas/BulkUploadHistoryEvent" + DebugDocumentRequest: + type: object + description: Describes the request body of the /debug/{datasource}/document API call. + properties: + objectType: + type: string + description: Object type of the document to get the status for. + example: Article + docId: + type: string + description: Glean Document ID within the datasource to get the status for. + example: art123 + required: + - objectType + - docId + DebugDocumentResponse: + type: object + description: Describes the response body of the /debug/{datasource}/document API call + properties: + status: + type: object + description: Upload and indexing status of the document + $ref: "#/components/schemas/DocumentStatusResponse" + uploadedPermissions: + $ref: "#/components/schemas/DocumentPermissionsDefinition" + DebugDocumentsRequest: + type: object + description: Describes the request body of the /debug/{datasource}/documents API call. + properties: + debugDocuments: + type: array + description: Documents to fetch debug information for + items: + $ref: "#/components/schemas/DebugDocumentRequest" + required: + - debugDocuments + DebugDocumentsResponseItem: + type: object + description: Describes the response body of a single document in the /debug/{datasource}/documents API call + properties: + docId: + type: string + description: Id of the document + objectType: + type: string + description: objectType of the document + debugInfo: + type: object + description: Debug information of the document + $ref: "#/components/schemas/DebugDocumentResponse" + DebugDocumentsResponse: + type: object + description: Describes the response body of a single document in the /debug/{datasource}/documents API call + properties: + documentStatuses: + type: array + description: List of document ids/urls and their debug information + items: + $ref: "#/components/schemas/DebugDocumentsResponseItem" + DocumentStatusResponse: + type: object + description: Describes the document status response body + properties: + uploadStatus: + type: string + description: Upload status, enum of NOT_UPLOADED, UPLOADED, STATUS_UNKNOWN + example: UPLOADED + lastUploadedAt: + type: string + description: Time of last successful upload for the document, in ISO 8601 format + example: "2021-08-06T17:58:01.000Z" + indexingStatus: + type: string + description: Indexing status, enum of NOT_INDEXED, INDEXED, STATUS_UNKNOWN + example: INDEXED + lastIndexedAt: + type: string + description: Time of last successful indexing for the document, in ISO 8601 format + example: "2021-08-06T17:58:01.000Z" + permissionIdentityStatus: + type: string + description: Permission identity status, enum of NOT_UPLOADED, UPLOADED, STATUS_UNKNOWN (Always unknown if `identityDatasourceName` is set). Document visibility may be affected status is `NOT_UPLOADED`. + example: UPLOADED + LifeCycleEvent: + type: object + properties: + event: + type: string + description: Type of event + enum: + - UPLOADED + - INDEXED + - DELETION_REQUESTED + - DELETED + example: INDEXED + timestamp: + type: string + description: Timestamp of the event + example: "2021-08-06T17:58:01.000Z" + ProcessingHistoryEvent: + type: object + description: Processing history event for a datasource + properties: + startTime: + type: string + description: The start time of the processing in ISO 8601 format + example: "2021-08-06T17:58:01.000Z" + endTime: + type: string + description: The end time of the processing in ISO 8601 format, 'NA' if still in progress + example: "2021-08-06T18:58:01.000Z" + ProcessingHistoryEventList: + description: Information about processing history for the datasource + type: array + items: + $ref: "#/components/schemas/ProcessingHistoryEvent" + DebugUserRequest: + type: object + description: Describes the request body of the /debug/{datasource}/user API call + properties: + email: + type: string + description: Email ID of the user to get the status for + example: u1@foo.com + required: + - email + DebugUserResponse: + type: object + description: Describes the response body of the /debug/{datasource}/user API call + properties: + status: + type: object + description: Upload and indexing status of the user + $ref: "#/components/schemas/UserStatusResponse" + uploadedGroups: + type: array + description: List of groups the user is a member of, as uploaded via permissions API. + items: + $ref: "#/components/schemas/DatasourceGroupDefinition" + UserStatusResponse: + type: object + description: Describes the user status response body + properties: + isActiveUser: + type: boolean + description: Whether the user is active or not + example: true + uploadStatus: + $ref: "#/components/schemas/UploadStatusEnum" + lastUploadedAt: + type: string + description: Time of last successful upload for the user, in ISO 8601 format + example: "2021-08-06T17:58:01.000Z" + UploadStatusEnum: + type: string + description: Upload status, enum of NOT_UPLOADED, UPLOADED, STATUS_UNKNOWN + enum: + - UPLOADED + - NOT_UPLOADED + - STATUS_UNKNOWN + example: UPLOADED + PropertyDefinition: + properties: + name: + type: string + description: The name of the property in the `DocumentMetadata` (e.g. 'createTime', 'updateTime', 'author', 'container'). In the future, this will support custom properties too. + displayLabel: + type: string + description: The user friendly label for the property. + displayLabelPlural: + type: string + description: The user friendly label for the property that will be used if a plural context. + propertyType: + type: string + enum: + - TEXT + - DATE + - INT + - USERID + - PICKLIST + - TEXTLIST + - MULTIPICKLIST + description: The type of custom property - this governs the search and faceting behavior. Note that MULTIPICKLIST is not yet supported. + uiOptions: + type: string + enum: + - NONE + - SEARCH_RESULT + - DOC_HOVERCARD + hideUiFacet: + type: boolean + description: If true then the property will not show up as a facet in the UI. + uiFacetOrder: + type: integer + description: Will be used to set the order of facets in the UI, if present. If set for one facet, must be set for all non-hidden UI facets. Must take on an integer value from 1 (shown at the top) to N (shown last), where N is the number of non-hidden UI facets. These facets will be ordered below the built-in "Type" and "Tag" operators. + skipIndexing: + type: boolean + description: If true then the property will not be indexed for retrieval and ranking. + group: + type: string + description: The unique identifier of the `PropertyGroup` to which this property belongs. + PropertyGroup: + description: A grouping for multiple PropertyDefinition. Grouped properties will be displayed together in the UI. + properties: + name: + type: string + description: The unique identifier of the group. + displayLabel: + type: string + description: The user-friendly group label to display. + ObjectDefinition: + description: The definition for an `DocumentMetadata.objectType` within a datasource. + properties: + name: + type: string + description: Unique identifier for this `DocumentMetadata.objectType`. If omitted, this definition is used as a default for all unmatched `DocumentMetadata.objectType`s in this datasource. + displayLabel: + type: string + description: The user-friendly name of the object for display. + docCategory: + type: string + enum: + - UNCATEGORIZED + - TICKETS + - CRM + - PUBLISHED_CONTENT + - COLLABORATIVE_CONTENT + - QUESTION_ANSWER + - MESSAGING + - CODE_REPOSITORY + - CHANGE_MANAGEMENT + - PEOPLE + - EMAIL + - SSO + - ATS + - KNOWLEDGE_HUB + - EXTERNAL_SHORTCUT + - ENTITY + - CALENDAR + description: The document category of this object type. + propertyDefinitions: + type: array + items: + $ref: "#/components/schemas/PropertyDefinition" + propertyGroups: + type: array + description: A list of `PropertyGroup`s belonging to this object type, which will group properties to be displayed together in the UI. + items: + $ref: "#/components/schemas/PropertyGroup" + summarizable: + description: Whether or not the object is summarizable + type: boolean + CanonicalizingRegexType: + description: Regular expression to apply to an arbitrary string to transform it into a canonical string. + properties: + matchRegex: + type: string + description: Regular expression to match to an arbitrary string. + rewriteRegex: + type: string + description: Regular expression to transform into a canonical string. + ConnectorType: + type: string + description: The source from which document content was pulled, e.g. an API crawl or browser history + enum: + - API_CRAWL + - BROWSER_CRAWL + - BROWSER_HISTORY + - BUILTIN + - FEDERATED_SEARCH + - PUSH_API + - WEB_CRAWL + - NATIVE_HISTORY + IconConfig: + description: Defines how to render an icon + properties: + generatedBackgroundColorKey: + type: string + backgroundColor: + type: string + color: + type: string + key: + type: string + iconType: + enum: + - COLLECTION + - CUSTOM + - DATASOURCE + - DATASOURCE_INSTANCE + - FAVICON + - FILE_TYPE + - GENERATED_BACKGROUND + - GLYPH + - MIME_TYPE + - NO_ICON + - PERSON + - REACTIONS + - URL + masked: + type: boolean + description: Whether the icon should be masked based on current theme. + name: + type: string + description: The name of the icon if applicable, e.g. the glyph name for `IconType.GLYPH` icons. + url: + type: string + description: The URL to an image to be displayed if applicable, e.g. the URL for `iconType.URL` icons. + example: + color: "#343CED" + key: person_icon + iconType: GLYPH + name: user + Quicklink: + description: An action for a specific datasource that will show up in autocomplete and app card, e.g. "Create new issue" for jira. + properties: + name: + type: string + description: Full action name. Used in autocomplete. + shortName: + type: string + description: Shortened name. Used in app cards. + url: + type: string + description: The URL of the action. + iconConfig: + $ref: "#/components/schemas/IconConfig" + description: The config for the icon for this quicklink + id: + type: string + description: Unique identifier of this quicklink + scopes: + type: array + description: The scopes for which this quicklink is applicable + items: + type: string + enum: + - APP_CARD + - AUTOCOMPLETE_EXACT_MATCH + - AUTOCOMPLETE_FUZZY_MATCH + - AUTOCOMPLETE_ZERO_QUERY + - NEW_TAB_PAGE + SharedDatasourceConfigNoInstance: + type: object + description: Structure describing shared config properties of a datasource with no multi-instance support. + required: + - name + properties: + name: + type: string + description: Unique identifier of datasource instance to which this config applies. + displayName: + type: string + description: The user-friendly instance label to display. If omitted, falls back to the title-cased `name`. + datasourceCategory: + type: string + enum: + - UNCATEGORIZED + - TICKETS + - CRM + - PUBLISHED_CONTENT + - COLLABORATIVE_CONTENT + - QUESTION_ANSWER + - MESSAGING + - CODE_REPOSITORY + - CHANGE_MANAGEMENT + - PEOPLE + - EMAIL + - SSO + - ATS + - KNOWLEDGE_HUB + - EXTERNAL_SHORTCUT + - ENTITY + - CALENDAR + default: UNCATEGORIZED + description: The type of this datasource. It is an important signal for relevance and must be specified and cannot be UNCATEGORIZED. Please refer to [this](https://developers.glean.com/docs/indexing_api_datasource_category/) for more details. + urlRegex: + type: string + description: "Regular expression that matches URLs of documents of the datasource instance. The behavior for multiple matches is non-deterministic. **Note: `urlRegex` is a required field for non-entity datasources, but not required if the datasource is used to push custom entities (ie. datasources where isEntityDatasource is false). Please add a regex as specific as possible to this datasource instance.**" + example: https://example-company.datasource.com/.* + iconUrl: + type: string + description: The URL to an image to be displayed as an icon for this datasource instance. Must have a transparency mask. SVG are recommended over PNG. Public, scio-authenticated and Base64 encoded data URLs are all valid (but not third-party-authenticated URLs). + objectDefinitions: + type: array + description: The list of top-level `objectType`s for the datasource. + items: + $ref: "#/components/schemas/ObjectDefinition" + suggestionText: + type: string + description: Example text for what to search for in this datasource + homeUrl: + type: string + description: The URL of the landing page for this datasource instance. Should point to the most useful page for users, not the company marketing page. + crawlerSeedUrls: + type: array + description: This only applies to WEB_CRAWL and BROWSER_CRAWL datasources. Defines the seed URLs for crawling. + items: + type: string + iconDarkUrl: + type: string + description: The URL to an image to be displayed as an icon for this datasource instance in dark mode. Must have a transparency mask. SVG are recommended over PNG. Public, scio-authenticated and Base64 encoded data URLs are all valid (but not third-party-authenticated URLs). + hideBuiltInFacets: + type: array + description: List of built-in facet types that should be hidden for the datasource. + items: + type: string + enum: + - TYPE + - TAG + - AUTHOR + - OWNER + canonicalizingURLRegex: + type: array + description: A list of regular expressions to apply to an arbitrary URL to transform it into a canonical URL for this datasource instance. Regexes are to be applied in the order specified in this list. + items: + $ref: "#/components/schemas/CanonicalizingRegexType" + canonicalizingTitleRegex: + type: array + description: A list of regular expressions to apply to an arbitrary title to transform it into a title that will be displayed in the search results + items: + $ref: "#/components/schemas/CanonicalizingRegexType" + redlistTitleRegex: + type: string + description: A regex that identifies titles that should not be indexed + connectorType: + allOf: + - $ref: "#/components/schemas/ConnectorType" + type: string + deprecated: false + quicklinks: + type: array + description: List of actions for this datasource instance that will show up in autocomplete and app card, e.g. "Create new issue" for jira + items: + $ref: "#/components/schemas/Quicklink" + renderConfigPreset: + type: string + description: The name of a render config to use for displaying results from this datasource. Any well known datasource name may be used to render the same as that source, e.g. `web` or `gdrive`. Please refer to [this](https://developers.glean.com/docs/rendering_search_results/) for more details + aliases: + type: array + description: Aliases that can be used as `app` operator-values. + items: + type: string + isOnPrem: + type: boolean + description: Whether or not this datasource is hosted on-premise. + trustUrlRegexForViewActivity: + type: boolean + default: true + description: True if browser activity is able to report the correct URL for VIEW events. Set this to true if the URLs reported by Chrome are constant throughout each page load. Set this to false if the page has Javascript that modifies the URL during or after the load. + includeUtmSource: + type: boolean + description: If true, a utm_source query param will be added to outbound links to this datasource within Glean. + stripFragmentInCanonicalUrl: + type: boolean + default: true + description: If true, the fragment part of the URL will be stripped when converting to a canonical url. + CustomDatasourceConfig: + description: Structure describing config properties of a custom datasource + allOf: + - $ref: "#/components/schemas/SharedDatasourceConfigNoInstance" + - type: object + properties: + identityDatasourceName: + type: string + description: If the datasource uses another datasource for identity info, then the name of the datasource. The identity datasource must exist already. + productAccessGroup: + type: string + description: If the datasource uses a specific product access group, then the name of that group. + isUserReferencedByEmail: + type: boolean + description: whether email is used to reference users in document ACLs and in group memberships. + isEntityDatasource: + type: boolean + default: false + description: True if this datasource is used to push custom entities. + isTestDatasource: + type: boolean + default: false + description: True if this datasource will be used for testing purpose only. Documents from such a datasource wouldn't have any effect on search rankings. + DatasourceProfile: + required: + - datasource + - handle + properties: + datasource: + type: string + example: github + description: The datasource the profile is of. + handle: + type: string + description: The display name of the entity in the given datasource. + url: + type: string + description: URL to view the entity's profile. + nativeAppUrl: + type: string + description: A deep link, if available, into the datasource's native application for the entity's platform (i.e. slack://...). + isUserGenerated: + type: boolean + description: For internal use only. True iff the data source profile was manually added by a user from within Glean (aka not from the original data source) + ShortcutProperties: + properties: + inputAlias: + type: string + description: link text following the viewPrefix as entered by the user. For example, if the view prefix is `go/` and the shortened URL is `go/abc`, then `abc` is the inputAlias. + description: + type: string + description: A short, plain text blurb to help people understand the intent of the shortcut. + destinationUrl: + type: string + format: url + description: destination URL for the shortcut. + createdBy: + type: string + description: Email of the user who created this shortcut. + createTime: + type: integer + format: int64 + description: The time the shortcut was created in epoch seconds. + updatedBy: + type: string + description: Email of the user who last updated this shortcut. + updateTime: + type: integer + format: int64 + description: The time the shortcut was updated in epoch seconds. + ExternalShortcut: + allOf: + - $ref: "#/components/schemas/ShortcutProperties" + - type: object + required: + - destinationUrl + - intermediateUrl + - createdBy + - inputAlias + properties: + title: + type: string + description: Title of the golink + intermediateUrl: + type: string + format: url + description: The URL from which the user is then redirected to the destination URL. + decayedVisitScore: + type: number + format: double + description: decayed visits score for ranking + editUrl: + type: string + format: url + description: The URL using which the user can access the edit page of the shortcut. + SharedDatasourceConfig: + description: Structure describing shared config properties of the datasource (including multi-instance support) + allOf: + - $ref: "#/components/schemas/SharedDatasourceConfigNoInstance" + - type: object + properties: + datasourceName: + type: string + description: The (non-unique) name of the datasource of which this config is an instance, e.g. "jira". + instanceOnlyName: + type: string + description: The instance of the datasource for this particular config, e.g. "onprem". + instanceDescription: + type: string + description: A human readable string identifying this instance as compared to its peers, e.g. "github.com/askscio" or "github.askscio.com" + IndexingShortcut: + allOf: + - $ref: "#/components/schemas/ShortcutProperties" + - type: object + required: + - destinationUrl + - createdBy + - inputAlias + properties: + unlisted: + type: boolean + description: Whether this shortcut is unlisted or not. Unlisted shortcuts are visible to author and admins only. + urlTemplate: + type: string + description: For variable shortcuts, contains the URL template; note, `destinationUrl` contains default URL.