diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock index 5deb736c..b95169fd 100644 --- a/.speakeasy/gen.lock +++ b/.speakeasy/gen.lock @@ -1,26 +1,26 @@ lockVersion: 2.0.0 id: 3e3290ca-0ee8-4981-b1bc-14536048fa63 management: - docChecksum: 7cfbc96a37c380a5aded568917db8adb + docChecksum: 313695a330c3b8a571fc85c3a6dc8131 docVersion: 0.9.0 - speakeasyVersion: 1.759.3 - generationVersion: 2.869.25 - releaseVersion: 0.12.18 - configChecksum: 55d8c28074319eb59aad3583f2c9d236 + speakeasyVersion: 1.761.1 + generationVersion: 2.879.6 + releaseVersion: 0.12.19 + configChecksum: b417f3c3a59516a14cfdc575dd099a41 repoURL: https://github.com/gleanwork/api-client-python.git installationURL: https://github.com/gleanwork/api-client-python.git published: true persistentEdits: - generation_id: 7db5cd3c-64ff-4f53-a68f-152476336148 - pristine_commit_hash: 10aee9c817a1cb26836721eb17e7ff703bdb068b - pristine_tree_hash: e26ec916089dbf8217a833ec40c10407483f1f6f + generation_id: be565be4-0434-4fd9-b3ca-57a74af04707 + pristine_commit_hash: a4b08a8854de9abcddca15f68d48f4d7e586b7d0 + pristine_tree_hash: 6314a92f4f8e4641195d1abfca2e202c2dab9fd1 features: python: additionalDependencies: 1.0.0 additionalProperties: 1.0.1 configurableModuleName: 0.2.0 constsAndDefaults: 1.0.7 - core: 6.0.20 + core: 6.0.21 defaultEnabledRetries: 0.2.0 deprecations: 3.0.2 devContainers: 3.0.0 @@ -29,7 +29,7 @@ features: examples: 3.0.3 flatRequests: 1.0.1 flattening: 3.1.1 - globalSecurity: 3.0.5 + globalSecurity: 3.0.7 globalSecurityCallbacks: 1.0.0 globalSecurityFlattening: 1.0.0 globalServerURLs: 3.2.1 @@ -1019,8 +1019,8 @@ trackedFiles: pristine_git_object: 6b1e6c24ec175c5d5ed53f605e5ad94e2600fab7 docs/models/documentspecugctype2.md: id: 482fa3980aad - last_write_checksum: sha1:0ea452e225f56b3c8668f3b1259a3fd9a3f3bfeb - pristine_git_object: a105173da956c0521efb779e5d4f81d157c804e0 + last_write_checksum: sha1:1568f539b72084faf5bb533f37b07a75123de070 + pristine_git_object: fea16d9d2b0488c5d45bbe5e1faca5401c61865c docs/models/documentspecunion.md: id: eb4d3f9f0d42 last_write_checksum: sha1:0d398dc3150ae343de568eef63c7c6e388721207 @@ -1239,8 +1239,8 @@ trackedFiles: pristine_git_object: a851a7f13eb25d515fa9b9244c5dfdc98fa14e2c docs/models/feedrequestcategory.md: id: 31a02f3064c7 - last_write_checksum: sha1:fe73753ac2cec1ef2fb81c46d641b9ac45971281 - pristine_git_object: fe86268508f2f4c04c80c633e9064155af4a0417 + last_write_checksum: sha1:58517f2ec589d8c087d00d12607f289252a7f33f + pristine_git_object: 1fb21bd08725048d355cbc1c5c857c12c51261a6 docs/models/feedrequestoptions.md: id: 58eb26b19e77 last_write_checksum: sha1:fd2ab08736cef8156169b0cfee8c52e7aed1accf @@ -1259,8 +1259,8 @@ trackedFiles: pristine_git_object: 6318b0206b7d4027b036e78c709ed4eb259ccedb docs/models/feedresultcategory.md: id: a5f77f38d0a7 - last_write_checksum: sha1:dbafe584e477cc1c2316e26df4327a438e4c301c - pristine_git_object: 2cf11cee9f3ef599cd23f12daf9d17b48b94360b + last_write_checksum: sha1:ffbc121700071a46f0d568b15c3d3deb8c557eab + pristine_git_object: 3e8ed01bd7e3b71e0ed0febcad89785a66697a71 docs/models/fieldscope.md: id: e6b52bcb22a6 last_write_checksum: sha1:13a1492ce39d2f89a01d626996a345a1339a1873 @@ -1647,8 +1647,8 @@ trackedFiles: pristine_git_object: 7024b2f4514140f03c2dfc6ba7c5db04bdc216e7 docs/models/justificationtype.md: id: 8286affacee4 - last_write_checksum: sha1:2306aa64a9ae8b052f757f7f1494746e8711ec95 - pristine_git_object: a6c62caffbe169d39ef4ae97fa191efeb2aa4b96 + last_write_checksum: sha1:ba70b2081e85371b7732a04750fa98014b467627 + pristine_git_object: 156cd0971c6e03117a8d9f99cec7015d4f2da438 docs/models/knowledgetype.md: id: 1e0c90679228 last_write_checksum: sha1:0030a7539b9362bbb59e0bbd36580676058b3540 @@ -2415,8 +2415,8 @@ trackedFiles: pristine_git_object: c7f7adecc74cc4072799169c68332df2d8932c44 docs/models/ugctype.md: id: 675d62d57771 - last_write_checksum: sha1:a631c234f78e929097bd310c9d337699f7c72593 - pristine_git_object: 9c8c5e086900d838bed8205ec50ecd1a49f44aa8 + last_write_checksum: sha1:dc863b7e745b73f7284e28036cff182d7f2205ab + pristine_git_object: 696a31174d19000f1e167ae332eaf343e6bd0bbb docs/models/uiconfig.md: id: c4d3817a701c last_write_checksum: sha1:dd422e5a1bbf9af85722cd43c5437716b8bb3017 @@ -2719,8 +2719,8 @@ trackedFiles: pristine_git_object: a2231eb1cba2a1753012ea00667e6a51601b888a docs/sdks/indexingshortcuts/README.md: id: 5cf29bd168af - last_write_checksum: sha1:b2363066fd13f1d883d54848bab1a910b1e7182a - pristine_git_object: 02339bf7ce713ea28210986d201dd89a18d038dc + last_write_checksum: sha1:a5e8c40acb0c02d2f37e2595aab1170492a126bf + pristine_git_object: 6d8cda7ab4483ef459462bbd02a38ff90befddd9 docs/sdks/insights/README.md: id: cc2be3db9032 last_write_checksum: sha1:5b1bf1e8254a299da7c5fb3dc7bac0737a37ed9b @@ -2771,8 +2771,8 @@ trackedFiles: pristine_git_object: e2fda7fe263c2a111e53872e3ad5bc324b4dccfe pyproject.toml: id: 5d07e7d72637 - last_write_checksum: sha1:e341f817e33aa4644d6a5b5cdaf9072bcd202aba - pristine_git_object: ef7641d7d740f4b2951e41fba5ec4c91e5c5d29b + last_write_checksum: sha1:5fd94901bbb750af287b5750f6c23693ae8c002c + pristine_git_object: ead28da3fa17b2bf357f9956c686da6aa14f6db6 scripts/prepare_readme.py: id: e0c5957a6035 last_write_checksum: sha1:c2c83f71dea61eb50c9e05da83b16d18b4da8794 @@ -2799,8 +2799,8 @@ trackedFiles: pristine_git_object: 58c4d70ac1797b86ff5c4237cafbc344c42d8f64 src/glean/api_client/_version.py: id: 0ce22b26136b - last_write_checksum: sha1:2a8e1885ffd3a18a97b41a8572aded8bb7c3f483 - pristine_git_object: 7585c68fe8f1ef4ed6f406d8b5892f3a53c05153 + last_write_checksum: sha1:3f72c721c9f39b95f61f8a33a7fe074d74e4b780 + pristine_git_object: 08ab8ef27cc9d18d00705e3e842c5167e2945e57 src/glean/api_client/agents.py: id: b925701a9217 last_write_checksum: sha1:ee99ae3d58f7f77ac2eba99c104d04d53c16c09c @@ -2819,8 +2819,8 @@ trackedFiles: pristine_git_object: 90fa357df14260a5a952f42b0b8500c5fee5968b src/glean/api_client/basesdk.py: id: a9eeecf7fa49 - last_write_checksum: sha1:d3d816ae1402d08e19e014db50bc9b62eddabc32 - pristine_git_object: dec3e125b14c0afe27fc19d68e384064967cf60a + last_write_checksum: sha1:17c945d87dd7b5c9fa47ed80f33c5655c9bfcf87 + pristine_git_object: e4482493368f58a14c39fcecb611f88c046a5c03 src/glean/api_client/client.py: id: c0c188098f10 last_write_checksum: sha1:7573d8778bba72612e7afc379c05e23c1de2ed1c @@ -2939,8 +2939,8 @@ trackedFiles: pristine_git_object: 9d15a17c5b7d2ad36576248a25f4654be57e8a41 src/glean/api_client/indexing_shortcuts.py: id: e833440cda56 - last_write_checksum: sha1:e12d99068af22340af922a97613038e2b3b766b2 - pristine_git_object: c626afd01ac57966ee38c29c341fc36226e6530c + last_write_checksum: sha1:400fbc9fb0b6082f917535d4e12586978d77e54f + pristine_git_object: f727690335cf036e861efe5dfc303530161733aa src/glean/api_client/insights.py: id: 4c5708d15234 last_write_checksum: sha1:3b4e64f47612d7d2766447b998a7e7ab4bbf857b @@ -3711,8 +3711,8 @@ trackedFiles: pristine_git_object: 6825bbb05b8da91f0aca07bf2520d9862afff2c9 src/glean/api_client/models/documentspec_union.py: id: 9b7e01401389 - last_write_checksum: sha1:3468c91bf86df1225779ce22a465f35ee2fad8cf - pristine_git_object: bad1222f53682be8f494f78cc15206f71240467e + last_write_checksum: sha1:f5c1033883dda0be3207cf6d09cd72f5ed02b2a1 + pristine_git_object: 82e3e53590ac4cb4047a89dc85e04656bc5280ed src/glean/api_client/models/documentstatusresponse.py: id: 03c5597a3ee0 last_write_checksum: sha1:6fa0c35f03862802e908f0ff16c1b93d09b42286 @@ -3879,16 +3879,16 @@ trackedFiles: pristine_git_object: 44041cb376d89949c815ea1e7813505940605855 src/glean/api_client/models/feedentry.py: id: 023eb6c10ae1 - last_write_checksum: sha1:32e91f30aafb99bf2a6e8a68c7a49aa43caec1d5 - pristine_git_object: 3f4b7f857f31c8be31c496bff774538f9a54aa14 + last_write_checksum: sha1:3e15b90e8410b4480a1d12514d37e4b0c8d2a79d + pristine_git_object: cec9f210e41dee0635ae103375b648352b1f8c44 src/glean/api_client/models/feedop.py: id: b8067ac0a127 last_write_checksum: sha1:c58cb0a3a01925eb14d84176c5c6e9d8f4d84cf1 pristine_git_object: f39626285f84630e5a9233736d652914b759d44b src/glean/api_client/models/feedrequest.py: id: 33496b6a5bab - last_write_checksum: sha1:c5aa779cfb334e7f00a0df6409702fd93c78627c - pristine_git_object: 59ede102b8af89474370660417f8f588c9e57d73 + last_write_checksum: sha1:60a53b71711257c59e75eff14db94945c7c85f8f + pristine_git_object: 0362ce883b3d1479568f6e6f75918055e6b61d08 src/glean/api_client/models/feedrequestoptions.py: id: b99003fbf522 last_write_checksum: sha1:d5ffee29242075cbe6d2dd5ec916b0c3d40acf54 @@ -3899,8 +3899,8 @@ trackedFiles: pristine_git_object: 683438c837601f483526ec18756fadc7222edb24 src/glean/api_client/models/feedresult.py: id: ae187332b37a - last_write_checksum: sha1:d012a8deceff0ddea625f9d5b4b9abb721ff13b2 - pristine_git_object: f9760fde4746d8ae9008519639c5e8f0952bb38b + last_write_checksum: sha1:18a24d8a6db6ae5e6ad7286608f5f7f3fe2dde7a + pristine_git_object: 475fbb42d71fd9b8b1396c311ba6641c991a89a2 src/glean/api_client/models/followupaction.py: id: e2de5c4c8524 last_write_checksum: sha1:49e1a826449081fecfcd828c940604db949a8533 @@ -4795,8 +4795,8 @@ trackedFiles: pristine_git_object: 8b5a32ccf25fcfb0fb904e8046bf1b36110a3880 src/glean/api_client/models/ugctype.py: id: 9afda9fb9dd7 - last_write_checksum: sha1:a44b63220dbec0debcdad1383ae5f8139a073263 - pristine_git_object: d4178d3d4abe2a0268bb9f211de9f888065a4bfd + last_write_checksum: sha1:c78efcc5ea286c48e849b1a91ed86cb55bd6aa7d + pristine_git_object: 5b529907922ba1e3119d6a29498701d86d1709be src/glean/api_client/models/unauthorizeddatasourceinstance.py: id: d3507c78b8df last_write_checksum: sha1:e86e33256eecf3766c2cc9fedeab56e34e0f129c @@ -5055,8 +5055,8 @@ trackedFiles: pristine_git_object: 6a16fe3e1046ea9ed0ddd098f8d67cd5084f5bb0 src/glean/api_client/utils/metadata.py: id: 3fc71f405e83 - last_write_checksum: sha1:c6a560bd0c63ab158582f34dadb69433ea73b3d4 - pristine_git_object: 173b3e5ce658675c2f504222a56b3daaaa68107d + last_write_checksum: sha1:e703e5cbb5255144aacf86898d1420529afaaff8 + pristine_git_object: 5abddd588837ac297050ca3b543627faadb350a9 src/glean/api_client/utils/queryparams.py: id: 481cbc2ea6b0 last_write_checksum: sha1:b94c3f314fd3da0d1d215afc2731f48748e2aa59 @@ -5071,12 +5071,12 @@ trackedFiles: pristine_git_object: af07d4e941007af4213c5ec9047ef8a2fca04e5e src/glean/api_client/utils/security.py: id: 5c4255995c2c - last_write_checksum: sha1:863f4bd46af8e0e9c1756a1e394117cc9710ddb3 - pristine_git_object: e91e5a6e195e5b2b8d2ed5d901ca934bc02aa5dd + last_write_checksum: sha1:355ba142fd72ec019e46b9aadb1da7172c17a312 + pristine_git_object: 4a272f16c2af33f6364bd9aec9cdc33b91f228d2 src/glean/api_client/utils/serializers.py: id: c499367f56e9 - last_write_checksum: sha1:ce1d8d7f500a9ccba0aeca5057cee9c271f4dfd7 - pristine_git_object: 14321eb479de81d0d9580ec8291e0ff91bf29e57 + last_write_checksum: sha1:61009f2e4ef6613a1a5af813fe020373dae5a492 + pristine_git_object: d2149f8b909cb96628db140ac3cddb1b1e981367 src/glean/api_client/utils/unmarshal_json_response.py: id: 10872f2f336a last_write_checksum: sha1:8bea26e2247cd1c5b8dc60c70725ad0aed487c6d @@ -5664,7 +5664,7 @@ trackedFiles: tests/mockserver/internal/sdk/models/components/documentsection.go: last_write_checksum: sha1:a783c3824736e1d092b4d05621470c1c9b19c115 tests/mockserver/internal/sdk/models/components/documentspecunion.go: - last_write_checksum: sha1:b95d60f0479005511b0b69c914f62ee208332a3d + last_write_checksum: sha1:9133128f54aef85e913a9a4dfd2b49d8630b9b3b tests/mockserver/internal/sdk/models/components/documentstatusresponse.go: last_write_checksum: sha1:a2ff6be811eb7e72cf0b690192d94472f4d6a6ca tests/mockserver/internal/sdk/models/components/documentvisibility.go: @@ -5732,15 +5732,15 @@ trackedFiles: tests/mockserver/internal/sdk/models/components/feedbackchatexchange.go: last_write_checksum: sha1:59418d4b2dc683c810308022eade51a8894ab3b0 tests/mockserver/internal/sdk/models/components/feedentry.go: - last_write_checksum: sha1:81f9343579854c6f2ee7d9da10f94d68404d17a7 + last_write_checksum: sha1:a99ce1279f66a52476d400921e69d37abed2c283 tests/mockserver/internal/sdk/models/components/feedrequest.go: - last_write_checksum: sha1:93197353843949af3924a9014f72e4fbd4eacb9f + last_write_checksum: sha1:ee94cd67bcfc3881a07dded1fa906f058e5bc82c tests/mockserver/internal/sdk/models/components/feedrequestoptions.go: last_write_checksum: sha1:fa30b7fd6ee3e45896d7bbe36e33e7c0cb9000ba tests/mockserver/internal/sdk/models/components/feedresponse.go: last_write_checksum: sha1:f6f77be921621cf1a133463043fc1871533e2e22 tests/mockserver/internal/sdk/models/components/feedresult.go: - last_write_checksum: sha1:25fbd8a33f6bf270717eee4a75cdff6fbaa8aef2 + last_write_checksum: sha1:aca6ac6c9624912587232ca30b5fd4997b865c30 tests/mockserver/internal/sdk/models/components/followupaction.go: last_write_checksum: sha1:32a31f7af77a58ce6f3284e8550d01fcf0d3bddd tests/mockserver/internal/sdk/models/components/generatedattachment.go: @@ -6118,7 +6118,7 @@ trackedFiles: tests/mockserver/internal/sdk/models/components/toolslistresponse.go: last_write_checksum: sha1:12c38931f0f2810e038e30a743845a97b876d03c tests/mockserver/internal/sdk/models/components/ugctype.go: - last_write_checksum: sha1:7b0ad1f6e7dd12b043365d56a0728a91c87c5986 + last_write_checksum: sha1:444443b7409bfbb85d042e60888f889cc6bcf62b tests/mockserver/internal/sdk/models/components/unauthorizeddatasourceinstance.go: last_write_checksum: sha1:39fb84396b33bc645fb5e6ebcea36ab88b5db179 tests/mockserver/internal/sdk/models/components/unpin.go: @@ -6567,8 +6567,8 @@ trackedFiles: pristine_git_object: 6cc8aeec3c52329d389081db0a27f10f53f214b9 tests/test_messages.py: id: be23089b1f8b - last_write_checksum: sha1:2404e23964ef6a1f5ddc900402b34e597d2d9617 - pristine_git_object: 132005ec7d1e35f805b6a8c28e07e043bce22f0a + last_write_checksum: sha1:bef200db8e7fff0aa33ef17846f5054a2d035a88 + pristine_git_object: 36643db35a2d2a3cf9d327379ee7a6cb30da51d0 tests/test_people.py: id: 37c243940039 last_write_checksum: sha1:7c7268ffeebe48d81ed25e9b1cfc3a395abf5c1f @@ -6591,8 +6591,8 @@ trackedFiles: pristine_git_object: df2944ebda36db652b2770dd1c23be83df90fc99 tests/test_summarize.py: id: a255d8a6f627 - last_write_checksum: sha1:1b22ee51523955e50e0bbaaf6fdccd3fa4bde12c - pristine_git_object: ad6c17b97c64653b741ddbe5e4a1e3cb536a44c2 + last_write_checksum: sha1:19e1270dae90c3ebc19d93365a0613815d9e5a0e + pristine_git_object: c55cf90ad4fc6407f3a8e208dffda40fd8d45661 tests/test_tools.py: id: 70889bdf7321 last_write_checksum: sha1:3c0c220f8975b050c322f6475e95f7af4e65b995 @@ -7520,7 +7520,7 @@ generatedTests: checkdatasourceauth: "2026-02-19T15:48:52Z" getDatasourceInstanceConfiguration: "2026-03-09T18:34:29Z" updateDatasourceInstanceConfiguration: "2026-03-09T18:34:29Z" -releaseNotes: "## Python SDK Changes:\n* `glean.client.chat.create()`: \n * `request.messages[].citations[].source_file.metadata.status.enum(partially_processed)` **Added**\n * `response.messages[].citations[].source_file.metadata.status.enum(partially_processed)` **Added**\n* `glean.client.chat.retrieve()`: `response.chat_result.chat.messages[].citations[].source_file.metadata.status.enum(partially_processed)` **Added**\n* `glean.client.chat.upload_files()`: `response.files[].metadata.status.enum(partially_processed)` **Added**\n* `glean.client.chat.retrieve_files()`: `response.files.Map.metadata.status.enum(partially_processed)` **Added**\n* `glean.client.chat.create_stream()`: \n * `request.messages[].citations[].source_file.metadata.status.enum(partially_processed)` **Added**\n* `glean.indexing.documents.add_or_update()`: \n * `request.document.native_app_url` **Added**\n* `glean.indexing.documents.index()`: \n * `request.documents[].native_app_url` **Added**\n* `glean.indexing.documents.bulk_index()`: \n * `request.documents[].native_app_url` **Added**\n" +releaseNotes: "## Python SDK Changes:\n* `glean.client.announcements.create()`: \n * `request.body.structured_list[].document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.body.structured_list[].document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.announcements.update()`: \n * `request.body.structured_list[].document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.body.structured_list[].document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.answers.create()`: \n * `request.data.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.answers.update()`: \n * `request.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.answers.retrieve()`: `response.answer_result.answer.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.answers.list()`: `response.answer_results[].answer.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.chat.create()`: \n * `request.messages[].citations[].source_document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.messages[].citations[].source_document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.chat.retrieve()`: `response.chat_result.chat.created_by.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.chat.list()`: `response.chat_results[].chat.created_by.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.chat.create_stream()`: \n * `request.messages[].citations[].source_document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.collections.add_items()`: `response.collection.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.collections.create()`: \n * `request.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.union(class (0)).collection.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.collections.delete_item()`: `response.collection.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.collections.update()`: \n * `request.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.collections.update_item()`: `response.collection.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.collections.retrieve()`: `response.collection.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.collections.list()`: `response.collections[].added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.documents.retrieve()`: \n * `request.get_documents_request.document_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.documents.Map.union(Document).metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.documents.retrieve_by_facets()`: `response.documents[].metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.documents.summarize()`: \n * `request.document_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.insights.retrieve()`: `response.glean_assist.activity_insights[].user.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.messages.retrieve()`: `response.search_response.results[].structured_results[].document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.pins.update()`: `response.attribution.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.pins.retrieve()`: `response.pin.attribution.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.pins.list()`: `response.pins[].attribution.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.pins.create()`: `response.attribution.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.search.query_as_admin()`: \n * `request.source_document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.results[].structured_results[].document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.search.autocomplete()`: `response.results[].document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.search.retrieve_feed()`: \n * `request.categories[]` **Changed**\n * `response.results[]` **Changed**\n* `glean.client.search.recommendations()`: \n * `request.source_document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.results[].structured_results[].document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.search.query()`: \n * `request.source_document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.results[].structured_results[].document.metadata.author.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.entities.list()`: `response.results[].related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.entities.read_people()`: `response.results[].related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.shortcuts.create()`: \n * `request.data.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.shortcut.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.shortcuts.retrieve()`: `response.shortcut.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.shortcuts.list()`: `response.shortcuts[].added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.shortcuts.update()`: \n * `request.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n * `response.shortcut.added_roles[].source_document_spec.union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.verification.add_reminder()`: `response.metadata.last_verifier.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.verification.list()`: `response.documents[].metadata.last_verifier.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n* `glean.client.verification.verify()`: `response.metadata.last_verifier.related_documents[].query_suggestion.request_options.inclusions.container_specs[].union(class (3)).ugc_type.enum(artifacts)` **Added**\n" generatedFiles: - .devcontainer/README.md - .devcontainer/devcontainer.json diff --git a/.speakeasy/gen.yaml b/.speakeasy/gen.yaml index b1644a48..bebfd540 100644 --- a/.speakeasy/gen.yaml +++ b/.speakeasy/gen.yaml @@ -34,7 +34,7 @@ generation: generateNewTests: true skipResponseBodyAssertions: true python: - version: 0.12.18 + version: 0.12.19 additionalDependencies: dev: {} main: {} diff --git a/.speakeasy/glean-merged-spec.yaml b/.speakeasy/glean-merged-spec.yaml index 278d8295..d4d3f3e7 100644 --- a/.speakeasy/glean-merged-spec.yaml +++ b/.speakeasy/glean-merged-spec.yaml @@ -2,7 +2,7 @@ openapi: 3.0.0 info: version: 0.9.0 title: Glean API - x-source-commit-sha: 0962a428c0094dd8c0a2c12b828a1ee04b69ef00 + x-source-commit-sha: 1d7c9fce4b503a2cb087ac91ad02744ad676c97c 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. @@ -22,7 +22,7 @@ info: 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-open-api-commit-sha: da0ed02e776d66daccdd2defaabb872cd5b9cee4 + x-open-api-commit-sha: 6091976de1f81034d18ec7d40802b66d34df089a x-speakeasy-name: 'Glean API' servers: - url: https://{instance}-be.glean.com @@ -3459,7 +3459,7 @@ paths: /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. + 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://docs.glean.com/user-guide/knowledge/go-links/how-go-links-work) page. tags: - Shortcuts security: @@ -4917,6 +4917,7 @@ components: enum: - ANNOUNCEMENTS - ANSWERS + - ARTIFACTS - COLLECTIONS - SHORTCUTS - CHATS @@ -6495,6 +6496,23 @@ components: - TICKET - TRANSCRIPT - WITH + x-enum-varnames: + - ATTACHMENT + - CANONICAL + - CASE + - CONTACT_LOWERCASE + - CONTACT + - CONVERSATION_MESSAGES + - EXPERT + - FROM + - HIGHLIGHT + - OPPORTUNITY_LOWERCASE + - OPPORTUNITY + - RECENT + - SOURCE + - TICKET + - TRANSCRIPT + - WITH x-enumDescriptions: CANONICAL: Canonical documents for the entity, such as overview docs, architecture docs elastic. x-speakeasy-enum-descriptions: @@ -10134,6 +10152,10 @@ components: - MID_DAY_CATCH_UP - QUERY_SUGGESTION - WEEKLY_MEETINGS + - FOLLOW_UP + - MILESTONE_TIMELINE_CHECK + - PROJECT_DISCUSSION_DIGEST + - PROJECT_NEXT_STEP description: Categories of content requested. An allowlist gives flexibility to request content separately or together. requestOptions: $ref: "#/components/schemas/FeedRequestOptions" @@ -10465,6 +10487,7 @@ components: - PAPER_TYPE - PRISM_VIEWS_TYPE - PROMPT_TEMPLATES_TYPE + - PINS_TYPE - SCRIBES_TYPE - SHORTCUTS_TYPE - SLIDE_TYPE @@ -10635,6 +10658,10 @@ components: - MID_DAY_CATCH_UP - QUERY_SUGGESTION - WEEKLY_MEETINGS + - FOLLOW_UP + - MILESTONE_TIMELINE_CHECK + - PROJECT_DISCUSSION_DIGEST + - PROJECT_NEXT_STEP description: Type of the justification. justification: type: string @@ -10714,6 +10741,10 @@ components: - MID_DAY_CATCH_UP - QUERY_SUGGESTION - WEEKLY_MEETINGS + - FOLLOW_UP + - MILESTONE_TIMELINE_CHECK + - PROJECT_DISCUSSION_DIGEST + - PROJECT_NEXT_STEP description: Category of the result, one of the requested categories in incoming request. primaryEntry: $ref: "#/components/schemas/FeedEntry" diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index ec400895..034a2c5f 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -1,9 +1,9 @@ -speakeasyVersion: 1.759.3 +speakeasyVersion: 1.761.1 sources: Glean API: sourceNamespace: glean-api-specs - sourceRevisionDigest: sha256:1734cb8cc2eedc7ba5751830b3f320257a058953130ab965ef482396b82dbf7f - sourceBlobDigest: sha256:996519bf46dc22d2b818df15645ba6f843a3879cc8410561f5983fab6bb99f6f + sourceRevisionDigest: sha256:52aa61e876f0353862e2fc6322d35ed8c61b895083a1c0ce0f679582d72376c4 + sourceBlobDigest: sha256:65201900855c6beeca4292f578c3ee678f7278fa86372f981c2e692248f80bee tags: - latest Glean Client API: @@ -16,10 +16,10 @@ targets: glean: source: Glean API sourceNamespace: glean-api-specs - sourceRevisionDigest: sha256:1734cb8cc2eedc7ba5751830b3f320257a058953130ab965ef482396b82dbf7f - sourceBlobDigest: sha256:996519bf46dc22d2b818df15645ba6f843a3879cc8410561f5983fab6bb99f6f + sourceRevisionDigest: sha256:52aa61e876f0353862e2fc6322d35ed8c61b895083a1c0ce0f679582d72376c4 + sourceBlobDigest: sha256:65201900855c6beeca4292f578c3ee678f7278fa86372f981c2e692248f80bee codeSamplesNamespace: glean-api-specs-python-code-samples - codeSamplesRevisionDigest: sha256:c955fa0218781c3e4fc1d95d0fa51ae5051cd077ff1730432ded1238b9a40532 + codeSamplesRevisionDigest: sha256:97795efcbae3db6986718ffba511ae7bc145269ba1f5012d30d69bc48b6e5772 workflow: workflowVersion: 1.0.0 speakeasyVersion: latest diff --git a/RELEASES.md b/RELEASES.md index 02f8ccc3..8d685df2 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -688,4 +688,14 @@ Based on: ### Generated - [python v0.12.18] . ### Releases -- [PyPI v0.12.18] https://pypi.org/project/glean-api-client/0.12.18 - . \ No newline at end of file +- [PyPI v0.12.18] https://pypi.org/project/glean-api-client/0.12.18 - . + +## 2026-04-05 02:36:51 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.761.1 (2.879.6) https://github.com/speakeasy-api/speakeasy +### Generated +- [python v0.12.19] . +### Releases +- [PyPI v0.12.19] https://pypi.org/project/glean-api-client/0.12.19 - . \ No newline at end of file diff --git a/docs/models/documentspecugctype2.md b/docs/models/documentspecugctype2.md index a105173d..fea16d9d 100644 --- a/docs/models/documentspecugctype2.md +++ b/docs/models/documentspecugctype2.md @@ -19,6 +19,7 @@ value = DocumentSpecUgcType2.ANNOUNCEMENTS | --------------- | --------------- | | `ANNOUNCEMENTS` | ANNOUNCEMENTS | | `ANSWERS` | ANSWERS | +| `ARTIFACTS` | ARTIFACTS | | `COLLECTIONS` | COLLECTIONS | | `SHORTCUTS` | SHORTCUTS | | `CHATS` | CHATS | \ No newline at end of file diff --git a/docs/models/feedrequestcategory.md b/docs/models/feedrequestcategory.md index fe862685..1fb21bd0 100644 --- a/docs/models/feedrequestcategory.md +++ b/docs/models/feedrequestcategory.md @@ -44,4 +44,8 @@ value = FeedRequestCategory.DOCUMENT_SUGGESTION | `STARTER_KIT` | STARTER_KIT | | `MID_DAY_CATCH_UP` | MID_DAY_CATCH_UP | | `QUERY_SUGGESTION` | QUERY_SUGGESTION | -| `WEEKLY_MEETINGS` | WEEKLY_MEETINGS | \ No newline at end of file +| `WEEKLY_MEETINGS` | WEEKLY_MEETINGS | +| `FOLLOW_UP` | FOLLOW_UP | +| `MILESTONE_TIMELINE_CHECK` | MILESTONE_TIMELINE_CHECK | +| `PROJECT_DISCUSSION_DIGEST` | PROJECT_DISCUSSION_DIGEST | +| `PROJECT_NEXT_STEP` | PROJECT_NEXT_STEP | \ No newline at end of file diff --git a/docs/models/feedresultcategory.md b/docs/models/feedresultcategory.md index 2cf11cee..3e8ed01b 100644 --- a/docs/models/feedresultcategory.md +++ b/docs/models/feedresultcategory.md @@ -48,4 +48,8 @@ value = FeedResultCategory.DOCUMENT_SUGGESTION | `STARTER_KIT` | STARTER_KIT | | `MID_DAY_CATCH_UP` | MID_DAY_CATCH_UP | | `QUERY_SUGGESTION` | QUERY_SUGGESTION | -| `WEEKLY_MEETINGS` | WEEKLY_MEETINGS | \ No newline at end of file +| `WEEKLY_MEETINGS` | WEEKLY_MEETINGS | +| `FOLLOW_UP` | FOLLOW_UP | +| `MILESTONE_TIMELINE_CHECK` | MILESTONE_TIMELINE_CHECK | +| `PROJECT_DISCUSSION_DIGEST` | PROJECT_DISCUSSION_DIGEST | +| `PROJECT_NEXT_STEP` | PROJECT_NEXT_STEP | \ No newline at end of file diff --git a/docs/models/justificationtype.md b/docs/models/justificationtype.md index a6c62caf..156cd097 100644 --- a/docs/models/justificationtype.md +++ b/docs/models/justificationtype.md @@ -61,4 +61,8 @@ value = JustificationType.FREQUENTLY_ACCESSED | `ACTIVE_DISCUSSION` | ACTIVE_DISCUSSION | | `MID_DAY_CATCH_UP` | MID_DAY_CATCH_UP | | `QUERY_SUGGESTION` | QUERY_SUGGESTION | -| `WEEKLY_MEETINGS` | WEEKLY_MEETINGS | \ No newline at end of file +| `WEEKLY_MEETINGS` | WEEKLY_MEETINGS | +| `FOLLOW_UP` | FOLLOW_UP | +| `MILESTONE_TIMELINE_CHECK` | MILESTONE_TIMELINE_CHECK | +| `PROJECT_DISCUSSION_DIGEST` | PROJECT_DISCUSSION_DIGEST | +| `PROJECT_NEXT_STEP` | PROJECT_NEXT_STEP | \ No newline at end of file diff --git a/docs/models/ugctype.md b/docs/models/ugctype.md index 9c8c5e08..696a3117 100644 --- a/docs/models/ugctype.md +++ b/docs/models/ugctype.md @@ -27,6 +27,7 @@ value = UgcType.AGENT_TYPE | `PAPER_TYPE` | PAPER_TYPE | | `PRISM_VIEWS_TYPE` | PRISM_VIEWS_TYPE | | `PROMPT_TEMPLATES_TYPE` | PROMPT_TEMPLATES_TYPE | +| `PINS_TYPE` | PINS_TYPE | | `SCRIBES_TYPE` | SCRIBES_TYPE | | `SHORTCUTS_TYPE` | SHORTCUTS_TYPE | | `SLIDE_TYPE` | SLIDE_TYPE | diff --git a/docs/sdks/indexingshortcuts/README.md b/docs/sdks/indexingshortcuts/README.md index 02339bf7..6d8cda7a 100644 --- a/docs/sdks/indexingshortcuts/README.md +++ b/docs/sdks/indexingshortcuts/README.md @@ -9,7 +9,7 @@ ## bulk_index -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. +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://docs.glean.com/user-guide/knowledge/go-links/how-go-links-work) page. ### Example Usage diff --git a/pyproject.toml b/pyproject.toml index ef7641d7..ead28da3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ [project] name = "glean-api-client" -version = "0.12.18" +version = "0.12.19" description = "Python Client SDK Generated by Speakeasy." authors = [{ name = "Glean Technologies, Inc." },] readme = "README-PYPI.md" diff --git a/src/glean/api_client/_version.py b/src/glean/api_client/_version.py index 7585c68f..08ab8ef2 100644 --- a/src/glean/api_client/_version.py +++ b/src/glean/api_client/_version.py @@ -3,10 +3,10 @@ import importlib.metadata __title__: str = "glean-api-client" -__version__: str = "0.12.18" +__version__: str = "0.12.19" __openapi_doc_version__: str = "0.9.0" -__gen_version__: str = "2.869.25" -__user_agent__: str = "speakeasy-sdk/python 0.12.18 2.869.25 0.9.0 glean-api-client" +__gen_version__: str = "2.879.6" +__user_agent__: str = "speakeasy-sdk/python 0.12.19 2.879.6 0.9.0 glean-api-client" try: if __package__ is not None: diff --git a/src/glean/api_client/basesdk.py b/src/glean/api_client/basesdk.py index dec3e125..e4482493 100644 --- a/src/glean/api_client/basesdk.py +++ b/src/glean/api_client/basesdk.py @@ -66,6 +66,7 @@ def _build_request_async( url_override: Optional[str] = None, http_headers: Optional[Mapping[str, str]] = None, allow_empty_value: Optional[List[str]] = None, + allowed_fields: Optional[List[str]] = None, ) -> httpx.Request: client = self.sdk_configuration.async_client return self._build_request_with_client( @@ -87,6 +88,7 @@ def _build_request_async( url_override, http_headers, allow_empty_value, + allowed_fields, ) def _build_request( @@ -110,6 +112,7 @@ def _build_request( url_override: Optional[str] = None, http_headers: Optional[Mapping[str, str]] = None, allow_empty_value: Optional[List[str]] = None, + allowed_fields: Optional[List[str]] = None, ) -> httpx.Request: client = self.sdk_configuration.client return self._build_request_with_client( @@ -131,6 +134,7 @@ def _build_request( url_override, http_headers, allow_empty_value, + allowed_fields, ) def _build_request_with_client( @@ -155,6 +159,7 @@ def _build_request_with_client( url_override: Optional[str] = None, http_headers: Optional[Mapping[str, str]] = None, allow_empty_value: Optional[List[str]] = None, + allowed_fields: Optional[List[str]] = None, ) -> httpx.Request: query_params = {} @@ -188,7 +193,9 @@ def _build_request_with_client( security = security() security = utils.get_security_from_env(security, models.Security) if security is not None: - security_headers, security_query_params = utils.get_security(security) + security_headers, security_query_params = utils.get_security( + security, allowed_fields + ) headers = {**headers, **security_headers} query_params = {**query_params, **security_query_params} diff --git a/src/glean/api_client/indexing_shortcuts.py b/src/glean/api_client/indexing_shortcuts.py index c626afd0..f7276903 100644 --- a/src/glean/api_client/indexing_shortcuts.py +++ b/src/glean/api_client/indexing_shortcuts.py @@ -26,7 +26,7 @@ def bulk_index( ): r"""Bulk index external shortcuts - 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. + 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://docs.glean.com/user-guide/knowledge/go-links/how-go-links-work) page. :param upload_id: Unique id that must be used for this bulk upload instance :param shortcuts: Batch of shortcuts information @@ -129,7 +129,7 @@ async def bulk_index_async( ): r"""Bulk index external shortcuts - 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. + 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://docs.glean.com/user-guide/knowledge/go-links/how-go-links-work) page. :param upload_id: Unique id that must be used for this bulk upload instance :param shortcuts: Batch of shortcuts information diff --git a/src/glean/api_client/models/documentspec_union.py b/src/glean/api_client/models/documentspec_union.py index bad1222f..82e3e535 100644 --- a/src/glean/api_client/models/documentspec_union.py +++ b/src/glean/api_client/models/documentspec_union.py @@ -15,6 +15,7 @@ class DocumentSpecUgcType2(str, Enum, metaclass=utils.OpenEnumMeta): ANNOUNCEMENTS = "ANNOUNCEMENTS" ANSWERS = "ANSWERS" + ARTIFACTS = "ARTIFACTS" COLLECTIONS = "COLLECTIONS" SHORTCUTS = "SHORTCUTS" CHATS = "CHATS" diff --git a/src/glean/api_client/models/feedentry.py b/src/glean/api_client/models/feedentry.py index 3f4b7f85..cec9f210 100644 --- a/src/glean/api_client/models/feedentry.py +++ b/src/glean/api_client/models/feedentry.py @@ -115,6 +115,10 @@ class JustificationType(str, Enum, metaclass=utils.OpenEnumMeta): MID_DAY_CATCH_UP = "MID_DAY_CATCH_UP" QUERY_SUGGESTION = "QUERY_SUGGESTION" WEEKLY_MEETINGS = "WEEKLY_MEETINGS" + FOLLOW_UP = "FOLLOW_UP" + MILESTONE_TIMELINE_CHECK = "MILESTONE_TIMELINE_CHECK" + PROJECT_DISCUSSION_DIGEST = "PROJECT_DISCUSSION_DIGEST" + PROJECT_NEXT_STEP = "PROJECT_NEXT_STEP" class FeedEntryTypedDict(TypedDict): diff --git a/src/glean/api_client/models/feedrequest.py b/src/glean/api_client/models/feedrequest.py index 59ede102..0362ce88 100644 --- a/src/glean/api_client/models/feedrequest.py +++ b/src/glean/api_client/models/feedrequest.py @@ -44,6 +44,10 @@ class FeedRequestCategory(str, Enum): MID_DAY_CATCH_UP = "MID_DAY_CATCH_UP" QUERY_SUGGESTION = "QUERY_SUGGESTION" WEEKLY_MEETINGS = "WEEKLY_MEETINGS" + FOLLOW_UP = "FOLLOW_UP" + MILESTONE_TIMELINE_CHECK = "MILESTONE_TIMELINE_CHECK" + PROJECT_DISCUSSION_DIGEST = "PROJECT_DISCUSSION_DIGEST" + PROJECT_NEXT_STEP = "PROJECT_NEXT_STEP" class FeedRequestTypedDict(TypedDict): diff --git a/src/glean/api_client/models/feedresult.py b/src/glean/api_client/models/feedresult.py index f9760fde..475fbb42 100644 --- a/src/glean/api_client/models/feedresult.py +++ b/src/glean/api_client/models/feedresult.py @@ -46,6 +46,10 @@ class FeedResultCategory(str, Enum, metaclass=utils.OpenEnumMeta): MID_DAY_CATCH_UP = "MID_DAY_CATCH_UP" QUERY_SUGGESTION = "QUERY_SUGGESTION" WEEKLY_MEETINGS = "WEEKLY_MEETINGS" + FOLLOW_UP = "FOLLOW_UP" + MILESTONE_TIMELINE_CHECK = "MILESTONE_TIMELINE_CHECK" + PROJECT_DISCUSSION_DIGEST = "PROJECT_DISCUSSION_DIGEST" + PROJECT_NEXT_STEP = "PROJECT_NEXT_STEP" class FeedResultTypedDict(TypedDict): diff --git a/src/glean/api_client/models/ugctype.py b/src/glean/api_client/models/ugctype.py index d4178d3d..5b529907 100644 --- a/src/glean/api_client/models/ugctype.py +++ b/src/glean/api_client/models/ugctype.py @@ -18,6 +18,7 @@ class UgcType(str, Enum, metaclass=utils.OpenEnumMeta): PAPER_TYPE = "PAPER_TYPE" PRISM_VIEWS_TYPE = "PRISM_VIEWS_TYPE" PROMPT_TEMPLATES_TYPE = "PROMPT_TEMPLATES_TYPE" + PINS_TYPE = "PINS_TYPE" SCRIBES_TYPE = "SCRIBES_TYPE" SHORTCUTS_TYPE = "SHORTCUTS_TYPE" SLIDE_TYPE = "SLIDE_TYPE" diff --git a/src/glean/api_client/utils/metadata.py b/src/glean/api_client/utils/metadata.py index 173b3e5c..5abddd58 100644 --- a/src/glean/api_client/utils/metadata.py +++ b/src/glean/api_client/utils/metadata.py @@ -15,6 +15,7 @@ class SecurityMetadata: scheme_type: Optional[str] = None sub_type: Optional[str] = None field_name: Optional[str] = None + composite: bool = False def get_field_name(self, default: str) -> str: return self.field_name or default diff --git a/src/glean/api_client/utils/security.py b/src/glean/api_client/utils/security.py index e91e5a6e..4a272f16 100644 --- a/src/glean/api_client/utils/security.py +++ b/src/glean/api_client/utils/security.py @@ -19,7 +19,9 @@ import os -def get_security(security: Any) -> Tuple[Dict[str, str], Dict[str, List[str]]]: +def get_security( + security: Any, allowed_fields: Optional[List[str]] = None +) -> Tuple[Dict[str, str], Dict[str, List[str]]]: headers: Dict[str, str] = {} query_params: Dict[str, List[str]] = {} @@ -30,7 +32,14 @@ def get_security(security: Any) -> Tuple[Dict[str, str], Dict[str, List[str]]]: raise TypeError("security must be a pydantic model") sec_fields: Dict[str, FieldInfo] = security.__class__.model_fields - for name in sec_fields: + sec_field_names = ( + list(sec_fields.keys()) if allowed_fields is None else allowed_fields + ) + + for name in sec_field_names: + if name not in sec_fields: + continue + sec_field = sec_fields[name] value = getattr(security, name) @@ -52,6 +61,9 @@ def get_security(security: Any) -> Tuple[Dict[str, str], Dict[str, List[str]]]: else: _parse_security_scheme(headers, query_params, metadata, name, value) + if not metadata.composite: + return headers, query_params + return headers, query_params @@ -77,15 +89,24 @@ def _parse_security_option( raise TypeError("security option must be a pydantic model") opt_fields: Dict[str, FieldInfo] = option.__class__.model_fields + for name in opt_fields: opt_field = opt_fields[name] metadata = find_field_metadata(opt_field, SecurityMetadata) if metadata is None or not metadata.scheme: continue - _parse_security_scheme( - headers, query_params, metadata, name, getattr(option, name) - ) + + value = getattr(option, name) + if ( + metadata.scheme_type == "http" + and metadata.sub_type == "basic" + and not isinstance(value, BaseModel) + ): + _parse_basic_auth_scheme(headers, option) + return + + _parse_security_scheme(headers, query_params, metadata, name, value) def _parse_security_scheme( diff --git a/src/glean/api_client/utils/serializers.py b/src/glean/api_client/utils/serializers.py index 14321eb4..d2149f8b 100644 --- a/src/glean/api_client/utils/serializers.py +++ b/src/glean/api_client/utils/serializers.py @@ -17,8 +17,7 @@ def serialize_decimal(as_str: bool): def serialize(d): - # Optional[T] is a Union[T, None] - if is_union(type(d)) and type(None) in get_args(type(d)) and d is None: + if d is None: return None if isinstance(d, Unset): return d @@ -46,8 +45,7 @@ def validate_decimal(d): def serialize_float(as_str: bool): def serialize(f): - # Optional[T] is a Union[T, None] - if is_union(type(f)) and type(None) in get_args(type(f)) and f is None: + if f is None: return None if isinstance(f, Unset): return f @@ -75,8 +73,7 @@ def validate_float(f): def serialize_int(as_str: bool): def serialize(i): - # Optional[T] is a Union[T, None] - if is_union(type(i)) and type(None) in get_args(type(i)) and i is None: + if i is None: return None if isinstance(i, Unset): return i @@ -104,8 +101,7 @@ def validate_int(b): def validate_const(v): def validate(c): - # Optional[T] is a Union[T, None] - if is_union(type(c)) and type(None) in get_args(type(c)) and c is None: + if c is None: return None if v != c: diff --git a/tests/mockserver/internal/sdk/models/components/documentspecunion.go b/tests/mockserver/internal/sdk/models/components/documentspecunion.go index e6206deb..87e6ac59 100644 --- a/tests/mockserver/internal/sdk/models/components/documentspecunion.go +++ b/tests/mockserver/internal/sdk/models/components/documentspecunion.go @@ -15,6 +15,7 @@ type DocumentSpecUgcType2 string const ( DocumentSpecUgcType2Announcements DocumentSpecUgcType2 = "ANNOUNCEMENTS" DocumentSpecUgcType2Answers DocumentSpecUgcType2 = "ANSWERS" + DocumentSpecUgcType2Artifacts DocumentSpecUgcType2 = "ARTIFACTS" DocumentSpecUgcType2Collections DocumentSpecUgcType2 = "COLLECTIONS" DocumentSpecUgcType2Shortcuts DocumentSpecUgcType2 = "SHORTCUTS" DocumentSpecUgcType2Chats DocumentSpecUgcType2 = "CHATS" @@ -33,6 +34,8 @@ func (e *DocumentSpecUgcType2) UnmarshalJSON(data []byte) error { fallthrough case "ANSWERS": fallthrough + case "ARTIFACTS": + fallthrough case "COLLECTIONS": fallthrough case "SHORTCUTS": diff --git a/tests/mockserver/internal/sdk/models/components/feedentry.go b/tests/mockserver/internal/sdk/models/components/feedentry.go index 0b1ab21b..af0239e8 100644 --- a/tests/mockserver/internal/sdk/models/components/feedentry.go +++ b/tests/mockserver/internal/sdk/models/components/feedentry.go @@ -101,6 +101,10 @@ const ( JustificationTypeMidDayCatchUp JustificationType = "MID_DAY_CATCH_UP" JustificationTypeQuerySuggestion JustificationType = "QUERY_SUGGESTION" JustificationTypeWeeklyMeetings JustificationType = "WEEKLY_MEETINGS" + JustificationTypeFollowUp JustificationType = "FOLLOW_UP" + JustificationTypeMilestoneTimelineCheck JustificationType = "MILESTONE_TIMELINE_CHECK" + JustificationTypeProjectDiscussionDigest JustificationType = "PROJECT_DISCUSSION_DIGEST" + JustificationTypeProjectNextStep JustificationType = "PROJECT_NEXT_STEP" ) func (e JustificationType) ToPointer() *JustificationType { @@ -201,6 +205,14 @@ func (e *JustificationType) UnmarshalJSON(data []byte) error { case "QUERY_SUGGESTION": fallthrough case "WEEKLY_MEETINGS": + fallthrough + case "FOLLOW_UP": + fallthrough + case "MILESTONE_TIMELINE_CHECK": + fallthrough + case "PROJECT_DISCUSSION_DIGEST": + fallthrough + case "PROJECT_NEXT_STEP": *e = JustificationType(v) return nil default: diff --git a/tests/mockserver/internal/sdk/models/components/feedrequest.go b/tests/mockserver/internal/sdk/models/components/feedrequest.go index 498137f1..50f12942 100644 --- a/tests/mockserver/internal/sdk/models/components/feedrequest.go +++ b/tests/mockserver/internal/sdk/models/components/feedrequest.go @@ -42,6 +42,10 @@ const ( FeedRequestCategoryMidDayCatchUp FeedRequestCategory = "MID_DAY_CATCH_UP" FeedRequestCategoryQuerySuggestion FeedRequestCategory = "QUERY_SUGGESTION" FeedRequestCategoryWeeklyMeetings FeedRequestCategory = "WEEKLY_MEETINGS" + FeedRequestCategoryFollowUp FeedRequestCategory = "FOLLOW_UP" + FeedRequestCategoryMilestoneTimelineCheck FeedRequestCategory = "MILESTONE_TIMELINE_CHECK" + FeedRequestCategoryProjectDiscussionDigest FeedRequestCategory = "PROJECT_DISCUSSION_DIGEST" + FeedRequestCategoryProjectNextStep FeedRequestCategory = "PROJECT_NEXT_STEP" ) func (e FeedRequestCategory) ToPointer() *FeedRequestCategory { @@ -116,6 +120,14 @@ func (e *FeedRequestCategory) UnmarshalJSON(data []byte) error { case "QUERY_SUGGESTION": fallthrough case "WEEKLY_MEETINGS": + fallthrough + case "FOLLOW_UP": + fallthrough + case "MILESTONE_TIMELINE_CHECK": + fallthrough + case "PROJECT_DISCUSSION_DIGEST": + fallthrough + case "PROJECT_NEXT_STEP": *e = FeedRequestCategory(v) return nil default: diff --git a/tests/mockserver/internal/sdk/models/components/feedresult.go b/tests/mockserver/internal/sdk/models/components/feedresult.go index 5da316a2..55bc99d4 100644 --- a/tests/mockserver/internal/sdk/models/components/feedresult.go +++ b/tests/mockserver/internal/sdk/models/components/feedresult.go @@ -43,6 +43,10 @@ const ( FeedResultCategoryMidDayCatchUp FeedResultCategory = "MID_DAY_CATCH_UP" FeedResultCategoryQuerySuggestion FeedResultCategory = "QUERY_SUGGESTION" FeedResultCategoryWeeklyMeetings FeedResultCategory = "WEEKLY_MEETINGS" + FeedResultCategoryFollowUp FeedResultCategory = "FOLLOW_UP" + FeedResultCategoryMilestoneTimelineCheck FeedResultCategory = "MILESTONE_TIMELINE_CHECK" + FeedResultCategoryProjectDiscussionDigest FeedResultCategory = "PROJECT_DISCUSSION_DIGEST" + FeedResultCategoryProjectNextStep FeedResultCategory = "PROJECT_NEXT_STEP" ) func (e FeedResultCategory) ToPointer() *FeedResultCategory { @@ -117,6 +121,14 @@ func (e *FeedResultCategory) UnmarshalJSON(data []byte) error { case "QUERY_SUGGESTION": fallthrough case "WEEKLY_MEETINGS": + fallthrough + case "FOLLOW_UP": + fallthrough + case "MILESTONE_TIMELINE_CHECK": + fallthrough + case "PROJECT_DISCUSSION_DIGEST": + fallthrough + case "PROJECT_NEXT_STEP": *e = FeedResultCategory(v) return nil default: diff --git a/tests/mockserver/internal/sdk/models/components/ugctype.go b/tests/mockserver/internal/sdk/models/components/ugctype.go index 7de61de5..96a1c420 100644 --- a/tests/mockserver/internal/sdk/models/components/ugctype.go +++ b/tests/mockserver/internal/sdk/models/components/ugctype.go @@ -22,6 +22,7 @@ const ( UgcTypePaperType UgcType = "PAPER_TYPE" UgcTypePrismViewsType UgcType = "PRISM_VIEWS_TYPE" UgcTypePromptTemplatesType UgcType = "PROMPT_TEMPLATES_TYPE" + UgcTypePinsType UgcType = "PINS_TYPE" UgcTypeScribesType UgcType = "SCRIBES_TYPE" UgcTypeShortcutsType UgcType = "SHORTCUTS_TYPE" UgcTypeSlideType UgcType = "SLIDE_TYPE" @@ -61,6 +62,8 @@ func (e *UgcType) UnmarshalJSON(data []byte) error { fallthrough case "PROMPT_TEMPLATES_TYPE": fallthrough + case "PINS_TYPE": + fallthrough case "SCRIBES_TYPE": fallthrough case "SHORTCUTS_TYPE": diff --git a/tests/test_messages.py b/tests/test_messages.py index 132005ec..36643db3 100644 --- a/tests/test_messages.py +++ b/tests/test_messages.py @@ -18,7 +18,7 @@ def test_messages_messages(): res = glean.client.messages.retrieve( id_type=models.IDType.CONVERSATION_ID, id="", - datasource=models.Datasource.FACEBOOKWORKPLACE, + datasource=models.Datasource.MICROSOFTTEAMS, timestamp_millis=558834, ) assert res is not None diff --git a/tests/test_summarize.py b/tests/test_summarize.py index ad6c17b9..c55cf90a 100644 --- a/tests/test_summarize.py +++ b/tests/test_summarize.py @@ -18,11 +18,12 @@ def test_summarize_summarize(): res = glean.client.documents.summarize( document_specs=[ { - "id": "", + "ugc_type": models.DocumentSpecUgcType2.ANNOUNCEMENTS, + "ugc_id": "", }, { - "ugc_type": models.DocumentSpecUgcType2.ANSWERS, - "ugc_id": "", + "ugc_type": models.DocumentSpecUgcType1.COLLECTIONS, + "content_id": 337360, }, ] )