diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock index 34e6b42c..df5c2d3f 100644 --- a/.speakeasy/gen.lock +++ b/.speakeasy/gen.lock @@ -1,19 +1,19 @@ lockVersion: 2.0.0 id: 3e3290ca-0ee8-4981-b1bc-14536048fa63 management: - docChecksum: 1974948f3cdb42c18f515f1fb0fea2dd + docChecksum: ee16bca05d3e652c444700568aef3727 docVersion: 0.9.0 - speakeasyVersion: 1.798.0 - generationVersion: 2.938.0 - releaseVersion: 0.17.15 - configChecksum: 1eb09757dc51c042e574b3e04826405c + speakeasyVersion: 1.800.0 + generationVersion: 2.943.0 + releaseVersion: 0.17.16 + configChecksum: bb68bec00fef7c965d2f40018b352432 repoURL: https://github.com/gleanwork/api-client-python.git installationURL: https://github.com/gleanwork/api-client-python.git published: true persistentEdits: - generation_id: 0c37b6b6-f498-4b35-9e48-b8cd9f4e6e68 - pristine_commit_hash: 2d2188952a3c1654eddee8b4920d6bdfb1418125 - pristine_tree_hash: 13f0956d61751a52fa8e0a390b15b03ef90cc4c3 + generation_id: 371ec297-a013-45b6-be5c-ca1e803b3a31 + pristine_commit_hash: 6cb25035302988d3cb059247a2de2929865889c9 + pristine_tree_hash: 05d242a62452f2d692e417ec8c9088df4c156a74 features: python: acceptHeaders: 3.0.0 @@ -22,7 +22,7 @@ features: callbacks: 2.0.0 configurableModuleName: 0.2.0 constsAndDefaults: 1.0.8 - core: 6.1.2 + core: 6.1.3 defaultEnabledRetries: 0.2.0 deprecations: 3.0.2 devContainers: 3.0.0 @@ -49,7 +49,7 @@ features: sdkHooks: 1.3.0 serverEvents: 1.1.1 tests: 1.19.10 - unions: 3.1.10 + unions: 3.1.12 uploadStreams: 1.0.3 trackedFiles: .devcontainer/README.md: @@ -312,6 +312,10 @@ trackedFiles: id: 333a2b7c460c last_write_checksum: sha1:f9779ac516afac0d0cab5f0a9e4993b5e305f413 pristine_git_object: b1d37dea76990544293f38221b2314739c22ffaa + docs/models/artifacttype.md: + id: 87a23e4dd4a6 + last_write_checksum: sha1:c8b0a1dda1ced0e79877c2da435092e96dc6eed0 + pristine_git_object: acd892d2857ac59d4a3b285aea1465b86b6290d5 docs/models/assistantinsightsresponse.md: id: 4da438a09c8e last_write_checksum: sha1:79953a586b4b90fa67d44c370271de068b3d49f3 @@ -386,8 +390,8 @@ trackedFiles: pristine_git_object: f52bd9ee886df0323f70d1416c7f567beee45fe9 docs/models/autocompleterequestresulttype.md: id: b8d90b50b8a1 - last_write_checksum: sha1:384db0e85ba2259d36c469bf18aad238ce221de9 - pristine_git_object: 1133a59c5d24f501ea467fb19e9a467682cd9d31 + last_write_checksum: sha1:6a466170ae65f1bb77a34ffa577050a3c677731f + pristine_git_object: d5efb95f03562827c2bfafe0984c098e2e3de5fb docs/models/autocompleteresponse.md: id: a8f4f0d2e960 last_write_checksum: sha1:e80e1ab5896798594c21df4361f9c5711f55d8d0 @@ -410,8 +414,8 @@ trackedFiles: pristine_git_object: 06cf46df1c5e8e897928c57585c307b386f4aefb docs/models/breakdowntype.md: id: 852d76343384 - last_write_checksum: sha1:fb3820973b2df634462475d5bed0b75cc09dfa09 - pristine_git_object: dbe3672757339f9ecbbb904f50a7ba5924ee4a43 + last_write_checksum: sha1:06b46b101ae37486143ca7695cbdf4cf58a4aac4 + pristine_git_object: 6e84b1a558f9dbe590947596b2e4c20e27b75ac0 docs/models/bulkindexdocumentsrequest.md: id: ea279e5855b8 last_write_checksum: sha1:4ae80ed6fa8146e90de4818a30d46af50e9affaa @@ -452,6 +456,10 @@ trackedFiles: id: 7d8688a5dbf6 last_write_checksum: sha1:70739badd105665d19482017bc8f7386fe454837 pristine_git_object: be38317813e3a9f663bffa698617775fd3a41d49 + docs/models/businessjustification.md: + id: b2f5ff81af08 + last_write_checksum: sha1:a10717c06d1cad927498453612d47e9eeb382bf8 + pristine_git_object: 9777ff875897cbd94a97e0700c365e5275a6f976 docs/models/calendarattendee.md: id: 65658df6d5ed last_write_checksum: sha1:95c9c7713d8dd0387c417133e10f3e8fc015738e @@ -614,8 +622,8 @@ trackedFiles: pristine_git_object: f04f0b8f01b063f1b3cb838e55a093880cf94693 docs/models/chatsuggestion.md: id: ed9377964a1e - last_write_checksum: sha1:ec415c7f0e372089f398ba9425cd64cce9e2b527 - pristine_git_object: e18aae7ba79f1f9c0d9a9b302f15ce4b1b1a8aac + last_write_checksum: sha1:7ada8e17261e02ef1e1fe234dc2c36848e723fd9 + pristine_git_object: c84fee735607ca08e73e1ad74b970db8f26152e8 docs/models/chatzerostatesuggestionoptions.md: id: 93484e4440f7 last_write_checksum: sha1:70ab46266394ffd387991ec7036aa7e12346d278 @@ -1482,8 +1490,8 @@ trackedFiles: pristine_git_object: a851a7f13eb25d515fa9b9244c5dfdc98fa14e2c docs/models/feedrequestcategory.md: id: 31a02f3064c7 - last_write_checksum: sha1:6c058c44c4c9cc02dd16dbf222a4576348789c0f - pristine_git_object: 662a836bc9b99d7fe65d08ba4280adcacf0aa096 + last_write_checksum: sha1:b69724904c42305546a082816a92a697919c7d23 + pristine_git_object: 35f342f96b9b40c54e5ffc181c174a83a1eaba50 docs/models/feedrequestoptions.md: id: 58eb26b19e77 last_write_checksum: sha1:fd2ab08736cef8156169b0cfee8c52e7aed1accf @@ -1502,8 +1510,8 @@ trackedFiles: pristine_git_object: f6f92abf16b61f88b527e1c906f605e98306878e docs/models/feedresultcategory.md: id: a5f77f38d0a7 - last_write_checksum: sha1:3defded05526cfd53ff95f819046e9cebaddd2b0 - pristine_git_object: b1ed34c83753598c152bc76c41196860f036262e + last_write_checksum: sha1:c67cbd5acb09f0cf187e3afe4edeb70a71c1ab35 + pristine_git_object: 591586c677c644993a9435e7bdc7c2c2d8ddd2d7 docs/models/fieldscope.md: id: e6b52bcb22a6 last_write_checksum: sha1:13a1492ce39d2f89a01d626996a345a1339a1873 @@ -1824,6 +1832,10 @@ trackedFiles: id: 322b72470576 last_write_checksum: sha1:165032455fe9dfdf7b596adbb5f01aad2c8525fd pristine_git_object: 8dfae128497ae67ba74052bed92a34d7c8a7094c + docs/models/idpgroups.md: + id: 8f0824e47bc5 + last_write_checksum: sha1:8156f597d08af77e0c51630b112ccdbd19ef6185 + pristine_git_object: 879d13aa6f69c82d2dc34e8408957c391d0b96ec docs/models/idtype.md: id: d998108e5ea8 last_write_checksum: sha1:691f92007f621c3190dd8e17e293be0852457d96 @@ -1946,8 +1958,8 @@ trackedFiles: pristine_git_object: 647f9bb67a6af30d7fd71c8ddb3c5e1bf40bb938 docs/models/justificationtype.md: id: 8286affacee4 - last_write_checksum: sha1:3cd9f468ee470bfe137224e72c46b03501e33905 - pristine_git_object: 7764769f62ea15ddd762c89e561431c2490b3edb + last_write_checksum: sha1:85183c4419216823357e0b29db3fe4e519e1e11f + pristine_git_object: 0017912af41f1eaa18634894e23d7e4014ef1078 docs/models/knowledgetype.md: id: 1e0c90679228 last_write_checksum: sha1:0030a7539b9362bbb59e0bbd36580676058b3540 @@ -2092,14 +2104,18 @@ trackedFiles: id: cf68b1f63cc7 last_write_checksum: sha1:6f62aad4e5e0583365e661548b8564d1b3c97e08 pristine_git_object: ba4cf618261dec6b6829099ec1760a6fd48bce10 + docs/models/mcpauthmethodbreakdown.md: + id: c7a9bf160968 + last_write_checksum: sha1:622f054e98722e645ba04b5d394480272fdcd5cd + pristine_git_object: bcdeb6cc5ac1e7aea7f46505ca15c6071888376d docs/models/mcpbreakdowninsightsrequest.md: id: 8c3c8a81e52f - last_write_checksum: sha1:1aa64aa623e6a963d57251261f28e38050922509 - pristine_git_object: dfc799474ee77c7a1086e51067bcf7a2b71c3fd2 + last_write_checksum: sha1:08fd1f9c6173c1b9f320a1f1c79a7db34aa77985 + pristine_git_object: 88e0fb3939cb2ab16bc8ab8b7a37deabde7f2fc1 docs/models/mcpbreakdowninsightsresponse.md: id: cdfee60eb6f4 - last_write_checksum: sha1:c1381c087e140760b2896d1ccc047cae26b596dc - pristine_git_object: 94328ff46f865baafc8a3470bbc03119d8b5b135 + last_write_checksum: sha1:624633c29fe6ebd03bfaa98053bc2b5fc811525b + pristine_git_object: 95f06445834cc6d632867b0e4aef21a0b10a7a3a docs/models/mcphostapplicationbreakdown.md: id: 7dbd2599b33b last_write_checksum: sha1:bbb736a2752cec78704d81935408318ee3381236 @@ -2122,8 +2138,8 @@ trackedFiles: pristine_git_object: 8eade3001193f86363e036f448148ca22d6e3758 docs/models/mcpuserbreakdown.md: id: 5a038100c9e2 - last_write_checksum: sha1:a642b877609d2765fe27b945fdaff8efc9853a8b - pristine_git_object: 1c4e22ef0d97f24e0b593d2080d123e7ce75b5d4 + last_write_checksum: sha1:4ac6db5b751febe217a71574ca0b44bf38170e95 + pristine_git_object: 09e90b950c22f758657c3d8dffd1b8155df88e44 docs/models/meeting.md: id: 823ab6288010 last_write_checksum: sha1:9efd1c28c84b767ea662cd26598364b032e35cf3 @@ -2172,6 +2188,10 @@ trackedFiles: id: b594dcf5417b last_write_checksum: sha1:6caf5827d4da2f9279f733ab063c489f24e27551 pristine_git_object: 75f9ddbbb057b5d4d011999825023254b3ee9ea8 + docs/models/operator.md: + id: 1b6d3fc58add + last_write_checksum: sha1:89f61c035282fc72fe3697621201a481f488bc2d + pristine_git_object: 0d0841761b03e06c7168e4ead36699afad5379e4 docs/models/operatormetadata.md: id: bb1b8522afc0 last_write_checksum: sha1:decaa2a1d74557b3011a3b6b778059482fce2846 @@ -2194,8 +2214,8 @@ trackedFiles: pristine_git_object: 4555c0106ca95de3c4ff40e7d2ec703506c30450 docs/models/peoplerequest.md: id: a2efd0c61878 - last_write_checksum: sha1:6d1ac4de80b9014019ead9c45dc74d6635be315f - pristine_git_object: cabbe6e5060ca81606726370df1d3cfeffee879f + last_write_checksum: sha1:35157d922bf4a512faa9e98f15cd5c5a3302fbb7 + pristine_git_object: 66af83b5b38f3321aea1bf2b7f71e6110b5c7fd8 docs/models/peoplerequestincludefield.md: id: 1cc1f2177bbd last_write_checksum: sha1:a02e302ceae15bdcd65b89c04a3d67252d95653b @@ -2226,8 +2246,8 @@ trackedFiles: pristine_git_object: 5d2835e91400f8c721cd32ac9c4ad0c2d4dff668 docs/models/person.md: id: 3b0ea6e43010 - last_write_checksum: sha1:c41a10861d5f427cfbdd80b81afbf201a43b3d51 - pristine_git_object: 233784bcf7eca5260994f7a48190e2207a6d6742 + last_write_checksum: sha1:48e57bd344ebad9f78e85d32dc2108412275e845 + pristine_git_object: e9846658ab15d8de3629fb55d1266a96824c983a docs/models/persondistance.md: id: 26300c30163c last_write_checksum: sha1:37d6ba089ac53d0338b6e7f5e00d343adcc05317 @@ -2288,6 +2308,14 @@ trackedFiles: id: 66630faec49a last_write_checksum: sha1:918357358bb6dd6840b6ef69e9bbfc05620f3eda pristine_git_object: 4a911ee3b51a89c0a847cc6984af2b01448edc73 + docs/models/platformadminusagerequestsgetrequest.md: + id: e1f007172282 + last_write_checksum: sha1:6b0d3abfb8eb6b5250b5421e3286896811890542 + pristine_git_object: aad4e248c560a5923917d815649ac9f9d36820cf + docs/models/platformadminusagerequestslistrequest.md: + id: e39f6b3260fa + last_write_checksum: sha1:e2b1adb3e4fe0cbcedb46701f20e3fab1fe63c77 + pristine_git_object: 7fda9d91b5054d573ccd7cb0b04de3d1371fd350 docs/models/platformagent.md: id: 6d684a308415 last_write_checksum: sha1:0f0c8b393957aebe795e3a7a142dffa1c65354a0 @@ -2304,6 +2332,10 @@ trackedFiles: id: 18c7f4c9c735 last_write_checksum: sha1:44a241668a240ee78a4c7bb6a85daf8cb4624121 pristine_git_object: be79ecee30d70d591903bd9a89e3708a670b5e20 + docs/models/platformagentrequestcreate.md: + id: ed9d870ebe90 + last_write_checksum: sha1:c324528f6bd81433abb7bf4e84cc167df4907574 + pristine_git_object: e618290b9efc1a82f26007c53aa36aa00231d019 docs/models/platformagentrun.md: id: 2b8087b0fcda last_write_checksum: sha1:a34783d31877e4a81505588767aa6e5eccf96fda @@ -2664,6 +2696,18 @@ trackedFiles: id: 459d8f60cd58 last_write_checksum: sha1:98575b0dfa32c14f341fc95490c0e2c5cace9fe8 pristine_git_object: d97b6753e2056405bec741b206680b230891c331 + docs/models/platformlimitincreaserequest.md: + id: e951619db061 + last_write_checksum: sha1:f36dc7a8b1627fd829e9338ff8ec2424d04ddca2 + pristine_git_object: a28d3bd82b32864c56bae1668498c884bf1ab09d + docs/models/platformlimitincreaserequestentitytype.md: + id: 1eb1ae768583 + last_write_checksum: sha1:b14ae7617e91bbf33b47af023a498d41bae7a21c + pristine_git_object: 055d1a51c7a743b33397fef2e31a4ce2958425c3 + docs/models/platformlimitincreaserequestsettings.md: + id: ec78701ff8c5 + last_write_checksum: sha1:c8151be08b15115b76a95e6b23fe5a46f6eae64f + pristine_git_object: 123d3f923df78012a7fc13b4d7e0811a0e9f86c0 docs/models/platformmessage.md: id: ea30c4fdad14 last_write_checksum: sha1:890468283cb6b47c68edf4b7b241dec096699d95 @@ -2684,10 +2728,26 @@ trackedFiles: id: 84ff8f38e838 last_write_checksum: sha1:7e2cc0010d738cd1a2ce104a90299936fbe40d43 pristine_git_object: 6e3694484701e30ba1114213a8f0a287b5f4030e + docs/models/platformmultiplemembershipresolutionsettings.md: + id: be6da3fa593d + last_write_checksum: sha1:ba5d7b0094b3d87e5dd7027aa4c839b85a64b3b8 + pristine_git_object: 55ca071b39ea42f8079441f33cb488511bf16b5b + docs/models/platformpermembersettings.md: + id: eced3b49ecf2 + last_write_checksum: sha1:9b0df2e74078bfc00d0c233f6ef659094d4b8bfd + pristine_git_object: 595e8d339a9d4bb719925d0a6ff80fddb7abe948 + docs/models/platformpersonalrequestcreate.md: + id: 88de97d339b0 + last_write_checksum: sha1:2c0b24ddb3c0d3d31b0f834167bfd50786860bb8 + pristine_git_object: 6ebde8022357302ce131619a874d5a32d3a104e4 docs/models/platformpersonreference.md: id: 8e0eb24c7ab0 last_write_checksum: sha1:b7e91a102caa171583e0033985345592eded3a47 pristine_git_object: 9602adac9af14a6a401eaf90a16cdc7e7a96c954 + docs/models/platformproblemdetail.md: + id: 3eb00158d145 + last_write_checksum: sha1:582bc89cfb2012c5fddeda164929ffe4151265c9 + pristine_git_object: 95a5121d13c926d7a7e17c39607778ec83bf0738 docs/models/platformproblemdetailcode.md: id: fd61a3fb0333 last_write_checksum: sha1:a1d01a7e9ba65fba741eb7ffc7c318ec2f00a28b @@ -2696,6 +2756,38 @@ trackedFiles: id: 2e752ca0f45d last_write_checksum: sha1:250c20189f7d3163d46e0036b2a7d8867f12f788 pristine_git_object: 169944d5c3ce0c14a23f82a9c5ac30efdec24533 + docs/models/platformrequestfilter.md: + id: 09132d346c4a + last_write_checksum: sha1:976fc834c044df9a48f4d4ad6c4575b14738490c + pristine_git_object: 419b88fee8ff237d86200cf8d1159e3ed20ee1ad + docs/models/platformrequestlistresponse1.md: + id: 1ecaddb34ee2 + last_write_checksum: sha1:368dec4fe2a83d9b6dd4c9cad9c281c3840808f5 + pristine_git_object: 758fb09c4ebaa410df45025c17775742c2070579 + docs/models/platformrequestlistresponse2.md: + id: 61879eac10b0 + last_write_checksum: sha1:b4877c9bc7df50533e28a2dc02ed87d36c4f3b13 + pristine_git_object: 637f2710be71f06da687139d7ae61e14e5d5fd3c + docs/models/platformrequestlistresponseunion.md: + id: 072cda8fe293 + last_write_checksum: sha1:20542b970e63eb3ae5889006c53447d8530104f0 + pristine_git_object: 8a2cb0241b043c605910d6d3351c903f22008736 + docs/models/platformrequestresolutiontarget.md: + id: 7f4899f6d928 + last_write_checksum: sha1:da97631be8eac7999f566b5120add7a4e9514c33 + pristine_git_object: 89aef19680b7893b57cfc1ff0722c8f0d277fe7a + docs/models/platformrequestresponse.md: + id: fdd19f64d9d9 + last_write_checksum: sha1:fe40a4954a61fba53899d383c253115589dd7675 + pristine_git_object: 899f22e80edfbf535239da037f5c64ce7588d0ec + docs/models/platformrequestscope.md: + id: fa2f1d95f8f1 + last_write_checksum: sha1:73124a3153fafbb09875f9be99ce2ce466fe1d27 + pristine_git_object: b6315e1aea3f6b6657243a1d45ef99e40791174e + docs/models/platformrequeststatus.md: + id: b024c51089cc + last_write_checksum: sha1:8ea233a8f7832dbb89400207632ed7ac325f0287 + pristine_git_object: 654cf9043104e3d5c64ddb91869af28bac6e122a docs/models/platformresult.md: id: 0fe3fed8d508 last_write_checksum: sha1:00c06fea69f19c8deedd7c27aa8fa735d1b04612 @@ -2722,8 +2814,8 @@ trackedFiles: pristine_git_object: 74045b8a6ae5e046bacdfb861ababddb3d770f5c docs/models/platformskill.md: id: 83c575f92901 - last_write_checksum: sha1:6b749a33dc64251968dac815aec5189373449b3e - pristine_git_object: f803434a2bd716ccdd0731bfb29c6921ce8e1c88 + last_write_checksum: sha1:d7789e381069b23aa1e7236c140f5db05fc246e2 + pristine_git_object: 3a68c65b0b08b80e44e2b10687404bfe7179949c docs/models/platformskillcreaterequest.md: id: d5a84c9d1cf0 last_write_checksum: sha1:90db6d3c8fe55234b4dcf26c734c04fc641ac719 @@ -2746,12 +2838,12 @@ trackedFiles: pristine_git_object: e6c95bd604dd05e5d2adfa909f30c2bf9d198b56 docs/models/platformskillimportresponse.md: id: 9a66de8859b8 - last_write_checksum: sha1:1c24f744a99500576dee1e41d5dd83ee9c799b7b - pristine_git_object: 9a383f207c36e4ac9c50a84c4f704c86dfb2d82d + last_write_checksum: sha1:2bb7017a4ea27b318bc2463d2961c9d929dc2f2a + pristine_git_object: 079c091efa09a850e3e829204a3c32c3b9a1ec95 docs/models/platformskillorigin.md: id: 66c12ec2d017 - last_write_checksum: sha1:281337f3fefcac11e66e5d8429b3b601dc357a57 - pristine_git_object: ca7bf36f2c931c0dce0bb529f8c2d86f4a06c326 + last_write_checksum: sha1:7d7f7efb7e4e48058e778bdc2b99d58fdfe55a38 + pristine_git_object: c43dbe562cc13c11ff28494d097e46859801ea2c docs/models/platformskillscreateversionrequest.md: id: bfcd223dbc04 last_write_checksum: sha1:5296d14b096632ffb2425da1f0db1fd6de40d18e @@ -2786,16 +2878,16 @@ trackedFiles: pristine_git_object: f9a2d64ae818b2da0d46bbec7f78eaae964678f0 docs/models/platformskillslistrequest.md: id: 475ac6fb76a7 - last_write_checksum: sha1:4bac5ec35ddeb35d13d8494aebd5e8237a1d6239 - pristine_git_object: ebf0ada9b31b7f0788d46aa6aa866d91270c86e7 + last_write_checksum: sha1:b59ca09afc101cfe225b37b8c7872e81fd6b3d39 + pristine_git_object: 321617bd7094f98b25bc2ef27698d1b18fd8223c docs/models/platformskillslistresponse.md: id: 03920dfa6e9d - last_write_checksum: sha1:a01d7093df9c1723f0fc7e5e55c75c13d502e8fd - pristine_git_object: 1adcf3fef9224325ffd1a40f5a37e26aaddc3d7a + last_write_checksum: sha1:ed6ed24b10e84239736f93f350d1745812cf4941 + pristine_git_object: c880bd4676f837f07a327ec209b5ebdc5a6a978f docs/models/platformskillslistversionsrequest.md: id: 47bd785d0b34 - last_write_checksum: sha1:c632c4018fd96fbca40e07d7dc3bf318ff65726f - pristine_git_object: a3fa36c955ce74ae0fac7bc821fe969fc407a67c + last_write_checksum: sha1:ea08c60a99059692a7f4c34b19fadde75543b27f + pristine_git_object: 75cd11778c969e1eb9d1cedaf140f876ac68cb2d docs/models/platformskillsourcepreview.md: id: a20f898498fd last_write_checksum: sha1:989f9420ee121202fec25562c5fc30ccdf14d953 @@ -2812,58 +2904,118 @@ trackedFiles: id: 80920192692e last_write_checksum: sha1:ab96df0544d94fda5d111d61cc9b4579a3039df0 pristine_git_object: 6f4626cb6098e3e52101516801035c098c0cdbe5 - docs/models/platformskillsourcepreviewrequest.md: - id: d7467b60160c - last_write_checksum: sha1:7771e2da7324d59d224a9e561721c2ff40209164 - pristine_git_object: 8d0b03a4ac2bc72a3059f1410f7e8f6bbbf0a537 docs/models/platformskillsourcepreviewresponse.md: id: 9f9048fa09fe last_write_checksum: sha1:7b55521b8f0031aeacb1bce804bf0975ba7ae809 pristine_git_object: 0c2df151a3683fcc39d966ca90cabfb9525316c1 + docs/models/platformskillsourcepreviewstreamerror.md: + id: 84fa968012d7 + last_write_checksum: sha1:97f1e6ec20f74e3a964b4c30a416bb2bcb65be40 + pristine_git_object: 0de09b2670392f551db795c2071ad791a0c4c2ef + docs/models/platformskillsourcepreviewstreamerrorserversentevent.md: + id: 10918a76db8c + last_write_checksum: sha1:c2b9e6c793ac949e4bd170397f309f6a807742d7 + pristine_git_object: 0f2bab47602c81d6371c632b06a162234b79cb7c + docs/models/platformskillsourcepreviewstreamerrortype.md: + id: 60f92906cb43 + last_write_checksum: sha1:c73df8474bcfd3c45116d12dcf818e0cb8fc99ba + pristine_git_object: eaea8d89f417242d97fc1c8624f14be7805f211d + docs/models/platformskillsourcepreviewstreameventserversentevent.md: + id: 2b7068826461 + last_write_checksum: sha1:243d109a425d7b57efde6fb37f79a948b43c23ab + pristine_git_object: 1a3ff6a82843a30827c83b3e4ec779b731222025 + docs/models/platformskillsourcepreviewstreamprogress.md: + id: e4da4f206067 + last_write_checksum: sha1:101308495c0e319d9b2b322643be0c48bbddcaca + pristine_git_object: 320e3d52723f656b87ef56dcd38ac50cfbfff4d8 + docs/models/platformskillsourcepreviewstreamprogressserversentevent.md: + id: bbdbc9def3d0 + last_write_checksum: sha1:6c3b5d9682eb5016ecfc11a37651d0210bd9c94e + pristine_git_object: 7f6063119c2da3df8886177b57c6ee339c62f281 + docs/models/platformskillsourcepreviewstreamprogresstype.md: + id: 8aca3319aa3b + last_write_checksum: sha1:16b7cb86c52f089982049c92794793c6023c0dd5 + pristine_git_object: 7a25cd48465de12437e3d637ab9d09b7834528c9 + docs/models/platformskillsourcepreviewstreamresult.md: + id: 356c29ee4486 + last_write_checksum: sha1:549befab1998dde0a248f99971aa18100375369e + pristine_git_object: c778b25759c85313782a5f0ca458661b43d13683 + docs/models/platformskillsourcepreviewstreamresultserversentevent.md: + id: a1ee433e9512 + last_write_checksum: sha1:348b4e1672a02994f3f7893229652a4c4585972e + pristine_git_object: fae2c0e8df796ec87cdb00506c281b0401f3aad8 + docs/models/platformskillsourcepreviewstreamresulttype.md: + id: c65916cbed8f + last_write_checksum: sha1:20aba21b3d7f8a8dc23f8c811484d4eb702eff25 + pristine_git_object: aae68d66595905a1b4d63f18dcfab9e1b3e37f6f + docs/models/platformskillsourcepreviewstreamscan.md: + id: 682dd1c4ac94 + last_write_checksum: sha1:77bc3bf4050ced3f63a869a501be1d48a997766e + pristine_git_object: c9705a55de286bee828d21cf133d413106497f97 + docs/models/platformskillsourcepreviewstreamscanserversentevent.md: + id: 93a676767392 + last_write_checksum: sha1:6140561ddc2c9811e95b0d3e5a14284196417a90 + pristine_git_object: 6b69806dba3fff88363d7028ad084b1512de5416 + docs/models/platformskillsourcepreviewstreamscantype.md: + id: 204786be9534 + last_write_checksum: sha1:8e1393f55c730b391ee12454e0c30313f01fdf70 + pristine_git_object: ba71c62a1d868b4c5c8f1a521066508dd477adb2 + docs/models/platformskillsourcepreviewstreamskill.md: + id: 1022b279fd21 + last_write_checksum: sha1:4803b1c4450544121fd113733ecb9317ab1b3e0d + pristine_git_object: 30f6225d86c636cdd44bd72985e34aebe7af5236 + docs/models/platformskillsourcepreviewstreamskillserversentevent.md: + id: 8951af43b977 + last_write_checksum: sha1:e23975a87d6fb75c88dfc72627d110bc05b617b9 + pristine_git_object: 740b8380ce08e8911a8755a3da825fcad3b6e46a + docs/models/platformskillsourcepreviewstreamskilltype.md: + id: 3e8a3c520903 + last_write_checksum: sha1:ce60088a3d60da225764574db25f58458ed2ed7e + pristine_git_object: 512ad4ade81b7aec03979689d2e561ce83c06556 docs/models/platformskillsourceprovenance.md: id: 259c50c9c90f last_write_checksum: sha1:d59dbc5d8d6a5e0a6da71f5a1bb3be1e0b2c8274 pristine_git_object: e7728f1bfc51509dc05d0b9e293eb08ad68c445c - docs/models/platformskillspreviewsourceresponse.md: - id: be33b627842c - last_write_checksum: sha1:8d5442369d04fcd70f652a28c6258b06cd62b0da - pristine_git_object: 2eabd1c452141c977bdd9e331b859694a4fc2ee6 + docs/models/platformskillspreviewsourcerequest.md: + id: 017ec0950f44 + last_write_checksum: sha1:ba633b1c419b5486a331f6c125dafc3f8e761d61 + pristine_git_object: cabcbff80fb0de9536581d7cf469f96630559ffb + docs/models/platformskillspreviewsourcestreamrequest.md: + id: 8a6b578e83fc + last_write_checksum: sha1:fad6a52c69236fda99be3c361170ec95b0e845e3 + pristine_git_object: 6d30247d171b81ed97a1c1a30f1b790c6f80effb docs/models/platformskillssyncrequest.md: id: d3c24d4f20d7 last_write_checksum: sha1:16c8019fe366f4e5e91a17a18bcba02a937a608f pristine_git_object: 58111860295d2bcff39bf2efbe38d9e2780419d1 docs/models/platformskillstatus.md: id: 33c93e7414d6 - last_write_checksum: sha1:7012661e93710994b8dc2a827b82bdb7da8bbb5f - pristine_git_object: 566f1092589cad8787c57dd7042e2f2c71ea49b4 + last_write_checksum: sha1:6772ad6cc5d999998f407328a948f6da8e16d78d + pristine_git_object: b863a5ebbecc12c027fe079e7600071000326fcd docs/models/platformskillsupdaterequest.md: id: f8592c4371a6 last_write_checksum: sha1:b9e9e33e0c952581b1087225608c9902fc4219ea pristine_git_object: c26ebd332bc1edbbd349c0de8c2ee6217da11c0f docs/models/platformskillsyncresponse.md: id: b449d9f6b2c6 - last_write_checksum: sha1:f8f1d23d37aac8ede523cdb7fa744e9c9dc55cbc - pristine_git_object: 03dbf80751f2c02778e0cc7385705d3aa909d5b1 - docs/models/platformskillsyncresultstatus.md: - id: c9adf6fdba97 - last_write_checksum: sha1:cf5d419b18c912661597d3c70a8dceb632c02a64 - pristine_git_object: 764a5847d5ff5ebbd775bf661c03a756d8b39817 + last_write_checksum: sha1:915b185f95fbcc164290cf2da3094760c6568875 + pristine_git_object: a3e141159f903a7a0c482415c2a2d732f3537562 docs/models/platformskillsyncstatus.md: id: c12e6da882a8 last_write_checksum: sha1:ddca3bc0c472815cbf35240dc3ce2f17c6fc87e2 pristine_git_object: 36b3ddd907f7ed42f42bfb7983afdb9f4dfb2b42 docs/models/platformskillupdaterequest.md: id: 6203e2a98d33 - last_write_checksum: sha1:593dd3b031c30c8fae572763aae685c552f22f03 - pristine_git_object: 1d94bb0a434f77403b9f6c4109e6beb9c71fa6a4 + last_write_checksum: sha1:548e4ade9c41186b1754d8412dd398d765599e60 + pristine_git_object: 3f454aaa8f8a81c951c893c63954a4f9575a8f13 docs/models/platformskillupdateresponse.md: id: de4f570e9a3d last_write_checksum: sha1:da13ed5450b210d4064056c72a712b270e6fe718 pristine_git_object: ae42e1d6a8e34603f2e157126f6eb8e733f6c3ff docs/models/platformskillupdatestatus.md: id: bbf036925440 - last_write_checksum: sha1:21c6edca9d3ba5ae257ae975d4fe66dfd707f6f6 - pristine_git_object: 898c434f2864d96532b529d80076e2b5cb20d68a + last_write_checksum: sha1:27d3f67a9992947df8cfc8ad9fe8d31c24394ccf + pristine_git_object: 87187173601e02a3d9171a6f2b43ba12fa4def64 docs/models/platformskillvalidationfile.md: id: ec82528a1836 last_write_checksum: sha1:f4f4f45aeabf5eb63cf40ce57edc939fe13a8d17 @@ -2906,8 +3058,8 @@ trackedFiles: pristine_git_object: a89c7a90219eb99cf80714dd5307fbdafceccbd8 docs/models/platformskillversionslistresponse.md: id: 04f03f45e509 - last_write_checksum: sha1:3fd42ad6fe3a2cd0ec97e477a960f18e9584c883 - pristine_git_object: edd94537c72a222df7aab60ddd84a4419ff712d1 + last_write_checksum: sha1:666195fb5bd138dceed17accc7fc25c72e11f066 + pristine_git_object: 082388b1d3aa6d33d3413f71d92207e50b4307a7 docs/models/platformtimerange.md: id: c37b2e815a8d last_write_checksum: sha1:31db2f83dba4ccb6d0a5e7b80edbeff356529101 @@ -3064,6 +3216,34 @@ trackedFiles: id: ba7807f1bd05 last_write_checksum: sha1:5c7268369788dbb8b7d4a573dceeada489dba02c pristine_git_object: c79b1eab1799d245a50c04c3180fd8f73192459a + docs/models/platformusagerequestsgetrequest.md: + id: ae3d4e29744c + last_write_checksum: sha1:e62f924ee2d70a421fe7860b5c2efae7d0ff0a5f + pristine_git_object: 47efb27a130769da47ab5efb07772d91c95ec352 + docs/models/platformusagerequestslistrequest.md: + id: e532a01ea9f6 + last_write_checksum: sha1:1662446baac35b6bc34db18bbf418eb7920b2f06 + pristine_git_object: 37da7f2cf880fa055fb92b93fdcc5fc76a075e90 + docs/models/platformusagesettingsresource.md: + id: eaf69120ef1c + last_write_checksum: sha1:8e64545ae9dd0da379f1410fc61f0b4109005ede + pristine_git_object: 6b0aec03e5c4a793ccbc746482251a62bc4f068a + docs/models/platformusagesettingsresponse.md: + id: bd687cfc7afa + last_write_checksum: sha1:ae617267e88d7d5ea6b778d814fd50987a7c7ea0 + pristine_git_object: e05699c1ad024d08a14bc07ec11d301816a7ee6f + docs/models/platformusagesettingsupdaterequest1.md: + id: ae7c3d0e7795 + last_write_checksum: sha1:b8344054ff6a0fd84b55d6a73f7e2d962e8ece42 + pristine_git_object: 56421737df83a27386c9ba3095f27c2b14077bce + docs/models/platformusagesettingsupdaterequest2.md: + id: bb4abc5d97d3 + last_write_checksum: sha1:81065ea3c81c7ab6b33c7c7019f5697fb22f6c6c + pristine_git_object: 863e66c829689218c03f1ac978e98cae9cadccba + docs/models/platformusagesettingsupdaterequestunion.md: + id: 32cef37ceaca + last_write_checksum: sha1:acab104dadb0dbf641cb68afae8dafe7d8ba1d4b + pristine_git_object: 7709ab537968b806e5b29b8f78476bff016bcfd4 docs/models/platformwarning.md: id: 458ffec7aa61 last_write_checksum: sha1:b70d5a767413fd7559601eb8e1e9728ad8b15773 @@ -3618,8 +3798,8 @@ trackedFiles: pristine_git_object: c7f7adecc74cc4072799169c68332df2d8932c44 docs/models/ugctype.md: id: 675d62d57771 - last_write_checksum: sha1:bafed49f9b14d83c3286e0e679168973efa19be6 - pristine_git_object: edccbd16624b8810be3c92ee88cafe94e9f76739 + last_write_checksum: sha1:c3d0ea6cf9dd63f17a6011f8b31d57883e961e0f + pristine_git_object: eeb95b91191d22ea33d976fbe6c90fb730991677 docs/models/uiconfig.md: id: c4d3817a701c last_write_checksum: sha1:dd422e5a1bbf9af85722cd43c5437716b8bb3017 @@ -3856,6 +4036,10 @@ trackedFiles: id: ae89309e8936 last_write_checksum: sha1:e1635e99db5bc7cb1f02a91cfeacbdb71beecb21 pristine_git_object: 61dd41f0319201cc105e29174ab1cc0018cecbce + docs/sdks/adminusage/README.md: + id: 5c2f7bd70c2e + last_write_checksum: sha1:84a46923f65cd88030e20a8a013c4f28bd7613dc + pristine_git_object: c00bad589706e6dbd0dc425d5bf0869086a51eca docs/sdks/agents/README.md: id: 5965d8232fd8 last_write_checksum: sha1:2f43583c532976156213dab99a4fcdf3b3a16853 @@ -3918,8 +4102,8 @@ trackedFiles: pristine_git_object: adac51700d9683a41dffb2f5c20ee18008a9e135 docs/sdks/entities/README.md: id: a140ac5181b9 - last_write_checksum: sha1:8ed55d70b05f1eb5c6c9f5a660f7321491cf05e4 - pristine_git_object: 55516c7df24464202dc36f9c118c323d266539f3 + last_write_checksum: sha1:bc03774c1d8541c868fe35963f549a1151a4648f + pristine_git_object: a5c95e0ed9dc9054df9e3c28baf3ae23c8e1cde7 docs/sdks/findings/README.md: id: 7f7356eb9e9c last_write_checksum: sha1:31cec287b2a5668e3f3bcf54173669c8a15aa292 @@ -3978,8 +4162,8 @@ trackedFiles: pristine_git_object: 43e735ef788378a15ac4a6e52aa4843ea4c5d4c8 docs/sdks/skills/README.md: id: 3a14a5c90791 - last_write_checksum: sha1:7c5b6dde477b907a0accac6ca019eb5d84aa5d03 - pristine_git_object: 7a11b9bcd4372fcefc3e59e66dc179ee8727bcee + last_write_checksum: sha1:86d96a041a5ab57b6a81ff70301fe3d4f142b334 + pristine_git_object: 6c9d5b42da5a3cff3e329e3960215a0ec0c9cb3f docs/sdks/tools/README.md: id: 044286549bac last_write_checksum: sha1:9b9a8e80c1d16018bd66150ba482b83825d6cf67 @@ -3988,6 +4172,10 @@ trackedFiles: id: 6706220e8a9c last_write_checksum: sha1:2bf6136aaee1c615729b74a54110abaa364988f8 pristine_git_object: 6b9d92d27e03823947907a1ed59fa53cf3fb9190 + docs/sdks/usage/README.md: + id: 631af2d7ce26 + last_write_checksum: sha1:16c66620aa532a0f9683e8c0bb8df248b5d77a21 + pristine_git_object: 2e8f5c3b9c96efa765d1e845d6934e4aeb749b8a docs/sdks/visibilityoverrides/README.md: id: c7d003d6a68f last_write_checksum: sha1:738c52c3b0964cfb441542710e10c51ca226f177 @@ -4006,8 +4194,8 @@ trackedFiles: pristine_git_object: 79e388be87446ab6a4064b372bad0e8376d0cb5e pyproject.toml: id: 5d07e7d72637 - last_write_checksum: sha1:50549d323659a35ab0a59c8c19451dc2d0aeba56 - pristine_git_object: b7cb0276a9bf207ec590dcac01947fd965245496 + last_write_checksum: sha1:dbe486cbfd0b3bd898820391ea73c269d83da610 + pristine_git_object: c6ffa3b52149c85754a7d5c6596b00214529923b scripts/prepare_readme.py: id: e0c5957a6035 last_write_checksum: sha1:c2c83f71dea61eb50c9e05da83b16d18b4da8794 @@ -4034,12 +4222,20 @@ trackedFiles: pristine_git_object: 55f23c1feabfedeb7e8cd5bea8b910f0ae0b77d9 src/glean/api_client/_version.py: id: 0ce22b26136b - last_write_checksum: sha1:6c63f673880e68be2815c4272eb4f4360d15423c - pristine_git_object: 4af11e8ed077223e781737633b6fd821ee561c3d + last_write_checksum: sha1:4eee3f3fc38df16b37cc25cf2223e76acfaab824 + pristine_git_object: ce7e0a16939827fd7367c1e2c7385610ae526b3d + src/glean/api_client/admin.py: + id: 583cfae82adf + last_write_checksum: sha1:b4845e6db7f1ca504fd209acc74511248d53a791 + pristine_git_object: c4b191232a92bff8e51ceffee0177708455c85e5 + src/glean/api_client/admin_usage.py: + id: 297c20e16cdf + last_write_checksum: sha1:2c0e157cff14d539bb558ac6c7254c6fb68809bc + pristine_git_object: 9abd018fb497167262c131e8e8fad9530c561be4 src/glean/api_client/agents.py: id: b925701a9217 - last_write_checksum: sha1:b911520f8b3938733aa37d8a8a5fb0c0aeb63cee - pristine_git_object: 23c75362dd1bc4f7ff8571dfcba9f1a6e1d3e600 + last_write_checksum: sha1:0e3dd95c81e2d38e1a13c1a0821a37c991ebade9 + pristine_git_object: 67c2c86a4486b542315acf6ee36ce72f2490569b src/glean/api_client/announcements.py: id: 452f3d593912 last_write_checksum: sha1:4b9f4ff97fb9754b5da3a36c1cc8edb02318ed7a @@ -4054,8 +4250,8 @@ trackedFiles: pristine_git_object: bf7b1b3b25ce6530403b0dd9f60599d236c780ce src/glean/api_client/chat_sdk.py: id: f2f30e13ca42 - last_write_checksum: sha1:106d956665429a3966b36f0a7cf70c35a9b39356 - pristine_git_object: b37457a825c6f8f7dd5a1183acf376b0bb187718 + last_write_checksum: sha1:03337f8457e7865116a1e816158488f21e79e10f + pristine_git_object: 2b43c6070fbb74911b70da6478865d80703adfaf src/glean/api_client/client.py: id: c0c188098f10 last_write_checksum: sha1:bfadba5dfdc64280fd9c7bdbf96a0651e5db429f @@ -4110,8 +4306,8 @@ trackedFiles: pristine_git_object: 1187e013fddc68f46bf0601237a4d8d6ba878e41 src/glean/api_client/entities.py: id: 38ebbab2f8a0 - last_write_checksum: sha1:bd52afae4d0b4d60e85189a4f6b999c280128329 - pristine_git_object: adc08d2771a312d55750096248b0f1a82d0432d0 + last_write_checksum: sha1:206168b489dbcfccd78cfab6e655c1228af50b7f + pristine_git_object: 44a41c9875078eb45326a4c198a8726f348ab9ca src/glean/api_client/errors/__init__.py: id: 88bbd5450191 last_write_checksum: sha1:1efa888eacd97dfa261f42013ae3690ab348346d @@ -4218,8 +4414,8 @@ trackedFiles: pristine_git_object: b140b656b788bb0deb8a974420783b338f0521e2 src/glean/api_client/models/__init__.py: id: d5f6ea5efcbe - last_write_checksum: sha1:e8461ac57d0cb12b0d136b1eab7374503d248019 - pristine_git_object: 6eac20c2c6f5bdb7f619dcc74a5c907742b0a8d8 + last_write_checksum: sha1:fa2c656e3e3f4826386dbabf2eb1237441f1a8b5 + pristine_git_object: 80619420e52bd3de1958129ff6d0a0d7a84e4586 src/glean/api_client/models/accessrequestpermissiondeniedresponse_error.py: id: 22a2fa0d5899 last_write_checksum: sha1:f7dd6f906a4dd7433992f77395f9fb491fa5ac5c @@ -4372,6 +4568,10 @@ trackedFiles: id: 90f48896fb46 last_write_checksum: sha1:3c4b307b7a965ff51f2f8b9c0d8d558563b397b7 pristine_git_object: 2105b7fe8cacbb74eab2c4d13bee7fe20af2c855 + src/glean/api_client/models/artifacttype.py: + id: 918d9cfbd123 + last_write_checksum: sha1:4d857fe3cbf08b4f921fd5af79f4550216beffc3 + pristine_git_object: 1d5c4d3d3662e6faad1f3ef36a1f93e8447525ed src/glean/api_client/models/assistantinsightsresponse.py: id: ce7387f28d84 last_write_checksum: sha1:9b1c7809e56d14ec0441969ed7a7f2d39aa8d1bb @@ -4422,8 +4622,8 @@ trackedFiles: pristine_git_object: 97d2bf4e337f24d11d53d15916bd5c59b9942b66 src/glean/api_client/models/autocompleterequest.py: id: 23b29c9e7dcf - last_write_checksum: sha1:f2f792c9d5539d92bb275385cae0a32667382c50 - pristine_git_object: 77f48a08f4bde254f8e201d5d03863cd15b9b150 + last_write_checksum: sha1:267be41c9d987da2f2dfc8a0d8ad3cb26e234566 + pristine_git_object: adfebaa0aa87fee2b86ff14fdae1fd527a7008bb src/glean/api_client/models/autocompleteresponse.py: id: 860297c9ef84 last_write_checksum: sha1:7972aeb2f5bd1c56df96bbd708088add6d5f04fd @@ -4594,8 +4794,8 @@ trackedFiles: pristine_git_object: 6ce3ce9bca35b6fee469e40b1b99a1e8a54fa733 src/glean/api_client/models/chatsuggestion.py: id: d1672ba5a41f - last_write_checksum: sha1:86ffbd3413a5d8ed6b631d10d8f888f617b99ac9 - pristine_git_object: 8d24fdad03c32156f977ad28ba870e31ca40ef0b + last_write_checksum: sha1:25280fb880062a3038cfbae9d4f730bd301a5118 + pristine_git_object: 95b2928c2a520e742bce07896f7ab4aace936e4d src/glean/api_client/models/chatzerostatesuggestionoptions.py: id: c2b8ed9c9949 last_write_checksum: sha1:2d1b44dcd4d7b15343829548833a2e257b3106e2 @@ -5298,16 +5498,16 @@ trackedFiles: pristine_git_object: 44041cb376d89949c815ea1e7813505940605855 src/glean/api_client/models/feedentry.py: id: 023eb6c10ae1 - last_write_checksum: sha1:803bdce57dc5815add1ac47744ecfb35ec26b3b8 - pristine_git_object: 83e2c6f0abadf1a67f849ff34c9ec825be039bd4 + last_write_checksum: sha1:fb8bf6c223b3d9110a3e891998e57e6f919ec4fa + pristine_git_object: cee66e4fa0c720a70490a07c3f3bd004863d2075 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:5d2d1b1a5b9cca934cd4d1a91b24b1a78a5afe3a - pristine_git_object: 75cd4b1bd2b9eb2508887a6e83485136713adef4 + last_write_checksum: sha1:5f5022567797b05cab8899b5e8cf4a2eb74e355d + pristine_git_object: 90fefe1458da4b214c170bfaecfe75c174d39cfc src/glean/api_client/models/feedrequestoptions.py: id: b99003fbf522 last_write_checksum: sha1:d5ffee29242075cbe6d2dd5ec916b0c3d40acf54 @@ -5318,8 +5518,8 @@ trackedFiles: pristine_git_object: 683438c837601f483526ec18756fadc7222edb24 src/glean/api_client/models/feedresult.py: id: ae187332b37a - last_write_checksum: sha1:d0e0236236965e4d5f2b3dd8776849e5e0bc36fc - pristine_git_object: f450760d9e50554270028662971d013df801cbd6 + last_write_checksum: sha1:fab0dcd390434b5e54ba79e34ce2c232f7e68f5c + pristine_git_object: dccf45add539232ef985984b429e9b3cdfb2add2 src/glean/api_client/models/followupaction.py: id: e2de5c4c8524 last_write_checksum: sha1:49e1a826449081fecfcd828c940604db949a8533 @@ -5784,14 +5984,18 @@ trackedFiles: id: 5cd6cc3b46ca last_write_checksum: sha1:b2717bc4112725c29f9d41376e51fc1212ab844f pristine_git_object: f0f511048d7e6766eddca8222503bfa475ae120a + src/glean/api_client/models/mcpauthmethodbreakdown.py: + id: 4bf72b45633a + last_write_checksum: sha1:88cfbc1814bbbfdb52269472f0c42c6f2e064da8 + pristine_git_object: fb87c13ee59d6a349c0244bb4aa7a3490132c965 src/glean/api_client/models/mcpbreakdowninsightsrequest.py: id: 332e57fe91b4 - last_write_checksum: sha1:1b302a4ab4ac5f6c4d7f23aa00c213984b44e340 - pristine_git_object: 2893dadf9907c3784a93a86adbff8918aebf62e6 + last_write_checksum: sha1:b8a5b8ffbe594cfce61d0183bec0379441638511 + pristine_git_object: 4d3a744d015294bb021141563748b237fe19a669 src/glean/api_client/models/mcpbreakdowninsightsresponse.py: id: 8d4c4b79318f - last_write_checksum: sha1:4fecec20445ede1663c33a02bbbf199f8abb71f5 - pristine_git_object: 5afd6a5c6f4462d2e2dc8fdd3500253fb820c54a + last_write_checksum: sha1:327324327a51d768f191da5325d9c018d51bef43 + pristine_git_object: e3f49671ad14aa1528da0f08e6a7a54cbcb2d01d src/glean/api_client/models/mcphostapplicationbreakdown.py: id: 1781ca7f416c last_write_checksum: sha1:d745fe25cc993a40ccee8fad5b7f754c4f839ddc @@ -5814,8 +6018,8 @@ trackedFiles: pristine_git_object: 5fcb1924ca16d5dad4fe73daaf5465584387fd9b src/glean/api_client/models/mcpuserbreakdown.py: id: 1dab2bbf7d27 - last_write_checksum: sha1:d10980a038d4d7e3384c46d0ddbaf2b6b1a0e93c - pristine_git_object: ec4587ff6a16cb153f3de2a43edc1bf9ee7eec53 + last_write_checksum: sha1:1dfe73c56e8671378f42ae0a04c8eb9b8abbcf02 + pristine_git_object: 42a1ac29e3a9b8b16e5ccddcbef7b94139da8394 src/glean/api_client/models/meeting.py: id: 0b1f0fdee050 last_write_checksum: sha1:d727361f35d0138e09cfd1bc1e8480afd0996795 @@ -5862,8 +6066,8 @@ trackedFiles: pristine_git_object: ab286401ed0296450b2ba4751cdb51ccff6f5a5c src/glean/api_client/models/peoplerequest.py: id: a7dcc3001149 - last_write_checksum: sha1:3d45a0ac68de0c33d9e040aa3e263653808803bf - pristine_git_object: 520c04d8b03a50d6c062827eb9dde4f67057f46a + last_write_checksum: sha1:1860e6f7a24bdb3bfbc40847d525b1272d924dba + pristine_git_object: 1ecee9b17688fcee5d67e193b1ca08cd878f74a4 src/glean/api_client/models/peopleresponse.py: id: 85f4d95884f9 last_write_checksum: sha1:ed99cd7a6f88c2b90a020d44ca984544e9693cb6 @@ -5886,8 +6090,8 @@ trackedFiles: pristine_git_object: 52b20386d1215ca9d5ddf1510c569954ae510c38 src/glean/api_client/models/person.py: id: 486c8c3db123 - last_write_checksum: sha1:277538c34f3024a5aa55ea6476e84268555c3eb5 - pristine_git_object: 24355a993c1e2b4e370eac468508ccf90242ac1c + last_write_checksum: sha1:1a6ad2c2c4cbe493c84499fe442660ae8ba56005 + pristine_git_object: be88dd7ee62fed92315207cff2267fc5d437062a src/glean/api_client/models/persondistance.py: id: 307f87d6cd91 last_write_checksum: sha1:90c27054198a8779074839f5226724e81271b462 @@ -5928,6 +6132,14 @@ trackedFiles: id: 5b14b683421a last_write_checksum: sha1:73484002a7a37df4baaf05fd282bf904acf54cc9 pristine_git_object: 1e291af2ba4ec81b33d9b03faad6cb8365c8ab55 + src/glean/api_client/models/platform_admin_usage_requests_getop.py: + id: 9c3574891c7e + last_write_checksum: sha1:8b4bcf5150d19a2bc77248afe70c517d5c26cda9 + pristine_git_object: da1306242bb34968d6116ce5db5c570aae0224df + src/glean/api_client/models/platform_admin_usage_requests_listop.py: + id: 3f5680f5719a + last_write_checksum: sha1:2aa49c94ecd42837743409c7bc92ea9163bb85e2 + pristine_git_object: 02b0f11fc7c211596a19beee549b7bf369323c18 src/glean/api_client/models/platform_agents_cancel_runop.py: id: c5b34ef0de1f last_write_checksum: sha1:e4e08794926fc36c0f3f00adffcd792b99d281ca @@ -5990,16 +6202,20 @@ trackedFiles: pristine_git_object: fc64256bf43449e23e1e7d093a45ee3fdfc441e5 src/glean/api_client/models/platform_skills_list_versionsop.py: id: 4d91c282c246 - last_write_checksum: sha1:4d572ac46c4a7085442f8724e12fed67ee6256fb - pristine_git_object: 145d396dbaf75e185792e6b19a4f0d635beffd37 + last_write_checksum: sha1:6d512e70608e914407b2a51c96ddbe9e54815e21 + pristine_git_object: b34fd73fdde468889d03ff2534a9ff58a4fca25d src/glean/api_client/models/platform_skills_listop.py: id: 2172706b6858 - last_write_checksum: sha1:7e9d92bd23b8072d38fc787c08d2c1d11afee1dd - pristine_git_object: 3f77419309047da04a558921ae77b447bf465d40 + last_write_checksum: sha1:ec8e8ead0aba41dadf4c74c51c9544f3f121a191 + pristine_git_object: 5c21fa77645acbbeaed69a4e5ad7cb9844670e3b + src/glean/api_client/models/platform_skills_preview_source_streamop.py: + id: 18b6a2dae087 + last_write_checksum: sha1:ea54a718241b065e791ed9f8e967818908521288 + pristine_git_object: 2ce11df6c8c13e74a959efc0ebc1b10e1a37169d src/glean/api_client/models/platform_skills_preview_sourceop.py: id: b7afa7764cef - last_write_checksum: sha1:cc21b3ead6075cb3db6426c2329b070648cdf32b - pristine_git_object: 30dcdd72bccb0fbfafd8c74a556654fd98da0b04 + last_write_checksum: sha1:72d025c4863fddbcca0f2ffc40d0647b5379875b + pristine_git_object: f56672761b4b2dee0cbff34294868eb7448492a4 src/glean/api_client/models/platform_skills_syncop.py: id: c6a29bedca20 last_write_checksum: sha1:90811712776457d85a5abe880857d1aef55f0197 @@ -6048,6 +6264,14 @@ trackedFiles: id: ee2002799c52 last_write_checksum: sha1:b4e89947c50873b2b74a283fdd1bbfa852134c6b pristine_git_object: c57697e4999df306ed30b910fd2e1d0e5007663b + src/glean/api_client/models/platform_usage_requests_getop.py: + id: 8471185bf630 + last_write_checksum: sha1:9a44f4283d396a8b1a280c31cad9bb868e8009e4 + pristine_git_object: 31a885aa5ed03d844d246f06b73b39ba37dcb623 + src/glean/api_client/models/platform_usage_requests_listop.py: + id: c81485f3abca + last_write_checksum: sha1:33c152f95299efc1537f704c83264e01c0593157 + pristine_git_object: e03e60d47a8f70cf9b6e5294eb114f3e7ab761ef src/glean/api_client/models/platformactionsummary.py: id: 00069b22d246 last_write_checksum: sha1:f714e076c3e0c86ded17dd732ba304dfc7d5526e @@ -6068,6 +6292,10 @@ trackedFiles: id: de08c9cd1f7e last_write_checksum: sha1:4b5e5e9fd0a8016e12954e78c56db177af5ab002 pristine_git_object: dff409304169026967f63b216afa4cad4e72d215 + src/glean/api_client/models/platformagentrequestcreate.py: + id: c3e1f5e9fd1f + last_write_checksum: sha1:abf2247d3fea49429ae7230e321d1a1f7e8f61a7 + pristine_git_object: f3614d69ea2ed4a5054405e0519eab71d8c538be src/glean/api_client/models/platformagentrun.py: id: 6a27f28ec4bf last_write_checksum: sha1:04e126eefa9aa91ff20eae6156e1737fb9210774 @@ -6268,6 +6496,14 @@ trackedFiles: id: f7d7bf136596 last_write_checksum: sha1:542dab71eb37501311f1457ef804f2486cc12d69 pristine_git_object: f0185fb9ecc077306220bae51217c1eb86018aec + src/glean/api_client/models/platformlimitincreaserequest.py: + id: b13e7f0e229e + last_write_checksum: sha1:1abb284a7bc26e04f85547f054217103c4a6681e + pristine_git_object: ffa63593064911d34e67a3383c49bb513f6acdc3 + src/glean/api_client/models/platformlimitincreaserequestsettings.py: + id: c8780e1601f7 + last_write_checksum: sha1:7140adcad97efbf2385666e126cce12234a4919c + pristine_git_object: ac77b5eb4cf854dfb76b16973b7477688f533090 src/glean/api_client/models/platformmessage.py: id: 5124dae40c5d last_write_checksum: sha1:e86beb4e210ed500ab72011ef90bb97b909a39e8 @@ -6288,10 +6524,26 @@ trackedFiles: id: a94017fc587c last_write_checksum: sha1:a7bf23349f2aa6aeb11de705a2d947a267f9aaf6 pristine_git_object: ddc4a1bb76ea66050631863cd0c52a779ba630ef + src/glean/api_client/models/platformmultiplemembershipresolutionsettings.py: + id: 2427b7559648 + last_write_checksum: sha1:d7ae1d6166a2a0876aeac10a7d5f3583ba4e8f5e + pristine_git_object: d3669b0739c404d2e824aae00012bfae56027075 + src/glean/api_client/models/platformpermembersettings.py: + id: 4c0515757f4a + last_write_checksum: sha1:82d1870dc0d5b8a50ee5be112205fbdbc4b2841c + pristine_git_object: 55f1d0eedcaa8a55006c96e7013b8562753f8627 + src/glean/api_client/models/platformpersonalrequestcreate.py: + id: bc058071d98a + last_write_checksum: sha1:02f1014254ffd45c2892cb5ce99ddeec31c2e4b8 + pristine_git_object: 9df2f1664ed773ee3a5c3f0776844aad951cbe0e src/glean/api_client/models/platformpersonreference.py: id: 2ff9ab749423 last_write_checksum: sha1:a366e67090ccf5a9754576467db2043a33e8a8e2 pristine_git_object: 3f68797935412add6a9cbe28335641064352c8c5 + src/glean/api_client/models/platformproblemdetail.py: + id: 564643c3d847 + last_write_checksum: sha1:bc77e15836741f22cc5d2f67b8fe32d2e4668986 + pristine_git_object: 05d4d46e2111a803b4194f0d81d50b315a7efa15 src/glean/api_client/models/platformproblemdetailcode.py: id: 3aa0b8193255 last_write_checksum: sha1:7f0f9bc67cdaa742e4cf4494bf2a3c29f8b58a16 @@ -6300,6 +6552,30 @@ trackedFiles: id: ea67cf68f170 last_write_checksum: sha1:c2f31d78abfaf8e63bd7ab62ff9e0fb281caa5a6 pristine_git_object: 336efdc33bfb762c3b0ddfc706b8d089da3cc23f + src/glean/api_client/models/platformrequestfilter.py: + id: 8530f5007061 + last_write_checksum: sha1:a4897d1ec83cd266506026d3a6a9b100d67f4f42 + pristine_git_object: 193c028f2ea04dce3c02282fbe0c8928aaa331c5 + src/glean/api_client/models/platformrequestlistresponse_union.py: + id: 958c81294075 + last_write_checksum: sha1:ba4a12b2721b507ffc2aa15df76ab02e8374dc5f + pristine_git_object: cbbf2ff14e0cfd13c85db126c856e26cec94001d + src/glean/api_client/models/platformrequestresolutiontarget.py: + id: 4505a9f8044f + last_write_checksum: sha1:e1161549cd0e6097b22c8d4f70f753a4b71cd19a + pristine_git_object: 913729732204348fd802f85c92d8b943c744c7d4 + src/glean/api_client/models/platformrequestresponse.py: + id: 4efeb236fc91 + last_write_checksum: sha1:2d8c338ebca66cedf13535da1d86e17cca95cf28 + pristine_git_object: b77c09193d80ffbe126d986c6e72f7db2d98e656 + src/glean/api_client/models/platformrequestscope.py: + id: 1e48d20589cc + last_write_checksum: sha1:6998ca6f7f8e4b866c8c3ca3c8f77ff301db858a + pristine_git_object: 7aa6be6649983fb9ab3ce8b6e4e3652b8785efc7 + src/glean/api_client/models/platformrequeststatus.py: + id: aa4270e5e2fe + last_write_checksum: sha1:94fe2966296fe86364150ef5557315ddce77b0a0 + pristine_git_object: 8766473550e2a2fc5a749465df572d61754279f3 src/glean/api_client/models/platformresult.py: id: 65de4ed5c1b3 last_write_checksum: sha1:b4b820992eaa454f9ac072e152204c6289e2a314 @@ -6318,8 +6594,8 @@ trackedFiles: pristine_git_object: ff13d204ece88b150c32fb69c65e266c7756b1af src/glean/api_client/models/platformskill.py: id: 10e1f311015c - last_write_checksum: sha1:c0225f37738625dbb6cab763be77cf5e40beafeb - pristine_git_object: 4b7e21a7eff4002f44ca69cc00ea080b152db720 + last_write_checksum: sha1:e1a70d0d4758869a8afc969c11b59f8426666c64 + pristine_git_object: d77b1fa2833bbe578a96a19f0402770e9aacf491 src/glean/api_client/models/platformskillcreaterequest.py: id: 9d75227d70d1 last_write_checksum: sha1:f6dadfcbab4b2800dd99abb6807b82b27c8c288e @@ -6338,16 +6614,16 @@ trackedFiles: pristine_git_object: 00ca6da543a5ad48d248e87c5199b36a415e8f2d src/glean/api_client/models/platformskillimportresponse.py: id: 5c641d8380aa - last_write_checksum: sha1:12aceeb94df10e62efcf8438f8db1b14cf92a5d2 - pristine_git_object: 4e8827e598b98f0f70a1a8fa6d132d56e421ed6c + last_write_checksum: sha1:f39609872801aec07d3ec7830aa5b4f8d21027eb + pristine_git_object: f07899250a6c4e5058cf71b41de0f25222b77699 src/glean/api_client/models/platformskillorigin.py: id: ac7dd2421a25 - last_write_checksum: sha1:d3373713ce852bfc79d180d5a9cb6d27d5bdd0e3 - pristine_git_object: 320c60ec3c2d46cef59742d40c6de29c43425776 + last_write_checksum: sha1:e75c12568b0a13107be45cc71c61343f91a4a5db + pristine_git_object: f05da6ac9653f6ba3b9fb1de2f1bd66730aa00ae src/glean/api_client/models/platformskillslistresponse.py: id: b031da1d2783 - last_write_checksum: sha1:45e8d141fb11032f3fd143d1818845a7eb750c3c - pristine_git_object: 7303b0519deea755bd54b5f5a42e5e0908c5c92f + last_write_checksum: sha1:771558db4f0e0d491b51cce54360fd084fe31051 + pristine_git_object: 8d37912ab9c1d7576088665dc12638d485bd510b src/glean/api_client/models/platformskillsourcepreview.py: id: aeb8f137962d last_write_checksum: sha1:2e2fd40151aff7cd3f0cb08997d66ffce8bfc314 @@ -6364,46 +6640,82 @@ trackedFiles: id: d7594e3706a8 last_write_checksum: sha1:8111240b45e77e5605be4d2993df8cbb0d1fe89b pristine_git_object: 71aee5339cc6d9c46394bd7c34b50cd51cde5a40 - src/glean/api_client/models/platformskillsourcepreviewrequest.py: - id: 521e672126c6 - last_write_checksum: sha1:987c57fe9b2db03d39cac8dc58750e7dfdacf7b3 - pristine_git_object: 92057490d80383015b2b175b7cd1b07845f46a24 src/glean/api_client/models/platformskillsourcepreviewresponse.py: id: 41861007f222 last_write_checksum: sha1:9eb2f08cf3b4ed7924286cc6c0233868ca1168c2 pristine_git_object: 37cf8bc1466c6482fd43c53d3ac2b54759d7d9b8 + src/glean/api_client/models/platformskillsourcepreviewstreamerror.py: + id: 5a87352ef914 + last_write_checksum: sha1:4334a44e1c7d20ca04ee3f9bacd4ee0af81d90a0 + pristine_git_object: 68f225d37986aa6aa2a122bdaf8c9d6650720eb3 + src/glean/api_client/models/platformskillsourcepreviewstreamerrorserversentevent.py: + id: 3d6a6f10c215 + last_write_checksum: sha1:7b4fc344bcf4b976f1ac30c635b33bb74c350ad0 + pristine_git_object: cd9a68bdfcea436b6dd29b7cf495f27cba535b0d + src/glean/api_client/models/platformskillsourcepreviewstreameventserversentevent.py: + id: 187d998b8358 + last_write_checksum: sha1:57c6e49c9c023f8feda24909b2e8a8b13a164e5d + pristine_git_object: a4974c16fb4e51fba062d1a25c6b1efad390610e + src/glean/api_client/models/platformskillsourcepreviewstreamprogress.py: + id: 4150674e4e9b + last_write_checksum: sha1:8d9f98350d600f09481f85d39d59e90cf60023c0 + pristine_git_object: ecca3b704cd9db73933238972abe905e8f3688b3 + src/glean/api_client/models/platformskillsourcepreviewstreamprogressserversentevent.py: + id: 08a0cd6abc04 + last_write_checksum: sha1:dcc1a85f50f73fd1ed260233241c4e80c08bcc70 + pristine_git_object: 60c2dbed5e9f4464fc77ff713d5eb2fe35b1a109 + src/glean/api_client/models/platformskillsourcepreviewstreamresult.py: + id: 36520c198eac + last_write_checksum: sha1:7c2f9f0100f9f84584e31863615d0e3c98a611c6 + pristine_git_object: df6d3b6ef858e6c4415579d09ea3b4da137cf569 + src/glean/api_client/models/platformskillsourcepreviewstreamresultserversentevent.py: + id: 4475a41fb7e4 + last_write_checksum: sha1:72ec21c35c356c749b601685f87f9eef59be019a + pristine_git_object: 0741143e4b96a4fb01f0f26116bd2be1c1b0fed7 + src/glean/api_client/models/platformskillsourcepreviewstreamscan.py: + id: 3361e8ce4f5a + last_write_checksum: sha1:acf9e15967f6864307c0c29b109a9c265d1f010f + pristine_git_object: a8fd422972c649a00c59dd85553ecba063c2d3d5 + src/glean/api_client/models/platformskillsourcepreviewstreamscanserversentevent.py: + id: 0a1e279e7ab2 + last_write_checksum: sha1:dc4e9d65b448d67b88c6c93fa76814f95ecce53b + pristine_git_object: aa588667793ad02acc2b771bb991e3f3a82eb75c + src/glean/api_client/models/platformskillsourcepreviewstreamskill.py: + id: 7a2284184193 + last_write_checksum: sha1:071f2b93c7f5671f8932b50c148545cc6a874516 + pristine_git_object: 937205e34b188f3f5112cd3e8feabe190a6972f4 + src/glean/api_client/models/platformskillsourcepreviewstreamskillserversentevent.py: + id: a7a0cb837838 + last_write_checksum: sha1:6259d650dadb7a3bedc7ec369f197e6fc3fd1e52 + pristine_git_object: 6197d06de7f450eca9fe73fbeb6b9cb6534f428b src/glean/api_client/models/platformskillsourceprovenance.py: id: 9d34177a5499 last_write_checksum: sha1:f1e2f0b74c65cd83e452b6e1cb0e33f0921c1085 pristine_git_object: d1352b1f9d6654cc43a2c81e33177d5c9a0e8528 src/glean/api_client/models/platformskillstatus.py: id: 4576e2918e48 - last_write_checksum: sha1:1590f56ac48366b921495bf292ee76b6e847d4e2 - pristine_git_object: d57185fb36c553090f5e797908e9f47447901c0c + last_write_checksum: sha1:f7a447d7333ae356690db028cc6d43c3f0bf8f7b + pristine_git_object: d705872350e43b38447834a1dd5b5574fe308612 src/glean/api_client/models/platformskillsyncresponse.py: id: 6de5744ff262 - last_write_checksum: sha1:945703bb35b623bd6b98200f00e17fe7c653f2ce - pristine_git_object: 731c531db42da5de432430aee73cf11706bb310c - src/glean/api_client/models/platformskillsyncresultstatus.py: - id: 453d374eb1cc - last_write_checksum: sha1:f8cac0172ec78194127e051d04f0af14e0012d2d - pristine_git_object: b85415a1e5bd2e1c3fb32ff934e89b60338d1c43 + last_write_checksum: sha1:7d2ec9da8ef2962769f964b56b47e1199055aecf + pristine_git_object: 8fe7526e9bed75768019ab8123f553b3abfae62a src/glean/api_client/models/platformskillsyncstatus.py: id: 4603ae41cbb9 last_write_checksum: sha1:911e9731ed66a257df85158125499d212a37f995 pristine_git_object: 13fb6bcf5a11934ae1c8e1cd100715fd8aaaedf6 src/glean/api_client/models/platformskillupdaterequest.py: id: 02dbc059a73d - last_write_checksum: sha1:84dd229a9a3f9cf61b6be86a544bece3187b5c22 - pristine_git_object: 0d87a591d2b5c92c347c166731dced9c89da0330 + last_write_checksum: sha1:93bece11a36bb7953324f8a6999f94c31c847a4b + pristine_git_object: 77732fcd46db281be7c884c4ca5a6426b3110750 src/glean/api_client/models/platformskillupdateresponse.py: id: 4a7d3fa0c78f last_write_checksum: sha1:ea15b9e50758327fe3bb81eeae59c81f226dcc6f pristine_git_object: b508a52fe52301ac4c371126c3ea8f09d411b6a8 src/glean/api_client/models/platformskillupdatestatus.py: id: a1d6763af4bf - last_write_checksum: sha1:3655d3529f2bad31a7424a908deaa69afc46782b - pristine_git_object: ede7b308d849e5253a989fd75bd3485b16bed70e + last_write_checksum: sha1:9d2335cb91a2e2c0ae3488a36dc8d8fc47214d12 + pristine_git_object: 50cf71de015a456447b8260ae703304c5470862d src/glean/api_client/models/platformskillvalidationfile.py: id: 840ce4c25e59 last_write_checksum: sha1:a179e1a787bba71733234145ad88e9dd3350cd5a @@ -6438,8 +6750,8 @@ trackedFiles: pristine_git_object: 828ce5457e0a36292852e503244f1af9a23429e7 src/glean/api_client/models/platformskillversionslistresponse.py: id: 6ffeabf770b5 - last_write_checksum: sha1:0a3bd8c4cccd599f3fea52d575eefd59d83c7e0f - pristine_git_object: 2ae04090bb81ff38aeed222fbb2330e20d169eff + last_write_checksum: sha1:5a7d3f257969977964f675198fc992d98a4a24ab + pristine_git_object: 37b4b1c81f298ffdc3060a16c62ce1db60834236 src/glean/api_client/models/platformtimerange.py: id: bf2b03e84949 last_write_checksum: sha1:645217a3827cd2a7455b88277f1ba2dcd4a5daf1 @@ -6548,6 +6860,18 @@ trackedFiles: id: e0f28c4af07a last_write_checksum: sha1:e1035b1e52647d0cba1a2d784e92e70ac9ecd425 pristine_git_object: 43b0b789a24961eaf150cd49ac1fc4aedeff3281 + src/glean/api_client/models/platformusagesettingsresource.py: + id: 5ad533f34e91 + last_write_checksum: sha1:4575a42595336120fd4bd5e1853db972aa28664e + pristine_git_object: 668619d0ee0a0eae87884c9fdde131bae73145bf + src/glean/api_client/models/platformusagesettingsresponse.py: + id: 3ddf07c5ec8a + last_write_checksum: sha1:e898aab305786011be2e72994f8a63a85b9e2e35 + pristine_git_object: 6e9979151d0576880094ae05f3024042e8ed8dd2 + src/glean/api_client/models/platformusagesettingsupdaterequest_union.py: + id: 7fdb778e5e62 + last_write_checksum: sha1:69c20c4ec7d6c86e92d7974321dd5c17da830edd + pristine_git_object: 229beb91e9acbaf8feff694eb0e940d1a37bad1f src/glean/api_client/models/platformwarning.py: id: b99ca6ee1c74 last_write_checksum: sha1:4e82a608e924c72338481e61b2e51fec9e447605 @@ -6982,8 +7306,8 @@ trackedFiles: pristine_git_object: 8b5a32ccf25fcfb0fb904e8046bf1b36110a3880 src/glean/api_client/models/ugctype.py: id: 9afda9fb9dd7 - last_write_checksum: sha1:3464ec5db301fcfece53e316e4325f69ef3b4f9b - pristine_git_object: a628cc8f00ce32c24ed9b022d6ed64e4bf1db2dd + last_write_checksum: sha1:c4ba5152fbf0a17867802a623278a8e56064bc4f + pristine_git_object: 01c9179afe6b224cfd50edf19752e43e7d962979 src/glean/api_client/models/unauthorizeddatasourceinstance.py: id: d3507c78b8df last_write_checksum: sha1:e86e33256eecf3766c2cc9fedeab56e34e0f129c @@ -7182,28 +7506,28 @@ trackedFiles: pristine_git_object: 3a4c3e6eee14c25616dbc8cbec206d9a74070d80 src/glean/api_client/sdk.py: id: e2de37b3ce92 - last_write_checksum: sha1:5d8613780a840ea8e2a3981406cd7d6c6064ea41 - pristine_git_object: 4efe2dd7071b0043e18c04b36398978c357f8255 + last_write_checksum: sha1:30b797f1024cf89c96819bab87630dd7055a729f + pristine_git_object: ade34d5fe52936be31df90f1d3beaf39c729e4dc src/glean/api_client/sdkconfiguration.py: id: f356ce00b5b7 last_write_checksum: sha1:1ae43e08ae57ae277b3ab5e66b52d020149ebe00 pristine_git_object: 22e0a4eab0ef8e54dcfd986084d01c14a56f47a6 src/glean/api_client/search.py: id: a3b404a8b402 - last_write_checksum: sha1:4c0766eb4af35b2cabd60ee4b3d0d1d617ef11ca - pristine_git_object: 0c1935e06607a39d513f45b02bf52a155a8614cd + last_write_checksum: sha1:b2c68f6baaabeaf0e14fd6e77dbde9bb80802696 + pristine_git_object: 7150efbff6e08314d6f576f8c0c38235d0e41db5 src/glean/api_client/skills.py: id: 79f3c37e1b5a - last_write_checksum: sha1:aebe5c9b6e2b24a13332ca13160d3994e008e477 - pristine_git_object: 89e97e10c092905a2b012a8f05f8fc986d018c6e + last_write_checksum: sha1:a9f6ddb1d28b6428e95bbe4c842e30a75f2b197b + pristine_git_object: 4a80b99769c3996fe837b41a2a41ce2c2a24372a src/glean/api_client/tools.py: id: 3ea40147c1cc last_write_checksum: sha1:017a12cc5b3fdce612fdb317a468b370e5100cc3 pristine_git_object: 702acd70ae3e1296fbc0346dac0870d4e3d1b16f src/glean/api_client/triggers.py: id: 9fac703b5844 - last_write_checksum: sha1:d69e3d7a3d4cc92b7ee4a37e61c976bf6b36351b - pristine_git_object: d05463361ba35042adb30f476181c9eb36ad4d5c + last_write_checksum: sha1:289fb16e30d0b9e1523f278b4bfb0e95f10aff26 + pristine_git_object: 3bbd7579fe769c115a3563915231b013cd30b5ab src/glean/api_client/types/__init__.py: id: f63c790831ee last_write_checksum: sha1:f9ad14217f832e74f594285960125add50324be9 @@ -7216,6 +7540,10 @@ trackedFiles: id: 436a12e02484 last_write_checksum: sha1:10d84aedeb9d35edfdadf2c3020caa1d24d8b584 pristine_git_object: a9a640a1a7048736383f96c67c6290c86bf536ee + src/glean/api_client/usage.py: + id: 0b70da024ea5 + last_write_checksum: sha1:40eed17f351558684cca84c3973529c8ea8be50e + pristine_git_object: 7db5ca187985eef5871c6f667e51176634fcccce src/glean/api_client/utils/__init__.py: id: d681dc4f06b3 last_write_checksum: sha1:e6fb1146e02dbccdc147eb3724b57e71568b8391 @@ -7226,8 +7554,8 @@ trackedFiles: pristine_git_object: 12e0aa4f1151bb52474cc02e88397329b90703f6 src/glean/api_client/utils/datetimes.py: id: cc5f732df6a7 - last_write_checksum: sha1:fa47d54c549ff9b95496ce91930fadfb04a36be9 - pristine_git_object: adad24762cf452d137abe94fda0fd26224cef593 + last_write_checksum: sha1:dcbdac8f63789f5d41b64d4d0515db77961e1d0c + pristine_git_object: 688c29a59b33a38c3b8bd3276f89c98483fcdb58 src/glean/api_client/utils/dynamic_imports.py: id: cc87d9ea2304 last_write_checksum: sha1:a1940c63feb8eddfd8026de53384baf5056d5dcc @@ -7282,12 +7610,12 @@ trackedFiles: pristine_git_object: d65a9662fbd980da32b4a2af7066036450a09c01 src/glean/api_client/utils/url.py: id: 1e37881af992 - last_write_checksum: sha1:6479961baa90432ca25626f8e40a7bbc32e73b41 - pristine_git_object: c78ccbae426ce6d385709d97ce0b1c2813ea2418 + last_write_checksum: sha1:0269c7e27f701e0c72d44bc2a36ac4d44ef2108c + pristine_git_object: 8eeaa7b0cc48e5e528afc0527da8b76ef46308d4 src/glean/api_client/utils/values.py: id: 3c2d5aa49b0e - last_write_checksum: sha1:65e1ee8607767a4fc1ae7a55c74d77a23ab3cef1 - pristine_git_object: ac217f473c5d52a454a2979b3eb35e66175d365c + last_write_checksum: sha1:c0eaaf8779a4ba3ae068579a57182667efef0cb7 + pristine_git_object: 094755b73f7f9382d8df997602080c82a55896fd src/glean/api_client/visibilityoverrides.py: id: 85e53a1c5de5 last_write_checksum: sha1:633cf3b5b0f1f2e4359d271a3a678a229e95f20a @@ -7354,8 +7682,8 @@ trackedFiles: pristine_git_object: 929558ef2e1165f7e09da6d0a64f016c90971655 tests/mockserver/internal/handler/generated_handlers.go: id: 61ac4f7cce9e - last_write_checksum: sha1:76b084b327cf42ef0df8fc6100203c03d8fa6562 - pristine_git_object: 0bea5676f41873a3d0f0fe7ce14292bf5bf4455e + last_write_checksum: sha1:2232b3efbb244a064d8c92e18b020e017653da59 + pristine_git_object: c1637f6de68fbe838201d1a4d7c7d368c2eb56dc tests/mockserver/internal/handler/pathdeleterestapiindexcustommetadataschemagroupname.go: id: 979e4583765b last_write_checksum: sha1:b1d4edb259d907c7a88b634bf16f0cf152321693 @@ -7364,6 +7692,18 @@ trackedFiles: id: 502db61f4b70 last_write_checksum: sha1:4ac03fda8cf26645eda1638b75f8c187ae7cf500 pristine_git_object: ff7097f855b75a46f88c437dfba247c1a1c17e52 + tests/mockserver/internal/handler/pathgetapiadminusagelimitincreaserequests.go: + id: eb652efde4e7 + last_write_checksum: sha1:a6cb484aaac218c70096705bd2182a8c73bfabb1 + pristine_git_object: 468ea6c386ee48c046a41864dc6cbcb82335861a + tests/mockserver/internal/handler/pathgetapiadminusagelimitincreaserequestsrequestid.go: + id: 9ff312bd0e5e + last_write_checksum: sha1:24ca59ba1e4b4bd0d0e0318054ca59eff067db77 + pristine_git_object: 20caa9fe5c09131ee1a83fb83fbadefa46063ce6 + tests/mockserver/internal/handler/pathgetapiadminusagesettings.go: + id: 4b7cd28168cb + last_write_checksum: sha1:68a44dcec3c3dba6af40d35fb229779906147286 + pristine_git_object: c67f41c32fc994c23bb7597a19986af28763a737 tests/mockserver/internal/handler/pathgetapiagentsagentid.go: id: 118e0c46ba00 last_write_checksum: sha1:8ad0cc0ad413e34c3d950ee07ccd13ce861a261b @@ -7382,20 +7722,20 @@ trackedFiles: pristine_git_object: 61dfb292ca694340fd9796a891113cfb07aa8a32 tests/mockserver/internal/handler/pathgetapiskills.go: id: a1697453079c - last_write_checksum: sha1:1608120c2f9ce748fdd2d373e576b6a0758092c1 - pristine_git_object: 7baa51e79fd4c8ed0f5c9ebadf5030c74e966973 + last_write_checksum: sha1:a55e5b037d9f0e456da29cb0a42a885f008d6b1e + pristine_git_object: 7eb2a3a1fc9f63f752f7890d231e2f2aab702211 tests/mockserver/internal/handler/pathgetapiskillsskillid.go: id: 97a0dcaf8ddf - last_write_checksum: sha1:d939db8a7f6d6e5b3e09402246efd0d1b53c44eb - pristine_git_object: 4f097d8448491dc032cba2fdbb1f9aae85f80600 + last_write_checksum: sha1:24aa74ef2592dcaaa912f1b9fea68c7662f39f76 + pristine_git_object: 7e0b98d73ed1b22de3957e3450a027046599a2dc tests/mockserver/internal/handler/pathgetapiskillsskillidcontent.go: id: 5a0bd6fb5b08 last_write_checksum: sha1:9765b1ebe84d20e2dd85613fc06fe22d1480315f pristine_git_object: 4a1564dde9fce01753cc7f40030578593bc5b2b5 tests/mockserver/internal/handler/pathgetapiskillsskillidversions.go: id: e8b9995766c3 - last_write_checksum: sha1:ceff593610562de91fd47b0694d8231834f8f8b2 - pristine_git_object: 878e7567ff9bba78baaa03b2a59c2b82f641d4a0 + last_write_checksum: sha1:44fbd551c419ec13c7ea3def121f8a5c3cf0ae72 + pristine_git_object: 41840fae0388e7a4ac5e650a546a1710952693c8 tests/mockserver/internal/handler/pathgetapiskillsskillidversionsversion.go: id: 6b886ba93965 last_write_checksum: sha1:66539864b0089984ac709c946711d854bc4a1930 @@ -7424,6 +7764,14 @@ trackedFiles: id: 024861a723c9 last_write_checksum: sha1:d0a4340ac6287dd0ffc9e84723ee95f72f2f661d pristine_git_object: 0ad3c036c63130546598a4ed5a6c497d980eccaf + tests/mockserver/internal/handler/pathgetapiusagelimitincreaserequests.go: + id: 55d35b26b573 + last_write_checksum: sha1:e15bedd00c70d7afaf5b7cecea933fd2bdd4b76b + pristine_git_object: 5aea708ce110ba3f9a9fb44d5a81ecf498791611 + tests/mockserver/internal/handler/pathgetapiusagelimitincreaserequestsrequestid.go: + id: 07ace3628800 + last_write_checksum: sha1:54b60d706f10add0a711d0dbee023a42fd841920 + pristine_git_object: 8870512cdf8e0aa4847a03dfebf6ae9f4390af8c tests/mockserver/internal/handler/pathgetrestapiindexcustommetadataschemagroupname.go: id: a14a30d0e377 last_write_checksum: sha1:83a992c70c3b7d010928d89a52f70db1042dd186 @@ -7480,10 +7828,14 @@ trackedFiles: id: 1598fa297cf6 last_write_checksum: sha1:8b0d26cd221009e78396ed0c573e78c0ac719e36 pristine_git_object: 163466cb44aa1a16439b3bd65ab52f00aeeff427 + tests/mockserver/internal/handler/pathpatchapiadminusagesettings.go: + id: adc58fb1e3c7 + last_write_checksum: sha1:d964caf6ec38febf399bd2f8d6b4b9f4fa0901b0 + pristine_git_object: 53d7718e16f99b5f1f33f19d36600a04e42af218 tests/mockserver/internal/handler/pathpatchapiskillsskillid.go: id: e09721a8879b - last_write_checksum: sha1:90c425f15814afd0ac42817b7ad6a056b6efc278 - pristine_git_object: 2b4d9db548fd58503a768732db17aca59d354d25 + last_write_checksum: sha1:f2d567eb1aa2e0b539119f09ce5a1d18326aba1c + pristine_git_object: abc15386116735f44ec67a9fa7801f55973961ac tests/mockserver/internal/handler/pathpatchapitriggerstriggerid.go: id: 76c9eb373567 last_write_checksum: sha1:e444fbfab92b77e23c98fd0e33531018450185ed @@ -7492,6 +7844,10 @@ trackedFiles: id: 24dd79d2c474 last_write_checksum: sha1:14d3e93a3f37b61145188a9e6544398fcfc200e4 pristine_git_object: 40105d8daeb4ec2dd77c36244a4db0e63b847ee1 + tests/mockserver/internal/handler/pathpostapiadminusagelimitincreaserequests.go: + id: 6213bd49fa5b + last_write_checksum: sha1:ee11766299e1b198f9ac4d7041e7734c820c2a0b + pristine_git_object: f4024d9b259343456026bfb74a907a00cad539dd tests/mockserver/internal/handler/pathpostapiagentsagentidcancellations.go: id: c7e3aaed90f3 last_write_checksum: sha1:6fd6979475ad5d59149eee88cd9b965a4f80f384 @@ -7634,24 +7990,24 @@ trackedFiles: pristine_git_object: 1e3fe6a9bed655ba32d7c59fe577f41beac69da8 tests/mockserver/internal/handler/pathpostapiskills.go: id: 8ed490cc6d95 - last_write_checksum: sha1:5749c3cbb8d3cc90c75ead5cd6547775e97d1ef4 - pristine_git_object: dfe54aafb86188b641df7d3f4ab98fba364b68c7 + last_write_checksum: sha1:baf2227d6bd2c85e94842170a811ed97ec2e2b5c + pristine_git_object: d69982892fc128b84300a4507e9fe1d15ade935b tests/mockserver/internal/handler/pathpostapiskillsimport.go: id: 07a47818c029 - last_write_checksum: sha1:41bc34387c843be0cbccb2bae4af32a7112e76f7 - pristine_git_object: cdcc73daba6ec8b34a04797674ce757cfce51e6b + last_write_checksum: sha1:4410caa65fa50da5b941547b5dd17b1e2c68ffb9 + pristine_git_object: 6c82be5d55724173c78931456a028f514902d293 tests/mockserver/internal/handler/pathpostapiskillsskillidsync.go: id: efdd0a8f2a3d - last_write_checksum: sha1:39cdf62ad6655c214bb0e38092b0464862e0a039 - pristine_git_object: 0cab544fc9c247c4b5f8d19a1e83d47996c7501f + last_write_checksum: sha1:a2081eecf8bdf5a392d788a9b87182ec59450af8 + pristine_git_object: c54314faee70f92e1a882b7a12f3bfcfbbec8638 tests/mockserver/internal/handler/pathpostapiskillsskillidversions.go: id: f6e6dcee5ffa - last_write_checksum: sha1:5a244bc3c1b083e78d22e3358ac4691ece188428 - pristine_git_object: 1f3d1fde1c6e5db9a85a116b88255e61a451fab4 + last_write_checksum: sha1:44b93ca1008e2dfd4a3ab346fd3159690f2e7185 + pristine_git_object: 664245fc17546fda61773d1dabaa8aed1c55a59e tests/mockserver/internal/handler/pathpostapiskillssourcespreview.go: id: 58d10f72cfe6 - last_write_checksum: sha1:f648c8848f17daa6b1777d48cddfa881ff0a6d2f - pristine_git_object: 11e0efcabee999d01568917c5497ea70e3804e62 + last_write_checksum: sha1:e3f49b6ee23218bbcaadd4c2dc2a5345be4251a7 + pristine_git_object: f8a79c8f6f62b627e17d9493adf18d4bbcbfa5ba tests/mockserver/internal/handler/pathpostapiskillsvalidation.go: id: eaa6c1478b34 last_write_checksum: sha1:cc8f959924866fdf5febe729b5d5819ff7e53173 @@ -7668,6 +8024,10 @@ trackedFiles: id: e27c1d4cb373 last_write_checksum: sha1:0af9ebb63a29cdd0b59d7ebb82a02f6bf24f3a20 pristine_git_object: f356922816acb43e8b460878976b761b424fea2f + tests/mockserver/internal/handler/pathpostapiusagelimitincreaserequests.go: + id: 8049be7e5b29 + last_write_checksum: sha1:9748a83df7f06e95a795a47140dcc126fa4cde14 + pristine_git_object: cbc96cd77cfbe2199d71fb61340004b3fb1eefae tests/mockserver/internal/handler/pathpostrestapiindexsubmissionsdatasourceinstancetype.go: id: 1a5daf7874ce last_write_checksum: sha1:b5b37f0b5a7b4d9a4c69ab523e831f1702301118 @@ -7726,8 +8086,8 @@ trackedFiles: pristine_git_object: ab9263d43404e8e6f07af222a3e785aca2fbf35f tests/mockserver/internal/handler/pathpostrestapiv1createcollection.go: id: 3fb93a419933 - last_write_checksum: sha1:7b2ffc9e36bbfc20c3bc1894f3727f96aa94ac74 - pristine_git_object: 75fb8eb70f6913c8f83c2895f5542bee631ffdaf + last_write_checksum: sha1:09a57acc1d004a2fff76290b6c25e24471ad333e + pristine_git_object: 469bd6e6ee30bb11661f2a596a4504b75fa07da0 tests/mockserver/internal/handler/pathpostrestapiv1createshortcut.go: id: 8d9d3abb0c34 last_write_checksum: sha1:dcdf684a85e20db1aee571db9a54a3ee259d71d5 @@ -8100,6 +8460,10 @@ trackedFiles: id: f5c8280eeff5 last_write_checksum: sha1:5d7841e6270918e5e1b59873c394d8a0b2eb1bc9 pristine_git_object: 13c623198b89959d69b58e6ccc7c73a0a022d4d0 + tests/mockserver/internal/sdk/models/components/artifacttype.go: + id: 531dffc323b2 + last_write_checksum: sha1:e3bbbec36f39ab4e8a4954a397d6065d804e9e42 + pristine_git_object: c07eb6aab361c53cee6508dad5b3e4a8d657b961 tests/mockserver/internal/sdk/models/components/assistantinsightsresponse.go: id: 8ca7fffccbde last_write_checksum: sha1:cf4bf37d272fba27bfe92b0f3e39f073550a4fb0 @@ -8138,8 +8502,8 @@ trackedFiles: pristine_git_object: 774930f21f6761e703d10082d6fd42bd5d7c5c32 tests/mockserver/internal/sdk/models/components/autocompleterequest.go: id: 56aa024b9118 - last_write_checksum: sha1:86415b3329533a2415815b14551f11a9c3dc3c3e - pristine_git_object: 2b02c414795216c099acd4479055f09d9c3d5492 + last_write_checksum: sha1:63941c26209efd373583eab713bf1a7f7c15f836 + pristine_git_object: d3de9d57317f6d2a6bb29809b40dbb35d2a75138 tests/mockserver/internal/sdk/models/components/autocompleteresponse.go: id: 66cd6764f2df last_write_checksum: sha1:ac7d26f25b2828f520494f4fbe7cd7c2beb9f44a @@ -8302,8 +8666,8 @@ trackedFiles: pristine_git_object: 33e8680da35e1cedaaa8ca6a0d98c1a564f6b7a1 tests/mockserver/internal/sdk/models/components/chatsuggestion.go: id: 33e4338b5b24 - last_write_checksum: sha1:40e54396ba6c59a5a6e92c49fd2c1a62af9d0dab - pristine_git_object: b8269ceb3de0ce38bec7ff3626ae677546e8a646 + last_write_checksum: sha1:498d32b82301d6117a5f7cc13beb4c8fca6bca9f + pristine_git_object: 73c2c22242eacc81aa8fa758f5e9d9537284d981 tests/mockserver/internal/sdk/models/components/chatzerostatesuggestionoptions.go: id: a6d088eab1c2 last_write_checksum: sha1:da633547681ec1c8ef5df79cc1d2919fb3714d13 @@ -8906,12 +9270,12 @@ trackedFiles: pristine_git_object: 04cc3a93272ac70933b0485bee31b335e05ab623 tests/mockserver/internal/sdk/models/components/feedentry.go: id: d25fd66fcf7a - last_write_checksum: sha1:f0a0c2321e2aff01b51b21b61df68d95f5ba979f - pristine_git_object: 44f5dfe7632e9ca462176445542fe70166921464 + last_write_checksum: sha1:a5c453b80a8cd765da109f17e128bcc57c418669 + pristine_git_object: 44e6f90dd617a59fce764b859519dc4e3493269d tests/mockserver/internal/sdk/models/components/feedrequest.go: id: b06bc4cef0cf - last_write_checksum: sha1:dba9418e46ca3f7d4fddec08c66623f9771d590d - pristine_git_object: 9489bdd527389d50e3826ebbeedc8de805528e57 + last_write_checksum: sha1:f70dc70fb6a3a9bd40567c898babf2f960b5f342 + pristine_git_object: b89f4ded9d810d810ba2c40da5be15273df10e21 tests/mockserver/internal/sdk/models/components/feedrequestoptions.go: id: fd9245fe1bf2 last_write_checksum: sha1:fa30b7fd6ee3e45896d7bbe36e33e7c0cb9000ba @@ -8922,8 +9286,8 @@ trackedFiles: pristine_git_object: 54f9d1a8997983156c84e69f888c59a80d06c2b1 tests/mockserver/internal/sdk/models/components/feedresult.go: id: 47411573e67a - last_write_checksum: sha1:ecef21a7754d70942718bf1dc156a8222c8fa36d - pristine_git_object: 4d9a33d3f245e67bb3d7ace1b5396672c73e236d + last_write_checksum: sha1:26eed6dc44ec225ca2646173c7c3e9c89fe112c4 + pristine_git_object: e2417ff8956ef297c8cc96de44535c47977574cd tests/mockserver/internal/sdk/models/components/followupaction.go: id: 38179fec19b1 last_write_checksum: sha1:32a31f7af77a58ce6f3284e8550d01fcf0d3bddd @@ -9256,14 +9620,18 @@ trackedFiles: id: ca109f859575 last_write_checksum: sha1:9c066d47590c5ee9823f57a51466268e2893a13b pristine_git_object: 23fb1a7da94ab17bfa0b54a45e12eb0ec3f59562 + tests/mockserver/internal/sdk/models/components/mcpauthmethodbreakdown.go: + id: eb802c4e50f1 + last_write_checksum: sha1:75d07caabd32a8e2f1c5afbbb860a089c38e7aad + pristine_git_object: 31f4103f51a93dd9d1e9ca159af4bb3130b46e32 tests/mockserver/internal/sdk/models/components/mcpbreakdowninsightsrequest.go: id: 9ffe49fd371c - last_write_checksum: sha1:70341128cd46d9472de34bd3d58ac377f37d2580 - pristine_git_object: ef9a081c408459b7ef665bc6b1e89ea05b242fcd + last_write_checksum: sha1:858cf5856b7481e360f1efd293a4582492d7bb61 + pristine_git_object: 4c60272bbcba0911bc2684da073da9095c08dede tests/mockserver/internal/sdk/models/components/mcpbreakdowninsightsresponse.go: id: 1f8eda5070e3 - last_write_checksum: sha1:8ecbd57e51bbd9b0690f74d66880087074a626d5 - pristine_git_object: 8ae55f171cc531a1b7f9fea7670d103b08191d7c + last_write_checksum: sha1:14fa07488478c7de7b3372085d86f60678f1d738 + pristine_git_object: 2383c4eab02e6df47904eb07708bb85696cd638f tests/mockserver/internal/sdk/models/components/mcphostapplicationbreakdown.go: id: a9ba91d64581 last_write_checksum: sha1:ef6e565d96b5253d5970fd5dd608f87cbe2f1cbe @@ -9286,8 +9654,8 @@ trackedFiles: pristine_git_object: be104ab72b0dbd45c2b852529cbf96985258066a tests/mockserver/internal/sdk/models/components/mcpuserbreakdown.go: id: 3796e6d874c0 - last_write_checksum: sha1:115c39fb75461e557499b7aebaac070fcbcc5af4 - pristine_git_object: 73014b6f5dd71b9d05fe8935098102f1ca034101 + last_write_checksum: sha1:2bba6e439cec02602b0983fc459ea126462bbe05 + pristine_git_object: 045685a2258bedb00cfd45a99d7db15e44b47e7e tests/mockserver/internal/sdk/models/components/meeting.go: id: 104e13d174f0 last_write_checksum: sha1:3cf5bc5fd2b5a40c545bfe1d9f768a98c3360d11 @@ -9326,8 +9694,8 @@ trackedFiles: pristine_git_object: 1432e9ddd5212e0f1142ae4ceefbf7e75c7e5805 tests/mockserver/internal/sdk/models/components/peoplerequest.go: id: b9eb3293a335 - last_write_checksum: sha1:ed92d35b9ee73fab4f70e9aaab17f6ad7c9351cf - pristine_git_object: 1240c00e54f6f5c4493022e643470ffd9011b8ac + last_write_checksum: sha1:d1a5b495e37ee65c5b191bca851f439330f87cdc + pristine_git_object: 4d75414bba70fd50be626d32415fdb6c58245207 tests/mockserver/internal/sdk/models/components/peopleresponse.go: id: e570c57343b4 last_write_checksum: sha1:370070abc7236a46218b5d2eeb74f00a4a082aba @@ -9350,8 +9718,8 @@ trackedFiles: pristine_git_object: f9056e4fc9da37d708e834fc6731ba114ce05981 tests/mockserver/internal/sdk/models/components/person.go: id: 11bb88f6a505 - last_write_checksum: sha1:205cadebb2dd56343e3985b090b1532ace9838e0 - pristine_git_object: ab2c5f86c9d1327bfde1edcb7706392180b8b8fc + last_write_checksum: sha1:e14e9cc2a0e35848bb4635516af18cf3b50b8943 + pristine_git_object: e3bd94410f6abc514c06fe966587bba221702eaa tests/mockserver/internal/sdk/models/components/persondistance.go: id: 38ff917355bb last_write_checksum: sha1:b1c7f853fd358135eeeeeebe8911abcefb0f646a @@ -9408,6 +9776,10 @@ trackedFiles: id: 531e55c09141 last_write_checksum: sha1:b36aba6678be9f8a1b18e6e901f1671dcdebd0a3 pristine_git_object: 3df4f65db7b472cc1bb0fec6603e80830ddd938d + tests/mockserver/internal/sdk/models/components/platformagentrequestcreate.go: + id: 60c69615a755 + last_write_checksum: sha1:2a046cd63fc847af2819ea24c828f13a32b91a3a + pristine_git_object: 3f011c1aa1751062e6685a42decba0ac4def6af7 tests/mockserver/internal/sdk/models/components/platformagentrun.go: id: d12a92c365e5 last_write_checksum: sha1:c39a6b74fe9c30850bf5bedd6827577bf4b56566 @@ -9462,8 +9834,8 @@ trackedFiles: pristine_git_object: ba08e943e4a74ac111304125d6085f642a522085 tests/mockserver/internal/sdk/models/components/platformauthenticationsuggestion.go: id: 48f115d1756f - last_write_checksum: sha1:1a05a8e9c2ce9f6db1c96831eb05f6dd2cc0abc8 - pristine_git_object: 58281ae6e982ccb6e585a3299a3893a5850cfb3d + last_write_checksum: sha1:6d1eae6baac1ea0a8d42a87a076548005e48e016 + pristine_git_object: 30dae6db4e416edd64d86dc6f4579b0f4bb388b4 tests/mockserver/internal/sdk/models/components/platformchatcitationannotation.go: id: f4acfb6b571a last_write_checksum: sha1:9c897630b1c2064f01239d038de95ad8131779fa @@ -9608,6 +9980,14 @@ trackedFiles: id: 7daac12f5ae7 last_write_checksum: sha1:49fd1240cf9eb9d2259465f79e0c481d711ec37d pristine_git_object: 7515a2832f306164806fae459e9a995d37b70b78 + tests/mockserver/internal/sdk/models/components/platformlimitincreaserequest.go: + id: 6afd77e19a4d + last_write_checksum: sha1:cb01e7b0a536a4a0931ef24b78e2edec545f8298 + pristine_git_object: 393f1ceb32a7fcb6e9917b6a3d89658fc614ffb4 + tests/mockserver/internal/sdk/models/components/platformlimitincreaserequestsettings.go: + id: 3e6ce2f4d7f7 + last_write_checksum: sha1:403a1cb4094fa247b7d523f4e22d0f64b24d938c + pristine_git_object: 90402268470c4234cc9e0893ac3cec4171b9aaf4 tests/mockserver/internal/sdk/models/components/platformmessage.go: id: 5eb3e8c3fd80 last_write_checksum: sha1:3051abc1ef3e40cd0385bd9846c987d3ebfbcbbf @@ -9628,18 +10008,58 @@ trackedFiles: id: 3a3335fcd639 last_write_checksum: sha1:6a66d3af6869882eba15c10a8598bbac9443744e pristine_git_object: a2f9800f6c38ae73cda44bafede4ab6d202cbe0f + tests/mockserver/internal/sdk/models/components/platformmultiplemembershipresolutionsettings.go: + id: f7494b4526fe + last_write_checksum: sha1:6822795a9e3b82368a32baded6451d3828a89e34 + pristine_git_object: 53a3c4a0d408ced0cc643cf284d1b2a965373003 + tests/mockserver/internal/sdk/models/components/platformpermembersettings.go: + id: 4675fc618817 + last_write_checksum: sha1:3f53028f0beb47ae72df7a7917cdb2fdf563743f + pristine_git_object: f28f77cbdd19a0a26d7ae8cead024761fc9c17da + tests/mockserver/internal/sdk/models/components/platformpersonalrequestcreate.go: + id: 648b9dc8b7d2 + last_write_checksum: sha1:c2bfdc5ad48ee4b203953722c71b5f4c5a87313d + pristine_git_object: 0ce82dd39e499b80873d858870489d0b09234bb3 tests/mockserver/internal/sdk/models/components/platformpersonreference.go: id: ebc5c183c98b last_write_checksum: sha1:91afcf6171cafdd18d638818711fe0f3a0ba1021 pristine_git_object: dca6a6f855816c3598a9a1fa69c72f131eefa1c6 + tests/mockserver/internal/sdk/models/components/platformproblemdetail.go: + id: adae7c75e138 + last_write_checksum: sha1:6f8702f1324b66ab2c612fe3dd02faafff2578d1 + pristine_git_object: f4cb5aa31bd82d3c0efbf7a32e98d757bfd4956c tests/mockserver/internal/sdk/models/components/platformproblemdetailcode.go: id: bc7ce56d1a6c last_write_checksum: sha1:3ddc9b692878c2d8af88aedbcf4c03174f91daad pristine_git_object: f7a60ae68c37856df51bb53227d89c870f9c9c27 tests/mockserver/internal/sdk/models/components/platformproblemdetailerror.go: id: 045ae4dc7a98 - last_write_checksum: sha1:4d135d9e4dc5967a64bab866df79f2fd689caae5 - pristine_git_object: 058f5e62bda5173fed3b24fff078d7540a1378f7 + last_write_checksum: sha1:f405e92536a5c01c0bb302e106a2a6001005cbf7 + pristine_git_object: e013d6443bb4ba66882b22a5d9086f7d698fbed2 + tests/mockserver/internal/sdk/models/components/platformrequestfilter.go: + id: 88188d537d7b + last_write_checksum: sha1:f00e10d8d963d7a3d34a38bc6ce7021bd3c62b8d + pristine_git_object: c5e0054345899273a2f483f6e8c8df9baacc12f7 + tests/mockserver/internal/sdk/models/components/platformrequestlistresponseunion.go: + id: 0a0b02d4bd57 + last_write_checksum: sha1:fbe2f912ebf82d6862cb269b08fff344a702423c + pristine_git_object: 56769fc9022fff56aa2746109d48bc82d953a7d3 + tests/mockserver/internal/sdk/models/components/platformrequestresolutiontarget.go: + id: 9f19576e798e + last_write_checksum: sha1:0f2ef73b49a1c04730e26fb946c397ba0aedd469 + pristine_git_object: 59492e1e6784a996da7f90d3f161509c154061ec + tests/mockserver/internal/sdk/models/components/platformrequestresponse.go: + id: bfe02e9bcebc + last_write_checksum: sha1:3ffee97a2e9bd0227ef2931fc5e8abdbef98856f + pristine_git_object: 2c168309580fe61b17162cdffff32f40040c0e3a + tests/mockserver/internal/sdk/models/components/platformrequestscope.go: + id: 865f99ae3ddf + last_write_checksum: sha1:5a07ae0198a6f85b94164d501fb64873aa0ebd5a + pristine_git_object: a032d93a7ff49d18a7e4c7b62a28e9745e47afcf + tests/mockserver/internal/sdk/models/components/platformrequeststatus.go: + id: c84a177da588 + last_write_checksum: sha1:7b9fb534042553e8517da7ff780936fdc1a8aece + pristine_git_object: e6d3ad943904c77bb993c0cc869d2b29517408c5 tests/mockserver/internal/sdk/models/components/platformresult.go: id: dd777258615b last_write_checksum: sha1:4343640607d8d0421164c0dc16daf5718d65e848 @@ -9658,8 +10078,8 @@ trackedFiles: pristine_git_object: 3eed4668d26f9212f864b7e486d75dbbf920b68d tests/mockserver/internal/sdk/models/components/platformskill.go: id: a97a51039ff5 - last_write_checksum: sha1:8871b58924c180a5565b43c91b58ed79212739bb - pristine_git_object: 8397a89921fdbadf8ff5733049b9faabf554e21a + last_write_checksum: sha1:a28db79567d75b08a04c51f7110db7af1686aeb2 + pristine_git_object: a507f97f20bda5e95431dd0f0d7df2d004cc9102 tests/mockserver/internal/sdk/models/components/platformskillcreaterequest.go: id: 05411c97e4b1 last_write_checksum: sha1:8d732893340e35116cb9768a65fd07dd6e77c6c6 @@ -9678,72 +10098,108 @@ trackedFiles: pristine_git_object: f038a7deff637e79bde341c3b7b30da64979a8c3 tests/mockserver/internal/sdk/models/components/platformskillimportresponse.go: id: 440a9e446bd2 - last_write_checksum: sha1:450ab4711bb5995f21f486cc05fae94264ee840a - pristine_git_object: 262df2a7dfed6e67a02d34a227ba545cbc521e18 + last_write_checksum: sha1:1fc9aaacdbebc73d421d004bd209ce8816213bab + pristine_git_object: 796e0f2e0c70e0ea0b7316b81fb8bc8b9ffc97be tests/mockserver/internal/sdk/models/components/platformskillorigin.go: id: b3f692d12f20 - last_write_checksum: sha1:4bbd57b85b9318d5fa9ea3ca97e26cab34e689fd - pristine_git_object: e0a004498154f0b4285d2d29dde3d0e27b163bb6 + last_write_checksum: sha1:924c28e24a95d203cc3f1be9f067ca1b72ca5fc2 + pristine_git_object: 1afff27476707400c1697c3f22533d9d44e92e3b tests/mockserver/internal/sdk/models/components/platformskillslistresponse.go: id: 61695a856d41 - last_write_checksum: sha1:718c3f3013007de52b02444e4a12d43a10fce37d - pristine_git_object: 566d53518ac6a45dc5ae0ec8e5e55df0433f8ae1 + last_write_checksum: sha1:1727a6f00ad993550964a828e798c5c75a52de84 + pristine_git_object: 55a8d69a0bb440a43cbade924357f664462c137a tests/mockserver/internal/sdk/models/components/platformskillsourcepreview.go: id: "760613548093" - last_write_checksum: sha1:3deb2829d40e4656a75ad550dc52dd3a97a3d8e6 - pristine_git_object: f7a467f1f1802a1a56314879c7666620ca9d714e + last_write_checksum: sha1:04e3eb17f6942925a17829e77f26ab20dde2b4df + pristine_git_object: 85b419fd0742494c027fafacef2ea295bab8f437 tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewfailure.go: id: e2897ced2da1 - last_write_checksum: sha1:6255f8ffe6c9d895d71f4eac788dc31a131b6038 - pristine_git_object: 5a6c6fe802defd21d7d69908b67a24d9b75c50ce + last_write_checksum: sha1:316b2fbb6836b7d12d7deac8313b3aa8c7e273ab + pristine_git_object: 92ed2f8b31775e22c78cc691fe4a616ec69ed2e0 tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewfailurecode.go: id: c9d600e5e25f last_write_checksum: sha1:7cd531f5e341ae1078991bf91345f4a6e32f35c8 pristine_git_object: 0096a29687b3f1e393cb76f6a8f794a20e860eb2 tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewfile.go: id: 7b0601c7fda7 - last_write_checksum: sha1:290db2107fb5e9f550e18a4f13542f391ad04cbd - pristine_git_object: 43503cfb38dcef06b555785d2edce1fe6ec3357e - tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewrequest.go: - id: 292b42c0c32f - last_write_checksum: sha1:f03a4a7dcadb91d7b31ba3a1ddd24bc5b612a7a6 - pristine_git_object: 506e0c0928373629b10db3240532b678e8fe6c42 + last_write_checksum: sha1:9aa7df164105692a1c8c94c58bdc905b0292f2d2 + pristine_git_object: 7622555e6e310e61fe97c2018874a2617652b8e0 tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewresponse.go: id: d14b15a2dcc9 - last_write_checksum: sha1:3fb833b7b4a3bb0b15ca4bba00a74a2de33dcad3 - pristine_git_object: 0607598d7d2a3539a2b4ad5ca38b9baba4402f32 + last_write_checksum: sha1:d441199f3e22acac926b5a9efe954bc9a6ccaf59 + pristine_git_object: 597fec463e80e259d214bab9f9558d7753e9f85d + tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamerror.go: + id: 6c1052e60686 + last_write_checksum: sha1:987b6979fc2edc28720b16d0f3dc46c30aa01260 + pristine_git_object: e1b0e86ee20a08703457d28c27c777b4654e4f7d + tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamerrorserversentevent.go: + id: 2cd2ecb73df6 + last_write_checksum: sha1:e939df04fe9b21db43b972eea9e4317c8e23a8e3 + pristine_git_object: 548ebf7aac1f449aeded1a7c43082ef08666d270 + tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreameventserversentevent.go: + id: 0be12109a543 + last_write_checksum: sha1:419185038a6d4a4e2d4b55e2ee34cb477877d7b4 + pristine_git_object: 3451e40995f399d256e6a2a2c377c53560e10044 + tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamprogress.go: + id: 4d68a2c79d1c + last_write_checksum: sha1:06ce3265abfe814ed64a121287011ab7833cdcde + pristine_git_object: 20885b778b3863d930303a423a6588cdb484da6e + tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamprogressserversentevent.go: + id: 08bebbbd3da8 + last_write_checksum: sha1:a02f1221cf4ed23cbaad7b2e92b6300cb5f370db + pristine_git_object: 76ee67dd91eca6dbe90fc58aaebd1f17470c138c + tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamresult.go: + id: caa717d6ce3b + last_write_checksum: sha1:358ccda38ea775047843b2f750fce1df522a9401 + pristine_git_object: b3070c6757f4e5566f37700dae82b4c73e545fd7 + tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamresultserversentevent.go: + id: adb39b845754 + last_write_checksum: sha1:ce3666888f02122539c2ce18e04c8f3904346432 + pristine_git_object: 9320bc5f1e3af5cb7b470c48afc672af6c74b89a + tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamscan.go: + id: c3b9aa22bb03 + last_write_checksum: sha1:d4e1ef41d9f8dab52da2f074249c72b459629bd1 + pristine_git_object: 118e12737ab1cce6c83e60a57b99e5f48e94fe0f + tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamscanserversentevent.go: + id: ce542da3ad10 + last_write_checksum: sha1:c978a4152705403426e4c70e421afc991715659e + pristine_git_object: f1b6205495b5d248c4a22df9277c9cc1a19e4d8f + tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamskill.go: + id: c94f07da7814 + last_write_checksum: sha1:cd297fc0aa70d3d22d31e2d13fab9f27b4ffb7a9 + pristine_git_object: 2be741fc4cf01ad11b6db6dabd51f2d37066b490 + tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamskillserversentevent.go: + id: f9205770e640 + last_write_checksum: sha1:9478a51994487670379db2b1ac9310b3d542aa1a + pristine_git_object: 7b53e037415d941d93027a0ed2751c51a4768408 tests/mockserver/internal/sdk/models/components/platformskillsourceprovenance.go: id: 3a0b70781266 last_write_checksum: sha1:f64c669b34f9bc8e21d5620001620e8c8a66756f pristine_git_object: 65ed2aacddbc7cb4f5ac6084a8eb21e236b3b377 tests/mockserver/internal/sdk/models/components/platformskillstatus.go: id: d6163aa830e8 - last_write_checksum: sha1:641cb578909b86e1c1166a75e309e5bcf52ecf29 - pristine_git_object: a218b7608eead950ddb62301af0326adc4f091f5 + last_write_checksum: sha1:ef51c4f47afcb3b1776ac211dafb2ca2051a6c6d + pristine_git_object: d47da9c07bd620bc344c9e32a203ed3ecb57c120 tests/mockserver/internal/sdk/models/components/platformskillsyncresponse.go: id: 267c56967302 - last_write_checksum: sha1:b9faeea2e746ab841ea853e4dbdd790b3108117f - pristine_git_object: 773dec5b3554705b262899c6d3bc0c88b1a971c8 - tests/mockserver/internal/sdk/models/components/platformskillsyncresultstatus.go: - id: 3d2ff828aede - last_write_checksum: sha1:eacc4c992746eb655ba515541ad13e83fd6bfeb5 - pristine_git_object: 93f6e9eda63a8156c768b4f69c52638311bcb103 + last_write_checksum: sha1:4a018e2a251697e01ea7b3234a834b16bff8e98e + pristine_git_object: cd8c8278ff2e72e9a3901d4ffef77ec986fd946a tests/mockserver/internal/sdk/models/components/platformskillsyncstatus.go: id: a172da0d9d4d last_write_checksum: sha1:66e29681184c77fbbff593cc30e33023a3b39c81 pristine_git_object: 0582664c1c7451d505bc18ea138e299db160c5a6 tests/mockserver/internal/sdk/models/components/platformskillupdaterequest.go: id: 77853bf3d285 - last_write_checksum: sha1:b327107396570bb07844005756dcbcc502c99030 - pristine_git_object: 16b5b62569411c6e73675a6e4322a5ad993994d6 + last_write_checksum: sha1:f3f5733d0e4b4fe9bfe5e84fb0c2e8d74994c97d + pristine_git_object: 1b12048233685c4f71d09237a656b60c798537b8 tests/mockserver/internal/sdk/models/components/platformskillupdateresponse.go: id: 505fbacea4bd last_write_checksum: sha1:2ef06dfd496e4209ccbdcf6bf246a31b97c23e46 pristine_git_object: 99256154b7dc79f111888a4dff8e90127090bd1f tests/mockserver/internal/sdk/models/components/platformskillupdatestatus.go: id: "511258017192" - last_write_checksum: sha1:b430910b34dda5f1fa8b12d36ad9d40681664464 - pristine_git_object: d40a5b9ff289b22e47722564782e863c1ad983db + last_write_checksum: sha1:c2f69717c45cc61406a2fdf501b9d26319d0e9b7 + pristine_git_object: 46eaa67fe4be82e0ff7ea6b1cf67d3483ec5ec62 tests/mockserver/internal/sdk/models/components/platformskillvalidationfile.go: id: 4c3718b26406 last_write_checksum: sha1:fda63f0276f5a36dca1e5b81fdc3e7b1e7766034 @@ -9778,8 +10234,8 @@ trackedFiles: pristine_git_object: d86476b946a8dd85853c233b93a123eb81b0cfb7 tests/mockserver/internal/sdk/models/components/platformskillversionslistresponse.go: id: 35adfb5fbba2 - last_write_checksum: sha1:19ba3b0df3949f3771d8026290caeb44a9350e42 - pristine_git_object: e6eac47b00f8ce90e72c78ef293dea6e1f933782 + last_write_checksum: sha1:42f6693dcea22369b550da6b9c2a6fc9a950e389 + pristine_git_object: cc6af7a34c50da96df3629b65aa69dc50a8452de tests/mockserver/internal/sdk/models/components/platformtimerange.go: id: cf2540151ce1 last_write_checksum: sha1:3a0ec2ca473681b89ff97606f648fc15fcdae38e @@ -9888,6 +10344,18 @@ trackedFiles: id: 5b5f73675f76 last_write_checksum: sha1:83a4692d9abc1ee07e343eabf32e5cce4c3c7ad9 pristine_git_object: 0a610553debaa7ab04e12b3f81dae01bd59c721c + tests/mockserver/internal/sdk/models/components/platformusagesettingsresource.go: + id: 2ba74791ea2e + last_write_checksum: sha1:a9b5fd717dba09db3e515fb457fcd2bfa314c32f + pristine_git_object: 8b2b5764b3ee476bde1139badf6a800a967185c4 + tests/mockserver/internal/sdk/models/components/platformusagesettingsresponse.go: + id: 38bbd6e5ed87 + last_write_checksum: sha1:78acde88ee70456a616071aa9028b00a0a65d8ef + pristine_git_object: af32749bd6793ae9324a7c4d9c4b6b113a19abde + tests/mockserver/internal/sdk/models/components/platformusagesettingsupdaterequestunion.go: + id: da5a6a2df172 + last_write_checksum: sha1:94cbdac6233961e77c786e8d70f60405c275490c + pristine_git_object: 10a76f27d02c6b0381b35ed2abf183ed29e667c4 tests/mockserver/internal/sdk/models/components/platformwarning.go: id: bf3a0578fb90 last_write_checksum: sha1:4f58e985f8592a928bb3d605f1a8538a5e611d2a @@ -10274,8 +10742,8 @@ trackedFiles: pristine_git_object: 7a6a89805e8b840aa2fae616ef6e49dc3d0e0851 tests/mockserver/internal/sdk/models/components/ugctype.go: id: 7b77277c1355 - last_write_checksum: sha1:653a15069e2fc0cce67579c0871856d42a85f51f - pristine_git_object: 3d7ab4b482de383d8b46f9af9779e1051f9c68ff + last_write_checksum: sha1:2b6f5ff1f6721e2333d1b6e37cde04f7b2263b80 + pristine_git_object: 069786dbc298275bf7eb181639b13d41eab4a4f3 tests/mockserver/internal/sdk/models/components/unauthorizeddatasourceinstance.go: id: bc69d4c4bf6d last_write_checksum: sha1:39fb84396b33bc645fb5e6ebcea36ab88b5db179 @@ -10744,6 +11212,26 @@ trackedFiles: id: b553eb9bdb35 last_write_checksum: sha1:5248f738207e7e99637a538c31c57d93394a588c pristine_git_object: d6f74b3f76e41314e5e33934c50f5bd0bda958de + tests/mockserver/internal/sdk/models/operations/platformadminusagerequestscreate.go: + id: 80f25f0e827e + last_write_checksum: sha1:ceb1b3f653e8fb291cb8ccb4f57e5816c79acac6 + pristine_git_object: d56734d12799f42d0378d492a9cc46307f249304 + tests/mockserver/internal/sdk/models/operations/platformadminusagerequestsget.go: + id: 977b9290852f + last_write_checksum: sha1:4bfd5af36257ca65b6d8e06fe5248e5ece8e27e4 + pristine_git_object: f0a393e86d52c73453037cae16b010ce54c432b7 + tests/mockserver/internal/sdk/models/operations/platformadminusagerequestslist.go: + id: ab510faf746f + last_write_checksum: sha1:2b378e2d9ccea8e86447d32a7dca9556731aceb0 + pristine_git_object: b0a440eb699e3ef5ed3ae195cfee92217fa54b6e + tests/mockserver/internal/sdk/models/operations/platformadminusagesettingsget.go: + id: 5f78cec93b07 + last_write_checksum: sha1:16c6abe3ac7efa05686fc94fa0fcbfa690261b15 + pristine_git_object: 9325e1d553efad7868d8fc0255c2ef1cf76ebd93 + tests/mockserver/internal/sdk/models/operations/platformadminusagesettingsupdate.go: + id: 5951a1017010 + last_write_checksum: sha1:739a97dbf1b731cc38f91bc6ed4e9bc10008f474 + pristine_git_object: 2213378854b56f18702507d3c5407c3687757d62 tests/mockserver/internal/sdk/models/operations/platformagentscancelrun.go: id: 0800b4f494e5 last_write_checksum: sha1:90d511938d50df74af601cab9ebdfda8aee8ecee @@ -10790,12 +11278,12 @@ trackedFiles: pristine_git_object: 8e578bcdd052389777bf51d0140176d523d4a976 tests/mockserver/internal/sdk/models/operations/platformskillscreate.go: id: cd743025fd37 - last_write_checksum: sha1:af1e6384914f9cd0cc653f0492e99ec648168391 - pristine_git_object: 7018793fb9ea00645c22183c434e464e8b1a9b15 + last_write_checksum: sha1:5b08770af61d546cfbeb95768a3f9a874fff1e15 + pristine_git_object: f5a358516f1061ddf869cf52c4f66c6e5381da38 tests/mockserver/internal/sdk/models/operations/platformskillscreateversion.go: id: e864f7a1e300 - last_write_checksum: sha1:71b26146e856969fad0ec9664b6ded57bcbf41cc - pristine_git_object: 554b04385e45319a18190bbce6e683be221cd3d2 + last_write_checksum: sha1:8a603a5c82d8531b6445a806c67dac05cca1ae47 + pristine_git_object: 6a55d73da4ad16aa98b7a027c5c4887d459b4a27 tests/mockserver/internal/sdk/models/operations/platformskillsdelete.go: id: b882924d7f05 last_write_checksum: sha1:e48b3d6e818895e65535b0d98bc69234920a8c8e @@ -10822,16 +11310,20 @@ trackedFiles: pristine_git_object: 05953c0918c11c9a3ee57114361e27026ee81e82 tests/mockserver/internal/sdk/models/operations/platformskillslist.go: id: daa657929c98 - last_write_checksum: sha1:fb44d154d8dcca86575b76dd6fdef213e2a568a5 - pristine_git_object: 40f74199560f03309466234c52f5d5dfaed2f563 + last_write_checksum: sha1:370b051d430a210d9d3a905fe325aae50a1a532a + pristine_git_object: 2286c481cbe0c103dc14c83580a86241be91d2e4 tests/mockserver/internal/sdk/models/operations/platformskillslistversions.go: id: ef57d1f31c39 - last_write_checksum: sha1:60e17abc357b220cb752d85a411402a118b6fde7 - pristine_git_object: 3853971fc3d394241809e862a204df0821c4e368 + last_write_checksum: sha1:2b2d45ef20b064c3904f9f5490c1cb585faf6001 + pristine_git_object: dcea3d13ed01063a2cd11bcefe52e4cd5393e2b9 tests/mockserver/internal/sdk/models/operations/platformskillspreviewsource.go: id: 9228f6ef6a79 - last_write_checksum: sha1:7f93cbe4b5fa4ddafbe7b3e5d7782d48c4290ce7 - pristine_git_object: a32c6102b4d886eb573006e516e5f1047cd5ac2c + last_write_checksum: sha1:57cc85028d47624c7697f5f3668f90b368152623 + pristine_git_object: a189b4a36f3e9b82467eee47d39965f5b51ce436 + tests/mockserver/internal/sdk/models/operations/platformskillspreviewsourcestream.go: + id: d16e8ef0b238 + last_write_checksum: sha1:01f9d7e96b48079c543d765273ef9954ff410c0f + pristine_git_object: f89eab8b3bee36773af12f03ba11a89de9b846e9 tests/mockserver/internal/sdk/models/operations/platformskillssync.go: id: 16804fdbcba4 last_write_checksum: sha1:7525ca186303c98bc1d8104c6aeb506dc64149ce @@ -10884,6 +11376,18 @@ trackedFiles: id: 97cc4ddb3921 last_write_checksum: sha1:0aafe1072c61b82f62f6bbb29c91dac410fa0a17 pristine_git_object: 0c16788ff815693180b186aa0e9d4a016ffe2c28 + tests/mockserver/internal/sdk/models/operations/platformusagerequestscreate.go: + id: 736567c08ab9 + last_write_checksum: sha1:02cd21ee6864fc98211b7412a5ef35b6f97e7dee + pristine_git_object: 87ac564481d1eccda60f839da66793d8c6265100 + tests/mockserver/internal/sdk/models/operations/platformusagerequestsget.go: + id: 2fbec77b52e1 + last_write_checksum: sha1:f149cb466b121b08f57966006e2206ff533b4887 + pristine_git_object: 3e3eb28e360b19a8f4267e9b2604a350cdce9b38 + tests/mockserver/internal/sdk/models/operations/platformusagerequestslist.go: + id: 2d347d9caa80 + last_write_checksum: sha1:96f2b4d9ab0b18c807a167904aa6c9622096cbe8 + pristine_git_object: 21ce6d669ab920c7627ae5ae204a534080282dcd tests/mockserver/internal/sdk/models/operations/postapiindexv1adddatasource.go: id: 85e7185113c5 last_write_checksum: sha1:2f82dc427027cdb45f8fcf8fa6454e28599233aa @@ -11138,12 +11642,12 @@ trackedFiles: pristine_git_object: 0f579e13784795d08fe8f2562fc5007cd43babd6 tests/mockserver/internal/sdk/optionalnullable/optionalnullable.go: id: 49a8c2638f49 - last_write_checksum: sha1:aa5ff815f31a3657487ad5e0c3f023f573b1fcab - pristine_git_object: bdf1155c8c11ce1a1266e0e2e0fe24a1cefff196 + last_write_checksum: sha1:58d775c91b1a5ef5149b625286e4f35b96bb6f7f + pristine_git_object: 6d3eff536c547737cc702e0d385dc38924e93b34 tests/mockserver/internal/sdk/optionalnullable/optionalnullable_test.go: id: 67aafc07794f - last_write_checksum: sha1:c0ca755fb35acd8f838567e22c2b5722592fe1c3 - pristine_git_object: 52fb11f9ecfbf5e83c2a2d406d39e9a58923ef27 + last_write_checksum: sha1:bc65a2684a85ad0d79c7643836c17a222adf1082 + pristine_git_object: cfddc167f5105e174c6ad5917a6ae9a7defa8245 tests/mockserver/internal/sdk/types/bigint.go: id: 87f867cb8679 last_write_checksum: sha1:49b004005d0461fb04b846eca062b070b0360b31 @@ -11174,8 +11678,8 @@ trackedFiles: pristine_git_object: 365d8cff3c2d90c64859e66f9f0b788f0271b2d7 tests/mockserver/internal/sdk/utils/json.go: id: b1ed67b63d16 - last_write_checksum: sha1:2c860aa8b53b7d38c20290854c880368ce4fe0ec - pristine_git_object: e5aafa7be41a6c5a754c4c500c13a1aabcc654d4 + last_write_checksum: sha1:5e20daa1ddf6ebe49c4c0f34fd0051c43e6b7ff9 + pristine_git_object: 6ec0f8449efe84dafbc7b5cc438f9a54ebe1fc52 tests/mockserver/internal/sdk/utils/reflect.go: id: b024be29d61f last_write_checksum: sha1:1e3a0ca0387685b6b21c0a6a75650b8611c76ee3 @@ -11228,6 +11732,10 @@ trackedFiles: id: 0511c9cc6a92 last_write_checksum: sha1:e3ed9762b0d3969663ff8b18dcd9d55a0198b2bb pristine_git_object: db4221c9f5953adc8f8219979060f1248ae5c342 + tests/test_admin_usage.py: + id: d6b39c2592ce + last_write_checksum: sha1:0bab65f85381532adf79e51a9de2a47caa629e55 + pristine_git_object: cd05e9397d927f035c973c4caae57593459cc8c4 tests/test_agents.py: id: 2eb70a860f3a last_write_checksum: sha1:cd1e485496d46c76d01aa8118aa3fe5517f0186d @@ -11306,8 +11814,8 @@ trackedFiles: pristine_git_object: acec822d761f40906a287eee92200d1223caec4d tests/test_entities.py: id: 9bdc6c717c71 - last_write_checksum: sha1:883ddda9c056ac71fb37d07777e21e97b3d6a345 - pristine_git_object: b6c97f067a81983cd9055ea636273276c569d6dc + last_write_checksum: sha1:80ecdab911ec70bb80ecbf213772280444c8224d + pristine_git_object: 1dac6d8fd15046b62633704e46ef1637efef0687 tests/test_findings.py: id: f4c91dfb4975 last_write_checksum: sha1:8c377b73f379ee056474bdc6a19e3d7d5d323ef4 @@ -11334,8 +11842,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:b7415512608102fa07b1990a350a7da66946fe46 + pristine_git_object: 636f01d348f30db3ee81985044634511b615af16 tests/test_people.py: id: 37c243940039 last_write_checksum: sha1:2b78b1c5ea17f267895188b1b48ff9fe2bc19f17 @@ -11358,12 +11866,12 @@ trackedFiles: pristine_git_object: d0a8bd281e331739b23473d92b80408666d63066 tests/test_skills.py: id: ac5db26bd6b1 - last_write_checksum: sha1:51a01a7104693f6ddde3496296f520a0f1c6243d - pristine_git_object: 63587d5a9e7b7e506ce9daf00d51ce92afb56035 + last_write_checksum: sha1:c01d9e86a9686459777a922246762675ffd9a41a + pristine_git_object: 1c854370da050c261cb2cbcf9cc16829f5d8e78c tests/test_summarize.py: id: a255d8a6f627 - last_write_checksum: sha1:6383d6969c6f1bf1832e5ace511e5c2ffaa6d86f - pristine_git_object: cac8e9788f25fda1ff78bd2e3e36917319145e82 + last_write_checksum: sha1:db1495dd1d59b792b140544408857944dde68cd7 + pristine_git_object: 1a30852634da9770268045981a730d5f48afeda9 tests/test_tools.py: id: 70889bdf7321 last_write_checksum: sha1:e9e37efd6a65d805c02d70d548df9c87dd062b0e @@ -11376,6 +11884,10 @@ trackedFiles: id: 784c409f631e last_write_checksum: sha1:5af30befb8fffd54210e313bf98c24a64a685c50 pristine_git_object: f505171958a72f776fbd4bc7e45c190a869aaf81 + tests/test_usage.py: + id: bd2595a1d8d5 + last_write_checksum: sha1:a5ad275f3f61c311dee7ba00120202fe78eb131a + pristine_git_object: 15e14c7d1cabbcacad2d2860f14858bbd274c713 tests/test_visibilityoverrides.py: id: fd0437fcd963 last_write_checksum: sha1:6c55e2416341d23ed4c68130c64c6eda00eedbfa @@ -11780,7 +12292,7 @@ examples: people: speakeasy-default-people: requestBody: - application/json: {"obfuscatedIds": ["abc123", "abc456"]} + application/json: {"fallbackToAuthenticatedIdentity": false, "obfuscatedIds": ["abc123", "abc456"]} responses: "200": application/json: {"results": [{"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": [{"mimeType": "mimeType", "snippet": "snippet"}], "mustIncludeSuggestions": {"suggestions": [{"query": "app:github type:pull author:mortimer", "label": "Mortimer's PRs", "datasource": "github"}], "person": {"name": "George Clooney", "obfuscatedId": "abc123"}}}]}]} @@ -12406,11 +12918,16 @@ examples: application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} "500": application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "201": + application/json: {"skill": {"skill_id": "", "display_name": "Merl18", "description": "rural ugh unexpectedly excepting livid", "latest_version": 504149, "latest_minor_version": 106110, "status": "DISABLED", "origin": "CUSTOM", "owner": {"name": ""}, "created_at": "2025-09-10T16:05:46.046Z", "updated_at": "2025-08-13T23:05:45.737Z"}, "request_id": ""} platform-skills-list: speakeasy-default-platform-skills-list: + parameters: + query: + page_size: 20 responses: "200": - application/json: {"skills": [], "has_more": true, "next_cursor": "", "request_id": ""} + application/json: {"results": [], "has_more": true, "next_cursor": "", "request_id": ""} "400": application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} "500": @@ -12433,7 +12950,7 @@ examples: skill_id: "" responses: "200": - application/json: {"skill": {"id": "", "display_name": "Chad_Herzog", "description": "whenever up aha controvert", "latest_version": 151495, "latest_minor_version": 170771, "status": "DISABLED", "origin": "CUSTOM", "owner": {"name": ""}, "created_at": "2024-12-25T16:41:00.099Z", "updated_at": "2026-12-07T21:59:59.375Z"}, "request_id": ""} + application/json: {"skill": {"skill_id": "", "display_name": "Chad_Herzog", "description": "whenever up aha controvert", "latest_version": 151495, "latest_minor_version": 170771, "status": "DISABLED", "origin": "CUSTOM", "owner": {"name": ""}, "created_at": "2024-12-25T16:41:00.099Z", "updated_at": "2026-12-07T21:59:59.375Z"}, "request_id": ""} "400": application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} "500": @@ -12464,14 +12981,18 @@ examples: application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} "500": application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "201": + application/json: {"version": {"skill_id": "", "version": 375506, "minor_version": 600322, "is_latest": false, "created_by": {"name": ""}, "created_at": "2026-09-27T14:37:09.109Z", "updated_at": "2024-05-30T08:59:58.715Z"}, "request_id": ""} platform-skills-list-versions: speakeasy-default-platform-skills-list-versions: parameters: path: skill_id: "" + query: + page_size: 20 responses: "200": - application/json: {"versions": [], "has_more": false, "next_cursor": "", "request_id": ""} + application/json: {"results": [], "has_more": false, "next_cursor": "", "request_id": ""} "400": application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} "500": @@ -12540,6 +13061,10 @@ examples: application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} "500": application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "201": + application/json: {"skills": [], "request_id": ""} + "422": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}], "authentication_suggestions": []} platform-skills-preview-source: speakeasy-default-platform-skills-preview-source: requestBody: @@ -12552,6 +13077,8 @@ examples: application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} "500": application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "422": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}], "authentication_suggestions": []} platform-skills-update: speakeasy-default-platform-skills-update: parameters: @@ -12561,7 +13088,7 @@ examples: application/json: {"status": "ENABLED"} responses: "200": - application/json: {"skill": {"id": "", "display_name": "Afton14", "description": "taut netsuke duh sonata boastfully elegantly management come", "latest_version": 425795, "latest_minor_version": 741364, "status": "DISABLED", "origin": "CUSTOM", "owner": {"name": ""}, "created_at": "2024-12-20T01:31:39.364Z", "updated_at": "2025-12-04T02:59:37.124Z"}, "request_id": ""} + application/json: {"skill": {"skill_id": "", "display_name": "Afton14", "description": "taut netsuke duh sonata boastfully elegantly management come", "latest_version": 425795, "latest_minor_version": 741364, "status": "DISABLED", "origin": "CUSTOM", "owner": {"name": ""}, "created_at": "2024-12-20T01:31:39.364Z", "updated_at": "2025-12-04T02:59:37.124Z"}, "request_id": ""} "400": application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} "500": @@ -12583,11 +13110,13 @@ examples: skill_id: "" responses: "200": - application/json: {"sync_status": "UP_TO_DATE", "commit_sha": "", "updated": false, "request_id": ""} + application/json: {"commit_sha": "", "is_updated": false, "request_id": ""} "400": application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} "500": application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "422": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}], "authentication_suggestions": [{"server_id": ""}]} platform-search-filters: speakeasy-default-platform-search-filters: responses: @@ -12794,6 +13323,107 @@ examples: application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} "500": application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + platform-skills-preview-source-stream: + speakeasy-default-platform-skills-preview-source-stream: + requestBody: + application/json: {"source_url": "https://github.com/anthropics/skills", "stream": true} + responses: + "422": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}], "authentication_suggestions": [{"server_id": ""}]} + "400": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "500": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + platform-admin-usage-settings-get: + speakeasy-default-platform-admin-usage-settings-get: + responses: + "200": + application/json: {"usage_settings": {}, "request_id": ""} + "400": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "500": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + platform-admin-usage-settings-update: + speakeasy-default-platform-admin-usage-settings-update: + requestBody: + application/json: {"limit_increase_requests": {"business_justification": "REQUIRED"}} + responses: + "200": + application/json: {"usage_settings": {}, "request_id": ""} + "400": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "500": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + platform-admin-usage-requests-create: + speakeasy-default-platform-admin-usage-requests-create: + requestBody: + application/json: {"agent_id": "", "client_id": ""} + responses: + "201": + application/json: {"request": {"request_id": "", "entity_type": "USER", "entity_id": "", "client_id": "", "requester_user_id": "", "period": "", "status": "DENIED", "created_at": "2024-10-18T04:43:55.054Z"}, "request_id": ""} + "400": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "500": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + platform-admin-usage-requests-list: + speakeasy-default-platform-admin-usage-requests-list: + parameters: + query: + page_size: 20 + responses: + "200": + application/json: {"has_more": false, "next_cursor": "", "results": [{"request_id": "", "entity_type": "USER", "entity_id": "", "client_id": "", "requester_user_id": "", "period": "", "status": "PENDING", "created_at": "2024-01-15T07:33:22.777Z"}], "request_id": ""} + "400": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "500": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + platform-admin-usage-requests-get: + speakeasy-default-platform-admin-usage-requests-get: + parameters: + path: + request_id: "{request_id}" + responses: + "200": + application/json: {"request": {"request_id": "", "entity_type": "USER", "entity_id": "", "client_id": "", "requester_user_id": "", "period": "", "status": "APPROVED", "created_at": "2024-11-21T17:52:20.403Z"}, "request_id": ""} + "400": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "500": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + platform-usage-requests-create: + speakeasy-default-platform-usage-requests-create: + requestBody: + application/json: {"client_id": ""} + responses: + "201": + application/json: {"request": {"request_id": "", "entity_type": "AGENT", "entity_id": "", "client_id": "", "requester_user_id": "", "period": "", "status": "PENDING", "created_at": "2024-07-26T20:31:19.316Z"}, "request_id": ""} + "400": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "500": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + platform-usage-requests-list: + speakeasy-default-platform-usage-requests-list: + parameters: + query: + page_size: 20 + responses: + "200": + application/json: {"has_more": false, "results": [], "request_id": ""} + "400": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "500": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + platform-usage-requests-get: + speakeasy-default-platform-usage-requests-get: + parameters: + path: + request_id: "{request_id}" + responses: + "200": + application/json: {"request": {"request_id": "", "entity_type": "AGENT", "entity_id": "", "client_id": "", "requester_user_id": "", "period": "", "status": "DENIED", "created_at": "2026-10-11T16:53:21.602Z"}, "request_id": ""} + "400": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} + "500": + application/problem+json: {"type": "https://developers.glean.com/errors/invalid-cursor", "title": "Invalid Pagination Cursor", "status": 400, "detail": "The provided cursor has expired. Start a new search to get a fresh cursor.\n", "code": "invalid_cursor", "documentation_url": "https://developers.glean.com/errors/invalid-cursor", "request_id": "req_7f8a9b0c1d2e", "errors": [{"pointer": "/messages/0/role", "detail": "Must be one of: USER, GLEAN_AI.", "code": "invalid_cursor"}]} examplesVersion: 1.0.2 generatedTests: activity: "2025-04-28T22:05:12+01:00" @@ -12997,7 +13627,15 @@ generatedTests: platform-agents-get-run: "2026-09-23T18:29:44Z" platform-agents-cancel-run: "2026-09-23T18:29:44Z" platform-agents-create-run-responses: "2026-09-23T18:29:44Z" -releaseNotes: "## Python SDK Changes:\n* `glean.agents.create_run()`: \n * `request.execution_mode` **Added**\n * `response.status[201]` **Added** (Breaking ⚠️)\n* `glean.agents.get_run()`: **Added**\n* `glean.agents.cancel_run()`: **Added**\n* `glean.agents.respond_to_run()`: **Added**\n* `glean.chat.create()`: \n * `request.text` **Added**\n * `response.output[].content[].structured_output` **Added**\n* `glean.client.search.retrieve_feed()`: \n * `request.categories[]` **Changed**\n * `response.results[]` **Changed**\n" + platform-admin-usage-settings-get: "2026-10-02T04:27:53Z" + platform-admin-usage-settings-update: "2026-10-02T04:27:53Z" + platform-admin-usage-requests-create: "2026-10-02T04:27:53Z" + platform-admin-usage-requests-list: "2026-10-02T04:27:53Z" + platform-admin-usage-requests-get: "2026-10-02T04:27:53Z" + platform-usage-requests-create: "2026-10-02T04:27:53Z" + platform-usage-requests-list: "2026-10-02T04:27:53Z" + platform-usage-requests-get: "2026-10-02T04:27:53Z" +releaseNotes: "## Python SDK Changes:\n* `glean.skills.sync()`: \n * `response` **Changed** (Breaking ⚠️)\n * `error` **Changed** (Breaking ⚠️)\n* `glean.skills.list()`: \n * `request.page_size` **Changed**\n * `response` **Changed** (Breaking ⚠️)\n* `glean.skills.import()`: \n * `response` **Changed** (Breaking ⚠️)\n * `error.status[422]` **Added**\n* `glean.skills.preview_source()`: \n * `request.stream` **Removed** (Breaking ⚠️)\n * `response.status[200].content[text/event-stream` **Removed** (Breaking ⚠️)\n * `error.status[422]` **Added**\n* `glean.skills.update()`: `response.skill` **Changed** (Breaking ⚠️)\n* `glean.skills.create()`: \n * `response` **Changed** (Breaking ⚠️)\n * `error.status[409]` **Added**\n* `glean.skills.list_versions()`: \n * `request.page_size` **Changed**\n * `response` **Changed** (Breaking ⚠️)\n* `glean.skills.create_version()`: `response` **Changed** (Breaking ⚠️)\n* `glean.skills.retrieve()`: `response.skill` **Changed** (Breaking ⚠️)\n* `glean.client.agents.import()`: `response.workflow_result.workflow.author` **Changed**\n* `glean.client.collections.retrieve()`: `response.collection.added_roles[].person` **Changed**\n* `glean.admin.usage.update_settings()`: **Added**\n* `glean.admin.usage.list_limit_increase_requests()`: **Added**\n* `glean.admin.usage.get_limit_increase_request()`: **Added**\n* `glean.usage.create_limit_increase_request()`: **Added**\n* `glean.usage.list_limit_increase_requests()`: **Added**\n* `glean.usage.get_limit_increase_request()`: **Added**\n* `glean.client.announcements.create()`: \n * `request.body.structured_list[].document.metadata.author` **Changed**\n * `response.body.structured_list[].document.metadata.author` **Changed**\n* `glean.client.announcements.update()`: \n * `request.body.structured_list[].document.metadata.author` **Changed**\n * `response.body.structured_list[].document.metadata.author` **Changed**\n* `glean.client.answers.create()`: \n * `request.data.added_roles[].person` **Changed**\n * `response.added_roles[].person` **Changed**\n* `glean.client.answers.update()`: \n * `request.added_roles[].person` **Changed**\n * `response.added_roles[].person` **Changed**\n* `glean.client.answers.retrieve()`: `response.answer_result.answer.added_roles[].person` **Changed**\n* `glean.client.answers.list()`: `response.answer_results[].answer.added_roles[].person` **Changed**\n* `glean.client.chat.create()`: \n * `request.messages[].citations[].source_document.metadata.author` **Changed**\n * `response.messages[].citations[].source_document.metadata.author` **Changed**\n* `glean.client.chat.retrieve()`: \n * `response.chat_result.chat.created_by` **Changed**\n * `error.created_by` **Changed**\n* `glean.client.chat.list()`: `response.chat_results[].chat.created_by` **Changed**\n* `glean.client.chat.create_stream()`: \n * `request.messages[].citations[].source_document.metadata.author` **Changed**\n* `glean.client.agents.create()`: `response.workflow.author` **Changed**\n* `glean.admin.usage.get_settings()`: **Added**\n* `glean.client.collections.add_items()`: `response.collection.added_roles[].person` **Changed**\n* `glean.client.collections.create()`: \n * `request.added_roles[].person` **Changed**\n * `response.union(class (0)).collection.added_roles[].person` **Changed**\n* `glean.client.collections.delete_item()`: `response.collection.added_roles[].person` **Changed**\n* `glean.client.collections.update()`: \n * `request.added_roles[].person` **Changed**\n * `response.added_roles[].person` **Changed**\n* `glean.client.collections.update_item()`: `response.collection.added_roles[].person` **Changed**\n* `glean.admin.usage.create_limit_increase_request()`: **Added**\n* `glean.client.collections.list()`: `response.collections[].added_roles[].person` **Changed**\n* `glean.client.documents.retrieve()`: `response.documents.Map.union(Document).metadata.author` **Changed**\n* `glean.client.documents.retrieve_by_facets()`: `response.documents[].metadata.author` **Changed**\n* `glean.client.insights.retrieve()`: \n * `request.mcp_breakdown_request` **Changed**\n * `response` **Changed**\n* `glean.client.messages.retrieve()`: `response.search_response.results[].structured_results[].document.metadata` **Changed**\n* `glean.client.pins.update()`: `response.attribution` **Changed**\n* `glean.client.pins.retrieve()`: `response.pin.attribution` **Changed**\n* `glean.client.pins.list()`: `response.pins[].attribution` **Changed**\n* `glean.client.pins.create()`: `response.attribution` **Changed**\n* `glean.client.search.query_as_admin()`: \n * `request.source_document.metadata.author` **Changed**\n * `response.results[].structured_results[].document.metadata` **Changed**\n* `glean.client.search.autocomplete()`: `response.results[].document.metadata.author` **Changed**\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` **Changed**\n * `response.results[].structured_results[].document.metadata` **Changed**\n* `glean.client.search.query()`: \n * `request.source_document.metadata.author` **Changed**\n * `response.results[].structured_results[].document.metadata` **Changed**\n* `glean.client.entities.list()`: `response.results[]` **Changed**\n* `glean.client.entities.read_people()`: \n * `request.fallback_to_authenticated_identity` **Added**\n * `response.results[]` **Changed**\n* `glean.client.shortcuts.create()`: \n * `request.data.added_roles[].person` **Changed**\n * `response.shortcut.added_roles[].person` **Changed**\n* `glean.client.shortcuts.retrieve()`: `response.shortcut.added_roles[].person` **Changed**\n* `glean.client.shortcuts.list()`: `response.shortcuts[].added_roles[].person` **Changed**\n* `glean.client.shortcuts.update()`: \n * `request.added_roles[].person` **Changed**\n * `response.shortcut.added_roles[].person` **Changed**\n* `glean.client.verification.add_reminder()`: `response.metadata.last_verifier` **Changed**\n* `glean.client.verification.list()`: `response.documents[].metadata.last_verifier` **Changed**\n* `glean.client.verification.verify()`: `response.metadata.last_verifier` **Changed**\n" generatedFiles: - .devcontainer/README.md - .devcontainer/devcontainer.json diff --git a/.speakeasy/gen.yaml b/.speakeasy/gen.yaml index 7b5f20a3..6b7d70e5 100644 --- a/.speakeasy/gen.yaml +++ b/.speakeasy/gen.yaml @@ -34,7 +34,7 @@ generation: generateNewTests: true skipResponseBodyAssertions: true python: - version: 0.17.15 + version: 0.17.16 additionalDependencies: dev: {} main: {} diff --git a/.speakeasy/glean-merged-spec.yaml b/.speakeasy/glean-merged-spec.yaml index 8ba3d65e..6baae55c 100644 --- a/.speakeasy/glean-merged-spec.yaml +++ b/.speakeasy/glean-merged-spec.yaml @@ -2,8 +2,8 @@ openapi: 3.1.0 info: version: "0.9.0" title: Glean API - x-source-commit-sha: 600aa35531e44582cf056cb0531c04e7ec04d472 - x-open-api-commit-sha: c9917479fd934576f376c1f21d0bb426ee4fd46e + x-source-commit-sha: c7bdd7a36c418441bf7ee3c206ed08a10e035b76 + x-open-api-commit-sha: ac23790b0587c4bb8777b17810b8ce0051e4689b 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. @@ -39,6 +39,11 @@ paths: description: | Search agents available to the authenticated user by agent name. operationId: platform-agents-search + x-glean-scopes: + legacy: + - AGENTS + platform: + - agents:read x-visibility: Public x-codegen-request-body-name: payload requestBody: @@ -84,6 +89,11 @@ paths: description: | Retrieve details for an agent available to the authenticated user. operationId: platform-agents-get + x-glean-scopes: + legacy: + - AGENTS + platform: + - agents:read x-visibility: Public parameters: - in: path @@ -129,6 +139,11 @@ paths: description: | Retrieve an agent's input and output JSON schemas. operationId: platform-agents-get-schemas + x-glean-scopes: + legacy: + - AGENTS + platform: + - agents:read x-visibility: Public parameters: - in: path @@ -181,6 +196,11 @@ paths: description: | Execute an agent run. By default, set `stream` to true to receive server-sent events; otherwise the response contains the final agent messages. Set `execution_mode` to `DURABLE` to persist a new run and return its initial snapshot with HTTP 201 without waiting for execution. Poll the agent-scoped GET run endpoint for progress. Durable execution continues after an HTTP disconnect, but is not automatically resumed after a QE restart or crash. An active turn becomes overdue more than 40 minutes after acceptance (a 30-minute execution timeout plus 10 minutes of grace). The next GET of the run marks the overdue turn FAILED without replay; there is no periodic sweep. Without a GET, the stored run can remain RUNNING. Failure does not prove that external tool work has stopped. Paused runs are not expired; an accepted approval continuation starts a fresh deadline. Each POST creates a new run; retrying a POST can create another execution. Submit pending approval decisions through the run responses endpoint, and cancellation can be requested through the run cancellations endpoint. A run tracks one workflow execution; automatic background-subagent wake turns are separate executions, not continuations tracked by this run ID. operationId: platform-agents-create-run + x-glean-scopes: + legacy: + - AGENTS + platform: + - agents:run x-visibility: Public x-codegen-request-body-name: payload parameters: @@ -266,6 +286,11 @@ paths: description: | Retrieve a persisted workflow execution owned by the authenticated user. The run must belong to the specified agent, and the user must still have access to that agent. Unknown runs, runs owned by another user, and mismatched agent/run identifiers return 404. Requires the agents.run scope. Executions without a persisted workflow record are not available through this endpoint. operationId: platform-agents-get-run + x-glean-scopes: + legacy: + - AGENTS + platform: + - agents:run x-visibility: Public parameters: - in: path @@ -321,6 +346,11 @@ paths: description: | Request cooperative cancellation of the durable agent run identified by `run_id` in the JSON body. Requires ownership, current agent access, and the agents.run scope. Sending a cancellation signal does not itself change an active run from RUNNING; poll GET run for the final state. Paused runs become CANCELLED without resuming execution. Repeated requests and requests for terminal runs return the current snapshot. Completion may win a race with cancellation. Completed tool side effects cannot be undone, and external work may continue if a tool does not support cancellation. Cancellation targets this run, not separate background-subagent executions. An active run without a cancellation registration returns 409. Cancellation signaling requires Redis. An interrupted active run can instead become FAILED through deadline cleanup; this does not verify that external tool work has stopped. operationId: platform-agents-cancel-run + x-glean-scopes: + legacy: + - AGENTS + platform: + - agents:run x-visibility: Public x-codegen-request-body-name: payload parameters: @@ -378,6 +408,11 @@ paths: description: | Submit decisions for every pending tool approval in the paused run's current batch. The run is identified by `run_id` in the JSON body. Decisions apply only to the stored invocations and arguments; argument edits, authentication responses, and session-wide grants are not supported. The caller must own the run, still have agent access, and have the agents.run scope. Acceptance persists the decisions before resuming the same run and chat session. Identical accepted decisions return the current snapshot without another continuation. Conflicting, stale, incomplete, or non-pending decisions return 409. Cancellation registration failure returns 503 without accepting the decisions; retry the same approval batch. This retry guarantee does not cover an indeterminate database commit outcome. Go workflow approval resumes currently support one tool invocation and one approval response. Unsupported multi-tool or multi-decision Go resumes fail without executing tools. The resumed action must resolve to the tool identified by the stored approval request and paused checkpoint. Missing or inconsistent identity fails without executing tools. Execution continues after HTTP disconnects, but is not automatically resumed after a QE crash. Each accepted continuation starts a fresh 30-minute execution timeout and 40-minute cleanup deadline. Identical retries do not extend that deadline. Waiting for approval does not expire a run. The next GET marks an overdue active turn FAILED without replaying execution. operationId: platform-agents-create-run-responses + x-glean-scopes: + legacy: + - AGENTS + platform: + - agents:run x-visibility: Public parameters: - in: path @@ -434,6 +469,11 @@ paths: description: | Run an assistant turn. The default response is JSON. HTTP clients request server-sent events by setting `stream` to true in the JSON body. An `Accept: text/event-stream` header does not replace `stream`. operationId: platform-chat-create + x-glean-scopes: + legacy: + - CHAT + platform: + - chat:write x-visibility: Public x-codegen-request-body-name: payload requestBody: @@ -488,12 +528,14 @@ paths: - Skills summary: Create skill description: | - Create a skill from an uploaded SKILL.md, .zip, or .skill bundle. If the authenticated user already has a skill with the same name, the existing skill is superseded with a new version. + Create a skill from an uploaded SKILL.md, .zip, or .skill bundle. If the authenticated user already has a skill with the same name, the existing skill is superseded with a new version, unless it is source-managed: a same-name create over a GitHub-imported skill returns 409, and the caller syncs the existing skill instead. Two concurrent same-name creates can still produce two skills. operationId: platform-skills-create + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:write x-visibility: Public - x-glean-experimental: - id: 3cd55572-0d5c-4898-9ecf-1b86c520d1c7 - introduced: "2026-06-24" requestBody: required: true content: @@ -502,8 +544,8 @@ paths: $ref: "#/components/schemas/PlatformSkillCreateRequest" x-codegen-request-body-name: request responses: - "200": - description: Successful response. + "201": + description: Skill created. content: application/json: schema: @@ -518,6 +560,8 @@ paths: $ref: "#/components/responses/PlatformNotFound" "408": $ref: "#/components/responses/PlatformRequestTimeout" + "409": + $ref: "#/components/responses/PlatformConflict" "413": $ref: "#/components/responses/PlatformRequestTooLarge" "429": @@ -535,21 +579,24 @@ paths: - Skills summary: List skills description: | - List skills available to the authenticated user. + List every custom skill the authenticated caller can access. Built-in skills are excluded: they have no versions, content download, update, or delete, so their identifiers would fail most skill operations. Chat-authored skills shared with the caller without a listed grant are omitted: they stay retrievable by identifier when it is known, but this list does not discover them. operationId: platform-skills-list + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:read x-visibility: Public - x-glean-experimental: - id: 3eb65937-03a3-472b-9a00-be713f302b5f - introduced: "2026-06-23" parameters: - in: query name: page_size - description: Maximum number of skills to return. + description: Maximum number of skills to return. Defaults to 20. Maximum is 100. required: false schema: type: integer minimum: 1 maximum: 100 + default: 20 - in: query name: cursor description: Opaque pagination cursor from a previous response. @@ -592,10 +639,12 @@ paths: description: | Import one or more skills selected from a GitHub source preview. Each source URL is fetched and persisted as an independent skill with source provenance. This operation does not create a durable source resource. The import is atomic: if any source cannot be fetched, validated, or persisted, no skills are created. operationId: platform-skills-import + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:write x-visibility: Public - x-glean-experimental: - id: 9162d790-e101-437d-a9a0-25e4687d150b - introduced: "2026-07-28" x-codegen-request-body-name: request requestBody: required: true @@ -604,7 +653,7 @@ paths: schema: $ref: "#/components/schemas/PlatformSkillImportRequest" responses: - "200": + "201": description: Skills imported successfully. content: application/json: @@ -622,6 +671,12 @@ paths: $ref: "#/components/responses/PlatformConflict" "413": $ref: "#/components/responses/PlatformRequestTooLarge" + "422": + description: Returned when GitHub authorization is missing for a source URL. `authentication_suggestions` names the GitHub action pack to authorize; POST its `server_id` to the Client API's `/tool-servers/{serverId}/auth` with `returnUrl` in the request body to obtain an `authorizationUrl` to redirect the end user to, then retry the import once OAuth completes. + content: + application/problem+json: + schema: + $ref: "#/components/schemas/PlatformUnauthorizedAgentToolsProblem" "429": $ref: "#/components/responses/PlatformTooManyRequests" "500": @@ -640,10 +695,12 @@ paths: description: | Validate a skill bundle without persisting it. Accepts a SKILL.md, .zip, or .skill upload and returns parsed metadata plus the normalized file layout. operationId: platform-skills-validate + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:write x-visibility: Public - x-glean-experimental: - id: 0b086fa6-30f8-4279-8d11-10ab0059c14a - introduced: "2026-06-24" requestBody: required: true content: @@ -688,17 +745,28 @@ paths: description: | Inspect a GitHub URL without persisting a source or any discovered skills. Set stream to true to receive repository scan progress as server-sent events; otherwise the response contains the completed preview. operationId: platform-skills-preview-source + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:write x-visibility: Public - x-glean-experimental: - id: 1629009b-244a-400a-bf55-c441dfbc586c - introduced: "2026-07-23" x-codegen-request-body-name: request requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/PlatformSkillSourcePreviewRequest" + allOf: + - $ref: "#/components/schemas/PlatformSkillSourcePreviewRequest" + - type: object + required: + - stream + properties: + stream: + type: boolean + const: false + default: false responses: "200": description: Successful response. @@ -706,23 +774,6 @@ paths: application/json: schema: $ref: "#/components/schemas/PlatformSkillSourcePreviewResponse" - text/event-stream: - schema: - type: string - description: | - Server-sent scan, progress, skill, and result events. A failed stream - emits `data: {"type":"error","code":"service_unavailable","message":"GitHub is temporarily unavailable."}` - followed by `data: [DONE]` instead of a result event. - example: | - data: {"type":"scan","total":1,"skill_paths":["https://github.com/acme/skills/tree/main/skills/example"]} - - data: {"type":"progress","completed":1,"total":1,"current_skill":"skills/example/SKILL.md"} - - data: {"type":"skill","skill":{"display_name":"Example","description":"Example skill","source_url":"https://github.com/acme/skills/tree/main/skills/example","commit_sha":"abc123","main_content":"---\nname: Example\n---","files":[],"file_tree":["SKILL.md"]}} - - data: {"type":"result","response":{"skills":[{"display_name":"Example","description":"Example skill","source_url":"https://github.com/acme/skills/tree/main/skills/example","commit_sha":"abc123","main_content":"---\nname: Example\n---","files":[],"file_tree":["SKILL.md"]}],"failures":[],"request_id":"req-123"}} - - data: [DONE] "400": $ref: "#/components/responses/PlatformBadRequest" "401": @@ -733,6 +784,12 @@ paths: $ref: "#/components/responses/PlatformRequestTimeout" "413": $ref: "#/components/responses/PlatformRequestTooLarge" + "422": + description: Returned when GitHub authorization is missing for the source URL. `authentication_suggestions` names the GitHub action pack to authorize; POST its `server_id` to the Client API's `/tool-servers/{serverId}/auth` with `returnUrl` in the request body to obtain an `authorizationUrl` to redirect the end user to, then retry the preview once OAuth completes. + content: + application/problem+json: + schema: + $ref: "#/components/schemas/PlatformUnauthorizedAgentToolsProblem" "429": $ref: "#/components/responses/PlatformTooManyRequests" "500": @@ -749,12 +806,14 @@ paths: - Skills summary: Update skill description: | - Update mutable metadata for a skill. V1 supports enabling or disabling a skill without changing its content. + Enable or disable the skill for the authenticated caller without changing its content. The owner's update sets the skill's stored status. Any other caller's update applies only to that caller. operationId: platform-skills-update + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:write x-visibility: Public - x-glean-experimental: - id: 262e1f6b-6c2d-4d6d-943b-fc251d2fb38b - introduced: "2026-07-20" parameters: - name: skill_id in: path @@ -809,10 +868,12 @@ paths: description: | Delete a skill the authenticated caller is allowed to manage. This operation permanently removes all versions of the skill. operationId: platform-skills-delete + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:write x-visibility: Public - x-glean-experimental: - id: c4351fd0-4d28-4ad4-ab93-587ca4778173 - introduced: "2026-07-31" parameters: - name: skill_id in: path @@ -852,10 +913,12 @@ paths: description: | Retrieve metadata for a skill available to the authenticated user. operationId: platform-skills-get + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:read x-visibility: Public - x-glean-experimental: - id: 8f8d1c92-a484-4769-9903-200613dc8a72 - introduced: "2026-06-23" parameters: - name: skill_id in: path @@ -900,10 +963,12 @@ paths: description: | Download the latest installable bundle for a skill available to the authenticated user. operationId: platform-skills-get-content + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:read x-visibility: Public - x-glean-experimental: - id: fd6908d8-f230-4cd5-bf45-f71e69266b1d - introduced: "2026-06-24" parameters: - name: skill_id in: path @@ -954,10 +1019,12 @@ paths: description: | Refresh one GitHub-imported skill from its stored source URL. If the skill content has changed, this operation creates a new skill version. If the skill is no longer present upstream, the stored skill is left unchanged and must be deleted explicitly. operationId: platform-skills-sync + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:write x-visibility: Public - x-glean-experimental: - id: 568aa3f8-2af8-449c-9e4f-818ed4b877ef - introduced: "2026-08-03" parameters: - name: skill_id in: path @@ -986,8 +1053,12 @@ paths: $ref: "#/components/responses/PlatformRequestTimeout" "409": $ref: "#/components/responses/PlatformConflict" - "413": - $ref: "#/components/responses/PlatformRequestTooLarge" + "422": + description: Returned when GitHub authorization is missing for the stored source URL. `authentication_suggestions` names the GitHub action pack to authorize; POST its `server_id` to the Client API's `/tool-servers/{serverId}/auth` with `returnUrl` in the request body to obtain an `authorizationUrl` to redirect the end user to, then retry the sync once OAuth completes. + content: + application/problem+json: + schema: + $ref: "#/components/schemas/PlatformUnauthorizedAgentToolsProblem" "429": $ref: "#/components/responses/PlatformTooManyRequests" "500": @@ -1004,12 +1075,14 @@ paths: - Skills summary: Create skill version description: | - Create a new immutable version for an existing caller-managed skill from an uploaded SKILL.md, .zip, or .skill bundle. + Create a new immutable version for an existing caller-managed skill from an uploaded SKILL.md, .zip, or .skill bundle. A create-version over a GitHub-imported skill returns 409, and the caller syncs the existing skill instead. operationId: platform-skills-create-version + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:write x-visibility: Public - x-glean-experimental: - id: 0d5e48e2-7a41-4d54-b3aa-5026f0dd65df - introduced: "2026-06-24" parameters: - name: skill_id in: path @@ -1027,8 +1100,8 @@ paths: $ref: "#/components/schemas/PlatformSkillVersionCreateRequest" x-codegen-request-body-name: request responses: - "200": - description: Successful response. + "201": + description: Skill version created. content: application/json: schema: @@ -1064,10 +1137,12 @@ paths: description: | List versions for a skill available to the authenticated user. operationId: platform-skills-list-versions + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:read x-visibility: Public - x-glean-experimental: - id: 9efbb8a3-d546-4304-a653-09bb427e3681 - introduced: "2026-06-24" parameters: - name: skill_id in: path @@ -1079,12 +1154,13 @@ paths: minLength: 1 - in: query name: page_size - description: Maximum number of versions to return. + description: Maximum number of versions to return. Defaults to 20. Maximum is 100. required: false schema: type: integer minimum: 1 maximum: 100 + default: 20 - in: query name: cursor description: Opaque pagination cursor from a previous response. @@ -1127,10 +1203,12 @@ paths: description: | Retrieve metadata for a skill version available to the authenticated user. operationId: platform-skills-get-version + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:read x-visibility: Public - x-glean-experimental: - id: d70986b1-ad80-48dd-8e52-f294e7251dda - introduced: "2026-06-24" parameters: - name: skill_id in: path @@ -1183,10 +1261,12 @@ paths: description: | Download the installable bundle for a skill version available to the authenticated user. operationId: platform-skills-get-version-content + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:read x-visibility: Public - x-glean-experimental: - id: 70c85692-7042-403a-a3a5-5b315576432a - introduced: "2026-06-24" parameters: - name: skill_id in: path @@ -1246,6 +1326,11 @@ paths: Search your organization's connected content and return ranked document results with cursor pagination. Use `GET /api/search/filters` to discover datasource identifiers and common filter fields. Built-in filter names are validated; other field names are accepted as custom filters and behavior depends on your Glean configuration and connected sources. Errors: HTTP 422 `unprocessable_query` returns no `results` or `next_cursor`. See `warnings` on the response for non-blocking issues such as partially available results. Not every query issue produces a warning or error. operationId: platform-search + x-glean-scopes: + legacy: + - SEARCH + platform: + - search:query x-visibility: Public x-codegen-request-body-name: payload requestBody: @@ -1294,6 +1379,11 @@ paths: List datasources and common built-in filter fields visible to the authenticated user. This is a best-effort catalog, not an exhaustive list of every filter search accepts. Without `query`, returns field metadata only and does not run a search. With a nonblank `query`, provide exactly one `datasources` value to request suggested filter values for that query; no documents are returned and this endpoint does not include warning objects. See `FilterFieldInfo.values` for limitations on suggested values. Rate-limited requests return HTTP 429 with `Retry-After`; temporary backend unavailability returns HTTP 503. operationId: platform-search-filters + x-glean-scopes: + legacy: + - SEARCH + platform: + - search:query x-visibility: Public parameters: - in: query @@ -1349,67 +1439,85 @@ paths: x-speakeasy-name-override: listFilters security: - APIToken: [] - /api/triggers: - post: + /api/admin/usage/settings: + get: tags: - - Triggers - summary: Create trigger + - Usage + summary: Get usage settings description: | - Create a trigger from a preset and return it with its signing secret. - operationId: platform-triggers-create + Retrieve workspace-wide usage settings. Requires admin.usage.settings:read and permission to read workspace billing; a global administrator role is not required. + operationId: platform-admin-usage-settings-get x-visibility: Public + x-glean-scopes: + legacy: + - ADMIN_USAGE + platform: + - admin.usage.settings:read x-glean-experimental: - id: eb175f18-74e6-4c9c-ba02-23bcc9018fc9 - introduced: "2026-07-06" - x-codegen-request-body-name: payload + id: 8f4c2d6e-3b7a-4e1f-9c8d-5a2b6e4f7c9a + introduced: "2026-09-14" + responses: + "200": + description: Usage settings. + content: + application/json: + schema: + $ref: "#/components/schemas/PlatformUsageSettingsResponse" + "400": + $ref: "#/components/responses/PlatformBadRequest" + "401": + $ref: "#/components/responses/PlatformUnauthorized" + "403": + $ref: "#/components/responses/PlatformForbidden" + "404": + $ref: "#/components/responses/PlatformNotFound" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" + "429": + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: admin.usage + x-speakeasy-name-override: getSettings + security: + - APIToken: [] + patch: + tags: + - Usage + summary: Update usage settings + description: | + Partially update workspace-wide usage settings. Requires admin.usage.settings:write and permission to edit workspace billing; a global administrator role is not required. + operationId: platform-admin-usage-settings-update + x-visibility: Public + x-glean-scopes: + legacy: + - ADMIN_USAGE + platform: + - admin.usage.settings:write + x-glean-experimental: + id: 443aeb3c-fdee-4da8-a756-37fa13922830 + introduced: "2026-09-14" requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/PlatformTriggerCreateRequest" - callbacks: - triggerEvent: - "{$request.body#/delivery/webhook_url}": - post: - tags: - - Triggers - summary: Receive a trigger event - description: Delivery uses at-least-once semantics, so the same event can be sent more than once. Return any 2xx status after accepting the event. Network failures, 408, 429, and 5xx responses are retried; other non-2xx responses, including redirects, are terminal. The `webhook-id` remains stable across attempts and can be used for deduplication, while `webhook-timestamp` and `webhook-signature` are generated for each attempt. - operationId: trigger-webhook-event - security: - - {} - - TriggerWebhookBearerAuth: [] - parameters: - - $ref: "#/components/parameters/TriggerWebhookId" - - $ref: "#/components/parameters/TriggerWebhookTimestamp" - - $ref: "#/components/parameters/TriggerWebhookSignature" - requestBody: - required: true - content: - application/json: - schema: - $ref: "#/components/schemas/PlatformTriggerWebhookEvent" - responses: - "408": - description: Request timeout. Glean retries the delivery. - "429": - description: Rate limited. Glean retries the delivery. - 2XX: - description: Event accepted. Glean does not retry the delivery. - 3XX: - description: Redirects are not followed and the delivery is not retried. - 4XX: - description: Client error other than 408 or 429. Glean does not retry. - 5XX: - description: Server error. Glean retries the delivery. + $ref: "#/components/schemas/PlatformUsageSettingsUpdateRequest" + example: + multiple_membership_resolution: + per_member: + idp_groups: HIGHEST + limit_increase_requests: + business_justification: REQUIRED responses: - "201": - description: Trigger created. + "200": + description: Updated usage settings. content: application/json: schema: - $ref: "#/components/schemas/PlatformTriggerCreateResponse" + $ref: "#/components/schemas/PlatformUsageSettingsResponse" "400": $ref: "#/components/responses/PlatformBadRequest" "401": @@ -1420,8 +1528,6 @@ paths: $ref: "#/components/responses/PlatformNotFound" "408": $ref: "#/components/responses/PlatformRequestTimeout" - "409": - $ref: "#/components/responses/PlatformConflict" "413": $ref: "#/components/responses/PlatformRequestTooLarge" "429": @@ -1430,51 +1536,58 @@ paths: $ref: "#/components/responses/PlatformInternalServerError" "503": $ref: "#/components/responses/PlatformServiceUnavailable" - x-speakeasy-group: triggers - x-speakeasy-name-override: create + x-speakeasy-group: admin.usage + x-speakeasy-name-override: updateSettings security: - APIToken: [] + /api/admin/usage/limits: get: tags: - - Triggers - summary: List triggers + - Usage + summary: List usage limits description: | - List triggers owned by the authenticated caller. - operationId: platform-triggers-list + List configured limits across Glean and external spend clients, plus aggregate agent limits. Organization and user limits identify their spend client; aggregate agent limits omit client_id. USER targets return the canonical user_id and, when available, the user's directory email. Requires admin.usage.limits:read and permission to read workspace billing. + operationId: platform-admin-usage-limits-list x-visibility: Public + x-glean-scopes: + legacy: + - ADMIN_USAGE + platform: + - admin.usage.limits:read x-glean-experimental: - id: e3554987-e043-4561-889a-a1117b1bce06 - introduced: "2026-07-06" + id: ca19b3e8-9a6d-4a31-8f2f-6c7d8e9f0011 + introduced: "2026-09-16" parameters: - - in: query - name: page_size - description: Maximum number of triggers to return. - required: false + - name: page_size + in: query + description: Maximum number of limits to return. Defaults to 20; the maximum allowed is 100. + example: 20 schema: type: integer minimum: 1 maximum: 100 - default: 50 - - in: query - name: cursor - description: Opaque pagination cursor from a previous response. - required: false + default: 20 + - name: cursor + in: query + description: Opaque cursor from a previous list response. + example: "{cursor}" schema: type: string - minLength: 1 responses: "200": - description: Successful response. + description: List of usage limits. content: application/json: schema: - $ref: "#/components/schemas/PlatformTriggerListResponse" + $ref: "#/components/schemas/PlatformListUsageLimitsResponse" "400": $ref: "#/components/responses/PlatformBadRequest" "401": $ref: "#/components/responses/PlatformUnauthorized" "403": $ref: "#/components/responses/PlatformForbidden" + "404": + $ref: "#/components/responses/PlatformNotFound" "408": $ref: "#/components/responses/PlatformRequestTimeout" "429": @@ -1483,38 +1596,49 @@ paths: $ref: "#/components/responses/PlatformInternalServerError" "503": $ref: "#/components/responses/PlatformServiceUnavailable" - x-speakeasy-group: triggers - x-speakeasy-name-override: list + x-speakeasy-group: admin.usage + x-speakeasy-name-override: listLimits security: - APIToken: [] - /api/triggers/{trigger_id}: - get: + post: tags: - - Triggers - summary: Get trigger + - Usage + summary: Upsert a usage limit description: | - Retrieve a trigger owned by the authenticated caller. - operationId: platform-triggers-get + Create or replace a single usage limit by its natural key. Always returns 200 with the normalized limit. A USER target may be identified by user_id or email; an unknown user returns 404. Requires admin.usage.limits:write and permission to edit workspace billing. Personal usage grants do not allow limit changes. + operationId: platform-admin-usage-limits-upsert x-visibility: Public - x-glean-experimental: - id: 46de62cb-ba31-4f71-9646-649c1d604816 - introduced: "2026-07-06" - parameters: - - in: path - name: trigger_id - description: ID of the trigger to retrieve. - required: true - example: "{trigger_id}" - schema: - type: string - minLength: 1 + x-glean-scopes: + legacy: + - ADMIN_USAGE + platform: + - admin.usage.limits:write + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/PlatformUsageLimit" + example: + target: + type: ORGANIZATION + usage_selector: + client_id: glean + period: + type: RECURRING_CALENDAR_MONTH + allocation_mode: SHARED_POOL + value: + mode: FINITE + amount: "1000.00" + unit: USD + enforcement: HARD responses: "200": - description: Successful response. + description: The upserted usage limit. content: application/json: schema: - $ref: "#/components/schemas/PlatformTriggerGetResponse" + $ref: "#/components/schemas/PlatformUpsertUsageLimitResponse" "400": $ref: "#/components/responses/PlatformBadRequest" "401": @@ -1525,50 +1649,56 @@ paths: $ref: "#/components/responses/PlatformNotFound" "408": $ref: "#/components/responses/PlatformRequestTimeout" + "413": + $ref: "#/components/responses/PlatformRequestTooLarge" "429": $ref: "#/components/responses/PlatformTooManyRequests" "500": $ref: "#/components/responses/PlatformInternalServerError" "503": $ref: "#/components/responses/PlatformServiceUnavailable" - x-speakeasy-group: triggers - x-speakeasy-name-override: get + x-speakeasy-group: admin.usage + x-speakeasy-name-override: upsertLimit security: - APIToken: [] - patch: + /api/admin/usage/limits/reset: + post: tags: - - Triggers - summary: Update trigger + - Usage + summary: Reset a usage limit description: | - Update a trigger. - operationId: platform-triggers-update + Remove a configured usage limit matching the selector without clearing measured usage. A USER target may be identified by user_id or email, including a user no longer in the directory. Requires admin.usage.limits:write and permission to edit workspace billing. + operationId: platform-admin-usage-limits-reset x-visibility: Public + x-glean-scopes: + legacy: + - ADMIN_USAGE + platform: + - admin.usage.limits:write x-glean-experimental: - id: 3eb4c709-bd5c-4019-b913-0db36c766350 - introduced: "2026-07-06" - x-codegen-request-body-name: payload - parameters: - - in: path - name: trigger_id - description: ID of the trigger to update. - required: true - example: "{trigger_id}" - schema: - type: string - minLength: 1 + id: ca19b3e8-9a6d-4a31-8f2f-6c7d8e9f0013 + introduced: "2026-09-16" requestBody: required: true content: application/json: schema: - $ref: "#/components/schemas/PlatformTriggerUpdateRequest" + $ref: "#/components/schemas/PlatformUsageLimitKey" + example: + target: + type: USER + email: user@example.com + usage_selector: + client_id: glean + period: + type: RECURRING_CALENDAR_MONTH responses: "200": - description: Trigger updated. + description: Reset result. content: application/json: schema: - $ref: "#/components/schemas/PlatformTriggerGetResponse" + $ref: "#/components/schemas/PlatformResetUsageLimitsResponse" "400": $ref: "#/components/responses/PlatformBadRequest" "401": @@ -1587,33 +1717,70 @@ paths: $ref: "#/components/responses/PlatformInternalServerError" "503": $ref: "#/components/responses/PlatformServiceUnavailable" - x-speakeasy-group: triggers - x-speakeasy-name-override: update + x-speakeasy-group: admin.usage + x-speakeasy-name-override: resetLimit security: - APIToken: [] - delete: + /api/admin/usage/limits/batch: + post: tags: - - Triggers - summary: Delete trigger + - Usage + summary: Apply usage limit policies description: | - Delete a trigger. - operationId: platform-triggers-delete + Apply one or more usage limit policy changes atomically. This action sets policy by natural key; it does not create addressable resources or return resource locations. Every change succeeds or none are applied. USER targets may be identified by user_id or email; each resolves to the canonical user_id before duplicate natural keys are checked. Requires admin.usage.limits:write and permission to edit workspace billing. + operationId: platform-admin-usage-limits-batch x-visibility: Public + x-glean-scopes: + legacy: + - ADMIN_USAGE + platform: + - admin.usage.limits:write x-glean-experimental: - id: e6564ed7-8b4b-4708-918b-eed97110859f - introduced: "2026-07-06" - parameters: - - in: path - name: trigger_id - description: ID of the trigger to delete. - required: true - example: "{trigger_id}" - schema: - type: string - minLength: 1 + id: ca19b3e8-9a6d-4a31-8f2f-6c7d8e9f0014 + introduced: "2026-09-16" + requestBody: + required: true + content: + application/json: + schema: + type: array + description: Usage limit policies to apply atomically. + minItems: 1 + maxItems: 100 + items: + $ref: "#/components/schemas/PlatformUsageLimit" + example: + - target: + type: ORGANIZATION + usage_selector: + client_id: glean + period: + type: RECURRING_CALENDAR_MONTH + allocation_mode: SHARED_POOL + value: + mode: FINITE + amount: "1000.00" + unit: USD + enforcement: HARD + - target: + type: USER + email: user@example.com + usage_selector: + client_id: glean + period: + type: RECURRING_CALENDAR_MONTH + value: + mode: FINITE + amount: "50.00" + unit: USD + enforcement: HARD responses: - "204": - description: Trigger deleted. No content. + "200": + description: The applied usage limit policies. + content: + application/json: + schema: + $ref: "#/components/schemas/PlatformBatchUsageLimitsResponse" "400": $ref: "#/components/responses/PlatformBadRequest" "401": @@ -1624,50 +1791,56 @@ paths: $ref: "#/components/responses/PlatformNotFound" "408": $ref: "#/components/responses/PlatformRequestTimeout" + "413": + $ref: "#/components/responses/PlatformRequestTooLarge" "429": $ref: "#/components/responses/PlatformTooManyRequests" "500": $ref: "#/components/responses/PlatformInternalServerError" "503": $ref: "#/components/responses/PlatformServiceUnavailable" - x-speakeasy-group: triggers - x-speakeasy-name-override: delete + x-speakeasy-group: admin.usage + x-speakeasy-name-override: applyLimits security: - APIToken: [] - /api/triggers/{trigger_id}/events/search: + /api/admin/usage/limits/evaluate: post: tags: - - Triggers - summary: Search events for a trigger + - Usage + summary: Evaluate administrative usage limit headroom description: | - Search recent content events an existing trigger matches. Read-only — no webhook delivery is made. Covers the last seven days. - operationId: platform-triggers-events-search + Evaluate the effective usage limits for a selector and return the current decision (AVAILABLE, WARNING, or BLOCKED) based on accrued usage. Requires admin.usage:evaluate and permission to read workspace billing, not a global administrator role. An explicit usage_selector.client_id selects the Glean or external spend client; it is never inferred from the caller. Returns all applicable limit values and counters, with effective headroom separated by unit. Agent counters retain aggregate scope. Billing readers receive exact IdP-group source identities. A USER target may be identified by user_id or email. Evaluation reports configured-budget status even when runtime enforcement switches are off; it does not perform request admission, model eligibility, or agent-run preflight checks. + operationId: platform-admin-usage-limits-evaluate x-visibility: Public + x-glean-scopes: + legacy: + - ADMIN_USAGE + platform: + - admin.usage:evaluate x-glean-experimental: - id: c734a377-3dec-4ee2-9ec5-3848a8384f03 - introduced: "2026-08-07" - parameters: - - in: path - name: trigger_id - description: ID of the trigger whose events to search. - required: true - example: "{trigger_id}" - schema: - type: string - minLength: 1 + id: 70bc17be-ccdb-4e9e-b1e7-1a75256c6ee1 + introduced: "2026-09-18" requestBody: - required: false + required: true content: application/json: schema: - $ref: "#/components/schemas/PlatformTriggerEventSearchRequest" + $ref: "#/components/schemas/PlatformEvaluateUsageLimitRequest" + example: + target: + type: USER + email: user@example.com + usage_selector: + client_id: glean + period: + type: RECURRING_CALENDAR_MONTH responses: "200": - description: Successful response. + description: Evaluation result. content: application/json: schema: - $ref: "#/components/schemas/PlatformTriggerEventSearchResponse" + $ref: "#/components/schemas/PlatformEvaluateUsageLimitResponse" "400": $ref: "#/components/responses/PlatformBadRequest" "401": @@ -1686,1084 +1859,1306 @@ paths: $ref: "#/components/responses/PlatformInternalServerError" "503": $ref: "#/components/responses/PlatformServiceUnavailable" - x-speakeasy-group: triggers - x-speakeasy-name-override: searchEvents + x-speakeasy-group: admin.usage + x-speakeasy-name-override: evaluateUsage security: - APIToken: [] - /api/trigger-presets: - get: + /api/usage/limits/evaluate: + post: tags: - - Triggers - summary: List trigger presets + - Usage + summary: Evaluate usage limit headroom description: | - List the trigger presets available to the caller. A preset is a curated content-trigger template (e.g. a new Jira ticket) which is passed when creating a trigger. - operationId: platform-trigger-presets-list + Evaluate the effective usage limits for a selector and return the current decision (AVAILABLE, WARNING, or BLOCKED) based on accrued usage. Requires usage:evaluate, without workspace billing permission. Omit target to evaluate the authenticated canonical user. An explicit USER must identify that user by canonical ID, known alias ID, email, or known alias email; every supplied field must identify the caller. An explicit AGENT requires current owner/editor or applicable global agent-edit permission; disabled agents remain eligible. Subagents, other users, ORGANIZATION, and default targets are forbidden on this route, even for billing administrators. Missing, inaccessible, and subagent targets return the same 403 insufficient_permissions. An explicit usage_selector.client_id selects the Glean or external spend client; it is never inferred from the caller. Agent evaluation reports aggregate agent usage and the selected client's organization limit, not the caller's personal slice or a complete run preflight. All applicable limit values, used counters, decisions, and headroom are returned; USD and credits have separate effective_limits. IdP-group source identities require billing-read permission. Other callers receive an IDP_GROUP source with is_identity_restricted true and no group_id, without suppressing the policy's value, counter, or decision. Evaluation reports configured-budget status even when runtime enforcement switches are off; it does not perform request admission, model eligibility, or agent-run preflight checks. + operationId: platform-usage-limits-evaluate x-visibility: Public + x-glean-scopes: + legacy: + - USAGE + platform: + - usage:evaluate x-glean-experimental: - id: f5b16196-0d4c-42f0-89bf-40313398728e - introduced: "2026-07-22" - parameters: - - in: query - name: datasource - description: Restrict results to presets for a single datasource (e.g. github). - required: false - schema: - type: string - minLength: 1 - - in: query - name: page_size - description: Maximum number of presets to return. - required: false - schema: - type: integer - minimum: 1 - maximum: 100 - default: 50 - - in: query - name: cursor - description: Opaque pagination cursor from a previous response. - required: false - schema: - type: string - minLength: 1 + id: ca19b3e8-9a6d-4a31-8f2f-6c7d8e9f0015 + introduced: "2026-09-16" + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/PlatformEvaluateCallerUsageLimitRequest" + example: + usage_selector: + client_id: glean + period: + type: RECURRING_CALENDAR_MONTH responses: "200": - description: Successful response. + description: Evaluation result. content: application/json: schema: - $ref: "#/components/schemas/PlatformTriggerPresetListResponse" + $ref: "#/components/schemas/PlatformEvaluateUsageLimitResponse" + "400": + $ref: "#/components/responses/PlatformBadRequest" + "401": + $ref: "#/components/responses/PlatformUnauthorized" + "403": + $ref: "#/components/responses/PlatformForbidden" + "404": + $ref: "#/components/responses/PlatformNotFound" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" + "413": + $ref: "#/components/responses/PlatformRequestTooLarge" + "429": + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: usage + x-speakeasy-name-override: evaluateUsage + security: + - APIToken: [] + /api/usage/limit-increase-requests: + post: + tags: + - Usage + summary: Submit a personal limit-increase request + operationId: platform-usage-requests-create + x-glean-scopes: + legacy: + - USAGE_LIMIT_INCREASE_REQUESTS + platform: + - usage.limit_increase_requests:write + x-visibility: Public + x-glean-experimental: + id: d9f125f8-85f3-4221-8627-0b39f6d5b4ab + introduced: "2026-09-25" + description: | + Requires usage.limit_increase_requests:write. The target is the authenticated canonical user, and requester identity comes from authentication. The caller supplies the client and optional business justification. The server assigns the request identifier and current UTC month. Billing grants do not widen this route. This internal scaffold returns 503 without creating a request. + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/PlatformPersonalRequestCreate" + description: Personal request for the authenticated user and specified client. + example: + client_id: glean + responses: + "201": + $ref: "#/components/responses/PlatformRequestResource" + description: The created personal request. "400": $ref: "#/components/responses/PlatformBadRequest" + description: Invalid input, with field-level validation details when available. "401": $ref: "#/components/responses/PlatformUnauthorized" + description: Authentication is missing or invalid. "403": $ref: "#/components/responses/PlatformForbidden" + description: The caller lacks the required scope or current resource permission. + "404": + $ref: "#/components/responses/PlatformNotFound" + description: The authorized request was not found. "408": $ref: "#/components/responses/PlatformRequestTimeout" + description: The operation timed out. + "409": + $ref: "#/components/responses/PlatformConflict" + description: The request conflicts with the current stored request state. + "413": + $ref: "#/components/responses/PlatformRequestTooLarge" + description: The request exceeds the supported body size. "429": $ref: "#/components/responses/PlatformTooManyRequests" + description: The caller exceeded the request rate limit. "500": $ref: "#/components/responses/PlatformInternalServerError" + description: An unexpected internal error prevented completion. "503": $ref: "#/components/responses/PlatformServiceUnavailable" - x-speakeasy-group: triggers - x-speakeasy-name-override: listPresets + description: Request handling is unavailable; the internal scaffold fails closed. + x-speakeasy-group: usage + x-speakeasy-name-override: createLimitIncreaseRequest security: - APIToken: [] - /api/trigger-presets/{preset_id}: get: tags: - - Triggers - summary: Get trigger preset - description: | - Retrieve a single trigger preset by id. - operationId: platform-trigger-presets-get + - Usage + summary: List personal limit-increase requests + operationId: platform-usage-requests-list + x-glean-scopes: + legacy: + - USAGE_LIMIT_INCREASE_REQUESTS + platform: + - usage.limit_increase_requests:read x-visibility: Public x-glean-experimental: - id: 5277167d-909b-4eee-95d1-8958b07016bb - introduced: "2026-07-22" + id: d92d077c-81c0-4d91-868d-021eed013d8d + introduced: "2026-09-25" + description: | + Requires usage.limit_increase_requests:read. The collection is limited to the authenticated canonical user's requests, including resolved requests. Cursors bind the filters and current authorization context; a billing grant cannot widen results. This internal scaffold returns 503 without reading requests. parameters: - - in: path - name: preset_id - description: ID of the preset to retrieve. - required: true - example: "{preset_id}" - schema: - type: string - minLength: 1 + - $ref: "#/components/parameters/PageSize" + description: Maximum page size; defaults to 20 and cannot exceed 100. + - $ref: "#/components/parameters/Cursor" + description: Opaque continuation bound to filters and current authorization. + - $ref: "#/components/parameters/Filters" + description: Optional structured filters on request status. responses: "200": - description: Successful response. + description: A bounded page of authorized requests. content: application/json: schema: - $ref: "#/components/schemas/PlatformTriggerPresetGetResponse" + $ref: "#/components/schemas/PlatformRequestListResponse" + description: Authorized request page and continuation state. "400": $ref: "#/components/responses/PlatformBadRequest" + description: Invalid input, with field-level validation details when available. "401": $ref: "#/components/responses/PlatformUnauthorized" + description: Authentication is missing or invalid. "403": $ref: "#/components/responses/PlatformForbidden" + description: The caller lacks the required scope or current resource permission. "404": $ref: "#/components/responses/PlatformNotFound" + description: The authorized request was not found. "408": $ref: "#/components/responses/PlatformRequestTimeout" + description: The operation timed out. "429": $ref: "#/components/responses/PlatformTooManyRequests" + description: The caller exceeded the request rate limit. "500": $ref: "#/components/responses/PlatformInternalServerError" + description: An unexpected internal error prevented completion. "503": $ref: "#/components/responses/PlatformServiceUnavailable" - x-speakeasy-group: triggers - x-speakeasy-name-override: getPreset + description: Request handling is unavailable; the internal scaffold fails closed. + x-speakeasy-group: usage + x-speakeasy-name-override: listLimitIncreaseRequests security: - APIToken: [] - /api/trigger-presets/{preset_id}/input-values: + /api/usage/limit-increase-requests/{request_id}: + parameters: + - $ref: "#/components/parameters/RequestId" + description: Opaque personal request identifier; not an authorization grant. get: tags: - - Triggers - summary: Search trigger preset input values - description: | - Return up to 300 selectable values for a single picklist input on a preset. Results are intended for typeahead selection and are not cursor-paginated. When `is_truncated` is true, refine `query` to narrow the result set. - operationId: platform-trigger-presets-input-values-list + - Usage + summary: Get a personal limit-increase request + operationId: platform-usage-requests-get + x-glean-scopes: + legacy: + - USAGE_LIMIT_INCREASE_REQUESTS + platform: + - usage.limit_increase_requests:read x-visibility: Public x-glean-experimental: - id: 24c5675d-a57a-48cb-9d71-3dece296f28c - introduced: "2026-08-06" - parameters: - - in: path - name: preset_id - description: ID of the preset the input belongs to. - required: true - example: "{preset_id}" - schema: - type: string - minLength: 1 - - in: query - name: field - description: Field identifier of the input whose values to list. - required: true - example: "{field}" - schema: - type: string - minLength: 1 - - in: query - name: query - description: | - Prefix filter over the input's option values, for typeahead. Matching is on the option value, not its display name. - required: false - schema: - type: string + id: 29a2f132-a0c2-429f-95e7-7995de058cd3 + introduced: "2026-09-25" + description: | + Requires usage.limit_increase_requests:read and the current user's request. Authorization precedes resource disclosure. This internal scaffold returns 503 without reading the request. responses: "200": - description: Successful response. - content: - application/json: - schema: - $ref: "#/components/schemas/PlatformTriggerPresetInputValueListResponse" + $ref: "#/components/responses/PlatformRequestResource" + description: The authorized request in its current stored state. "400": $ref: "#/components/responses/PlatformBadRequest" + description: Invalid input, with field-level validation details when available. "401": $ref: "#/components/responses/PlatformUnauthorized" + description: Authentication is missing or invalid. "403": $ref: "#/components/responses/PlatformForbidden" + description: The caller lacks the required scope or current resource permission. "404": $ref: "#/components/responses/PlatformNotFound" + description: The authorized request was not found. "408": $ref: "#/components/responses/PlatformRequestTimeout" + description: The operation timed out. "429": $ref: "#/components/responses/PlatformTooManyRequests" + description: The caller exceeded the request rate limit. "500": $ref: "#/components/responses/PlatformInternalServerError" + description: An unexpected internal error prevented completion. "503": $ref: "#/components/responses/PlatformServiceUnavailable" - x-speakeasy-group: triggers - x-speakeasy-name-override: listPresetInputValues + description: Request handling is unavailable; the internal scaffold fails closed. + x-speakeasy-group: usage + x-speakeasy-name-override: getLimitIncreaseRequest security: - APIToken: [] - /api/trigger-presets/{preset_id}/events/search: + /api/admin/usage/limit-increase-requests: post: tags: - - Triggers - summary: Search events for a trigger preset - description: | - Search recent content events an unsaved trigger built from this preset would match, to preview it before creating the trigger. Read-only — no trigger is created and no webhook delivery is made. Covers the last seven days. - operationId: platform-trigger-presets-events-search + - Usage + summary: Submit an editable-agent limit-increase request + operationId: platform-admin-usage-requests-create + x-glean-scopes: + legacy: + - USAGE_LIMIT_INCREASE_REQUESTS + platform: + - usage.limit_increase_requests:write x-visibility: Public x-glean-experimental: - id: a48efd80-78d6-46de-9f23-5b8c63ecd157 - introduced: "2026-08-12" - parameters: - - in: path - name: preset_id - description: ID of the preset to preview. - required: true - example: "{preset_id}" - schema: - type: string - minLength: 1 + id: e28f40de-1f6c-4dc6-ab12-4054b89628c1 + introduced: "2026-09-25" + description: | + Requires usage.limit_increase_requests:write, the same scope as personal creation, and current edit permission on the agent, not billing permissions. The caller supplies the agent, client, and optional business justification. Requester identity comes from authentication; the server assigns the request identifier and current UTC month. This internal scaffold returns 503 without creating a request. requestBody: - required: false + required: true content: application/json: schema: - $ref: "#/components/schemas/PlatformTriggerPresetEventSearchRequest" + $ref: "#/components/schemas/PlatformAgentRequestCreate" + description: Client-scoped request for an agent the caller can edit. + example: + agent_id: "{agent_id}" + client_id: glean responses: - "200": - description: Successful response. - content: - application/json: - schema: - $ref: "#/components/schemas/PlatformTriggerEventSearchResponse" + "201": + $ref: "#/components/responses/PlatformRequestResource" + description: The created editable-agent request. "400": $ref: "#/components/responses/PlatformBadRequest" + description: Invalid input, with field-level validation details when available. "401": $ref: "#/components/responses/PlatformUnauthorized" + description: Authentication is missing or invalid. "403": $ref: "#/components/responses/PlatformForbidden" + description: The caller lacks the required scope or current resource permission. "404": $ref: "#/components/responses/PlatformNotFound" + description: The authorized request was not found. "408": $ref: "#/components/responses/PlatformRequestTimeout" + description: The operation timed out. + "409": + $ref: "#/components/responses/PlatformConflict" + description: The request conflicts with the current stored request state. "413": $ref: "#/components/responses/PlatformRequestTooLarge" + description: The request exceeds the supported body size. "429": $ref: "#/components/responses/PlatformTooManyRequests" + description: The caller exceeded the request rate limit. "500": $ref: "#/components/responses/PlatformInternalServerError" + description: An unexpected internal error prevented completion. "503": $ref: "#/components/responses/PlatformServiceUnavailable" - x-speakeasy-group: triggers - x-speakeasy-name-override: searchPresetEvents + description: Request handling is unavailable; the internal scaffold fails closed. + x-speakeasy-group: admin.usage + x-speakeasy-name-override: createLimitIncreaseRequest security: - APIToken: [] - /api/chat#stream: - post: + get: tags: - - Chat - summary: Create a streaming chat response - description: | - SDK-only logical operation. HTTP clients must call the base path; the URL fragment is not sent. Run an assistant turn as server-sent events. HTTP clients request this mode by setting `stream` to true in the JSON body. - operationId: platform-chat-create-stream + - Usage + summary: List the billing limit-increase request queue + operationId: platform-admin-usage-requests-list + x-glean-scopes: + legacy: + - ADMIN_USAGE_LIMIT_INCREASE_REQUESTS + platform: + - admin.usage.limit_increase_requests:read x-visibility: Public - x-codegen-request-body-name: payload - requestBody: - required: true - content: - application/json: - schema: - allOf: - - $ref: "#/components/schemas/PlatformChatCreateRequest" - - type: object - required: - - stream - properties: - stream: - type: boolean - const: true - default: true + x-glean-experimental: + id: b02bb653-00f9-4739-b387-90f68c7385ee + introduced: "2026-09-25" + description: | + Requires admin.usage.limit_increase_requests:read and current workspace billing read permission. Agent ownership is not queue access. Cursors bind filters and current authorization context. This internal scaffold returns 503, not a successful empty page. + parameters: + - $ref: "#/components/parameters/PageSize" + description: Maximum page size; defaults to 20 and cannot exceed 100. + - $ref: "#/components/parameters/Cursor" + description: Opaque continuation bound to filters and current authorization. + - $ref: "#/components/parameters/Filters" + description: Optional structured filters on request status. responses: "200": - description: Successful response. + description: A bounded page of authorized requests. content: - text/event-stream: + application/json: schema: - $ref: "#/components/schemas/PlatformChatStreamEventServerSentEvent" + $ref: "#/components/schemas/PlatformRequestListResponse" + description: Authorized request page and continuation state. "400": $ref: "#/components/responses/PlatformBadRequest" + description: Invalid input, with field-level validation details when available. "401": $ref: "#/components/responses/PlatformUnauthorized" + description: Authentication is missing or invalid. "403": $ref: "#/components/responses/PlatformForbidden" + description: The caller lacks the required scope or current resource permission. "404": $ref: "#/components/responses/PlatformNotFound" + description: The authorized request was not found. "408": $ref: "#/components/responses/PlatformRequestTimeout" - "413": - $ref: "#/components/responses/PlatformRequestTooLarge" - "422": - $ref: "#/components/responses/PlatformUnprocessableEntity" + description: The operation timed out. "429": $ref: "#/components/responses/PlatformTooManyRequests" + description: The caller exceeded the request rate limit. "500": $ref: "#/components/responses/PlatformInternalServerError" + description: An unexpected internal error prevented completion. "503": $ref: "#/components/responses/PlatformServiceUnavailable" - x-speakeasy-group: chat - x-speakeasy-name-override: createStream + description: Request handling is unavailable; the internal scaffold fails closed. + x-speakeasy-group: admin.usage + x-speakeasy-name-override: listLimitIncreaseRequests security: - APIToken: [] - /rest/api/v1/activity: - post: - operationId: activity - summary: Report document activity - description: Report user activity that occurs on indexed documents such as viewing or editing. This signal improves search quality. + /api/admin/usage/limit-increase-requests/{request_id}: + parameters: + - $ref: "#/components/parameters/RequestId" + description: Opaque request identifier; not an authorization grant. + get: tags: - - Activity - security: - - APIToken: [] - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/Activity' - required: true - x-exportParamName: Activity + - Usage + summary: Get a billing limit-increase request + operationId: platform-admin-usage-requests-get + x-glean-scopes: + legacy: + - ADMIN_USAGE_LIMIT_INCREASE_REQUESTS + platform: + - admin.usage.limit_increase_requests:read + x-visibility: Public + x-glean-experimental: + id: 88f1a13a-3e09-4c78-a2dc-87cc223dc003 + introduced: "2026-09-25" + description: | + Requires admin.usage.limit_increase_requests:read. Authorization precedes resource disclosure. This internal scaffold returns 503 without reading the request. responses: "200": - description: OK + $ref: "#/components/responses/PlatformRequestResource" + description: The authorized request in its current stored state. "400": - description: Invalid request + $ref: "#/components/responses/PlatformBadRequest" + description: Invalid input, with field-level validation details when available. "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" + description: Authentication is missing or invalid. + "403": + $ref: "#/components/responses/PlatformForbidden" + description: The caller lacks the required scope or current resource permission. + "404": + $ref: "#/components/responses/PlatformNotFound" + description: The authorized request was not found. + "408": + $ref: "#/components/responses/PlatformRequestTimeout" + description: The operation timed out. "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: report - x-speakeasy-group: client.activity - /rest/api/v1/feedback: - post: - operationId: feedback - 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. - tags: - - Activity + $ref: "#/components/responses/PlatformTooManyRequests" + description: The caller exceeded the request rate limit. + "500": + $ref: "#/components/responses/PlatformInternalServerError" + description: An unexpected internal error prevented completion. + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + description: Request handling is unavailable; the internal scaffold fails closed. + x-speakeasy-group: admin.usage + x-speakeasy-name-override: getLimitIncreaseRequest security: - APIToken: [] - parameters: - - name: feedback - in: query - description: A URL encoded versions of Feedback. This is useful for requests. - required: false - schema: - type: string + patch: + tags: + - Usage + summary: Resolve a billing limit-increase request + operationId: platform-admin-usage-requests-update + x-glean-scopes: + legacy: + - ADMIN_USAGE_LIMIT_INCREASE_REQUESTS + platform: + - admin.usage.limit_increase_requests:write + x-visibility: Public + x-glean-experimental: + id: 08d999ca-f438-4fed-81ce-350c7e65c2cc + introduced: "2026-09-25" + description: | + Update a pending request with an approval decision or denial. Requires admin.usage.limit_increase_requests:write and current billing edit permission. A pending request can be approved with a positive additive increase or denied with an optional resolution note. PERIOD applies to the request's stored month; ONGOING increases the applicable standing rule at the selected resolution target. Ongoing approval is supported only for user requests, not agent requests. This internal scaffold returns 503 without resolving requests or changing policy. requestBody: + required: true content: application/json: schema: - $ref: '#/components/schemas/Feedback' - x-exportParamName: Feedback + $ref: "#/components/schemas/PlatformAdministrativeRequestUpdate" + description: Additive approval or denial of a pending request. + example: + status: APPROVED + approved_increase_amount: "100.00" + scope: PERIOD responses: "200": - description: OK + $ref: "#/components/responses/PlatformRequestResource" + description: The resolved request in its current stored state. "400": - description: Invalid request + $ref: "#/components/responses/PlatformBadRequest" + description: Invalid input, with field-level validation details when available. "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" + description: Authentication is missing or invalid. + "403": + $ref: "#/components/responses/PlatformForbidden" + description: The caller lacks the required scope or current resource permission. + "404": + $ref: "#/components/responses/PlatformNotFound" + description: The authorized request was not found. + "408": + $ref: "#/components/responses/PlatformRequestTimeout" + description: The operation timed out. + "409": + $ref: "#/components/responses/PlatformConflict" + description: The request conflicts with the current stored request state. + "413": + $ref: "#/components/responses/PlatformRequestTooLarge" + description: The request exceeds the supported body size. "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-group: client.activity - /rest/api/v1/createannouncement: - post: - operationId: createannouncement - summary: Create Announcement - description: Create a textual announcement visible to some set of users based on department and location. - tags: - - Announcements + $ref: "#/components/responses/PlatformTooManyRequests" + description: The caller exceeded the request rate limit. + "500": + $ref: "#/components/responses/PlatformInternalServerError" + description: An unexpected internal error prevented completion. + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + description: Request handling is unavailable; the internal scaffold fails closed. + x-speakeasy-group: admin.usage + x-speakeasy-name-override: updateLimitIncreaseRequest security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' + /api/triggers: + post: + tags: + - Triggers + summary: Create trigger + description: | + Create a trigger from a preset and return it with its signing secret. + operationId: platform-triggers-create + x-glean-scopes: + legacy: + - TRIGGERS + platform: + - triggers:write + x-visibility: Public + x-glean-experimental: + id: eb175f18-74e6-4c9c-ba02-23bcc9018fc9 + introduced: "2026-07-06" + x-codegen-request-body-name: payload requestBody: - description: Announcement content + required: true content: application/json: schema: - $ref: '#/components/schemas/CreateAnnouncementRequest' - required: true - x-exportParamName: Request + $ref: "#/components/schemas/PlatformTriggerCreateRequest" + callbacks: + triggerEvent: + "{$request.body#/delivery/webhook_url}": + post: + tags: + - Triggers + summary: Receive a trigger event + description: Delivery uses at-least-once semantics, so the same event can be sent more than once. Return any 2xx status after accepting the event. Network failures, 408, 429, and 5xx responses are retried; other non-2xx responses, including redirects, are terminal. The `webhook-id` remains stable across attempts and can be used for deduplication, while `webhook-timestamp` and `webhook-signature` are generated for each attempt. + operationId: trigger-webhook-event + security: + - {} + - TriggerWebhookBearerAuth: [] + parameters: + - $ref: "#/components/parameters/TriggerWebhookId" + - $ref: "#/components/parameters/TriggerWebhookTimestamp" + - $ref: "#/components/parameters/TriggerWebhookSignature" + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/PlatformTriggerWebhookEvent" + responses: + "408": + description: Request timeout. Glean retries the delivery. + "429": + description: Rate limited. Glean retries the delivery. + 2XX: + description: Event accepted. Glean does not retry the delivery. + 3XX: + description: Redirects are not followed and the delivery is not retried. + 4XX: + description: Client error other than 408 or 429. Glean does not retry. + 5XX: + description: Server error. Glean retries the delivery. responses: - "200": - description: OK + "201": + description: Trigger created. content: application/json: schema: - $ref: '#/components/schemas/Announcement' + $ref: "#/components/schemas/PlatformTriggerCreateResponse" "400": - description: Invalid request + $ref: "#/components/responses/PlatformBadRequest" "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" + "403": + $ref: "#/components/responses/PlatformForbidden" + "404": + $ref: "#/components/responses/PlatformNotFound" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" + "409": + $ref: "#/components/responses/PlatformConflict" + "413": + $ref: "#/components/responses/PlatformRequestTooLarge" "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: triggers x-speakeasy-name-override: create - x-speakeasy-group: client.announcements - /rest/api/v1/deleteannouncement: - post: - operationId: deleteannouncement - summary: Delete Announcement - description: Delete an existing user-generated announcement. - tags: - - Announcements security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' - requestBody: - description: Delete announcement request - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteAnnouncementRequest' - required: true - x-exportParamName: Request - responses: - "200": - description: OK - "400": - description: Invalid request - "401": - description: Not Authorized - "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: delete - x-speakeasy-group: client.announcements - /rest/api/v1/updateannouncement: - post: - operationId: updateannouncement - summary: Update Announcement - description: Update a textual announcement visible to some set of users based on department and location. + get: tags: - - Announcements - security: - - APIToken: [] + - Triggers + summary: List triggers + description: | + List triggers owned by the authenticated caller. + operationId: platform-triggers-list + x-glean-scopes: + legacy: + - TRIGGERS + platform: + - triggers:read + x-visibility: Public + x-glean-experimental: + id: e3554987-e043-4561-889a-a1117b1bce06 + introduced: "2026-07-06" parameters: - - $ref: '#/components/parameters/locale' - requestBody: - description: Announcement content. Id need to be specified for the announcement. - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateAnnouncementRequest' - required: true - x-exportParamName: Request + - in: query + name: page_size + description: Maximum number of triggers to return. + required: false + schema: + type: integer + minimum: 1 + maximum: 100 + default: 50 + - in: query + name: cursor + description: Opaque pagination cursor from a previous response. + required: false + schema: + type: string + minLength: 1 responses: "200": - description: OK + description: Successful response. content: application/json: schema: - $ref: '#/components/schemas/Announcement' + $ref: "#/components/schemas/PlatformTriggerListResponse" "400": - description: Invalid request + $ref: "#/components/responses/PlatformBadRequest" "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" + "403": + $ref: "#/components/responses/PlatformForbidden" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: update - x-speakeasy-group: client.announcements - /rest/api/v1/createanswer: - post: - operationId: createanswer - summary: Create Answer - description: Create a user-generated Answer that contains a question and answer. - tags: - - Answers - security: - - APIToken: [] + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: triggers + x-speakeasy-name-override: list + security: + - APIToken: [] + /api/triggers/{trigger_id}: + get: + tags: + - Triggers + summary: Get trigger + description: | + Retrieve a trigger owned by the authenticated caller. + operationId: platform-triggers-get + x-glean-scopes: + legacy: + - TRIGGERS + platform: + - triggers:read + x-visibility: Public + x-glean-experimental: + id: 46de62cb-ba31-4f71-9646-649c1d604816 + introduced: "2026-07-06" parameters: - - $ref: '#/components/parameters/locale' - requestBody: - description: CreateAnswer request - content: - application/json: - schema: - $ref: '#/components/schemas/CreateAnswerRequest' - required: true - x-exportParamName: Request + - in: path + name: trigger_id + description: ID of the trigger to retrieve. + required: true + example: "{trigger_id}" + schema: + type: string + minLength: 1 responses: "200": - description: OK + description: Successful response. content: application/json: schema: - $ref: '#/components/schemas/Answer' + $ref: "#/components/schemas/PlatformTriggerGetResponse" "400": - description: Invalid request + $ref: "#/components/responses/PlatformBadRequest" "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" + "403": + $ref: "#/components/responses/PlatformForbidden" + "404": + $ref: "#/components/responses/PlatformNotFound" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: create - x-speakeasy-group: client.answers - /rest/api/v1/deleteanswer: - post: - operationId: deleteanswer - summary: Delete Answer - description: Delete an existing user-generated Answer. - tags: - - Answers + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: triggers + x-speakeasy-name-override: get security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' - requestBody: - description: DeleteAnswer request - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteAnswerRequest' - required: true - x-exportParamName: Request - responses: - "200": - description: OK - "400": - description: Invalid request - "401": - description: Not Authorized - "429": - description: Too Many Requests + patch: + tags: + - Triggers + summary: Update trigger + description: | + Update a trigger. + operationId: platform-triggers-update + x-glean-scopes: + legacy: + - TRIGGERS + platform: + - triggers:write x-visibility: Public + x-glean-experimental: + id: 3eb4c709-bd5c-4019-b913-0db36c766350 + introduced: "2026-07-06" x-codegen-request-body-name: payload - x-speakeasy-name-override: delete - x-speakeasy-group: client.answers - /rest/api/v1/editanswer: - post: - operationId: editanswer - summary: Update Answer - description: Update an existing user-generated Answer. - tags: - - Answers - security: - - APIToken: [] parameters: - - $ref: '#/components/parameters/locale' + - in: path + name: trigger_id + description: ID of the trigger to update. + required: true + example: "{trigger_id}" + schema: + type: string + minLength: 1 requestBody: - description: EditAnswer request + required: true content: application/json: schema: - $ref: '#/components/schemas/EditAnswerRequest' - required: true - x-exportParamName: Request + $ref: "#/components/schemas/PlatformTriggerUpdateRequest" responses: "200": - description: OK + description: Trigger updated. content: application/json: schema: - $ref: '#/components/schemas/Answer' + $ref: "#/components/schemas/PlatformTriggerGetResponse" "400": - description: Invalid request + $ref: "#/components/responses/PlatformBadRequest" "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" + "403": + $ref: "#/components/responses/PlatformForbidden" + "404": + $ref: "#/components/responses/PlatformNotFound" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" + "413": + $ref: "#/components/responses/PlatformRequestTooLarge" "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: triggers x-speakeasy-name-override: update - x-speakeasy-group: client.answers - /rest/api/v1/getanswer: - post: - operationId: getanswer - summary: Read Answer - description: Read the details of a particular Answer given its ID. - tags: - - Answers security: - APIToken: [] + delete: + tags: + - Triggers + summary: Delete trigger + description: | + Delete a trigger. + operationId: platform-triggers-delete + x-glean-scopes: + legacy: + - TRIGGERS + platform: + - triggers:write + x-visibility: Public + x-glean-experimental: + id: e6564ed7-8b4b-4708-918b-eed97110859f + introduced: "2026-07-06" parameters: - - $ref: '#/components/parameters/locale' - requestBody: - description: GetAnswer request - content: - application/json: - schema: - $ref: '#/components/schemas/GetAnswerRequest' - required: true - x-exportParamName: Request + - in: path + name: trigger_id + description: ID of the trigger to delete. + required: true + example: "{trigger_id}" + schema: + type: string + minLength: 1 responses: - "200": - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/GetAnswerResponse' + "204": + description: Trigger deleted. No content. "400": - description: Invalid request + $ref: "#/components/responses/PlatformBadRequest" "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" + "403": + $ref: "#/components/responses/PlatformForbidden" + "404": + $ref: "#/components/responses/PlatformNotFound" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: retrieve - x-speakeasy-group: client.answers - /rest/api/v1/listanswers: - post: - operationId: listanswers - summary: List Answers - description: List Answers created by the current user. - tags: - - Answers + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: triggers + x-speakeasy-name-override: delete security: - APIToken: [] + /api/triggers/{trigger_id}/events/search: + post: + tags: + - Triggers + summary: Search events for a trigger + description: | + Search recent content events an existing trigger matches. Read-only — no webhook delivery is made. Covers the last seven days. + operationId: platform-triggers-events-search + x-glean-scopes: + legacy: + - TRIGGERS + platform: + - triggers:read + x-visibility: Public + x-glean-experimental: + id: c734a377-3dec-4ee2-9ec5-3848a8384f03 + introduced: "2026-08-07" parameters: - - $ref: '#/components/parameters/locale' + - in: path + name: trigger_id + description: ID of the trigger whose events to search. + required: true + example: "{trigger_id}" + schema: + type: string + minLength: 1 requestBody: - description: ListAnswers request + required: false content: application/json: schema: - $ref: '#/components/schemas/ListAnswersRequest' - required: true - x-exportParamName: Request + $ref: "#/components/schemas/PlatformTriggerEventSearchRequest" responses: "200": - description: OK + description: Successful response. content: application/json: schema: - $ref: '#/components/schemas/ListAnswersResponse' + $ref: "#/components/schemas/PlatformTriggerEventSearchResponse" "400": - description: Invalid request + $ref: "#/components/responses/PlatformBadRequest" "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" + "403": + $ref: "#/components/responses/PlatformForbidden" + "404": + $ref: "#/components/responses/PlatformNotFound" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" + "413": + $ref: "#/components/responses/PlatformRequestTooLarge" "429": - description: Too Many Requests - deprecated: true - x-visibility: Public - x-codegen-request-body-name: payload - x-glean-deprecated: - id: 4c0923bd-64c7-45b9-99a5-b36f2705e618 - introduced: "2026-01-21" - message: Answer boards have been removed and this endpoint no longer serves a purpose - removal: "2026-10-15" - x-speakeasy-deprecation-message: "Deprecated on 2026-01-21, removal scheduled for 2026-10-15: Answer boards have been removed and this endpoint no longer serves a purpose" - x-speakeasy-name-override: list - x-speakeasy-group: client.answers - /rest/api/v1/checkdatasourceauth: - post: - operationId: checkdatasourceauth - summary: Check datasource authorization - description: | - Returns all datasource instances that require per-user OAuth authorization - for the authenticated user, along with a transient auth token that can be - appended to auth URLs to complete OAuth flows. - - Clients construct the full OAuth URL by combining the backend base URL, - the `authUrlRelativePath` from each instance, and the transient auth token: - `/?transient_auth_token=`. - tags: - - Authentication + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: triggers + x-speakeasy-name-override: searchEvents security: - APIToken: [] - parameters: [] + /api/trigger-presets: + get: + tags: + - Triggers + summary: List trigger presets + description: | + List the trigger presets available to the caller. A preset is a curated content-trigger template (e.g. a new Jira ticket) which is passed when creating a trigger. + operationId: platform-trigger-presets-list + x-glean-scopes: + legacy: + - TRIGGERS + platform: + - triggers:read + x-visibility: Public + x-glean-experimental: + id: f5b16196-0d4c-42f0-89bf-40313398728e + introduced: "2026-07-22" + parameters: + - in: query + name: datasource + description: Restrict results to presets for a single datasource (e.g. github). + required: false + schema: + type: string + minLength: 1 + - in: query + name: page_size + description: Maximum number of presets to return. + required: false + schema: + type: integer + minimum: 1 + maximum: 100 + default: 50 + - in: query + name: cursor + description: Opaque pagination cursor from a previous response. + required: false + schema: + type: string + minLength: 1 responses: "200": - description: OK + description: Successful response. content: application/json: schema: - $ref: '#/components/schemas/CheckDatasourceAuthResponse' + $ref: "#/components/schemas/PlatformTriggerPresetListResponse" + "400": + $ref: "#/components/responses/PlatformBadRequest" "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" + "403": + $ref: "#/components/responses/PlatformForbidden" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" "429": - description: Too Many Requests - x-visibility: Public - x-speakeasy-name-override: checkDatasourceAuth - x-speakeasy-group: client.authentication - /rest/api/v1/createauthtoken: - post: - operationId: createauthtoken - summary: Create authentication token - description: | - Creates an authentication token for the authenticated user. These are - specifically intended to be used with the [Web SDK](https://developers.glean.com/web). - - Note: The tokens generated from this endpoint are **not** valid tokens - for use with the Client API (e.g. `/rest/api/v1/*`). - tags: - - Authentication + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: triggers + x-speakeasy-name-override: listPresets security: - APIToken: [] - parameters: [] + /api/trigger-presets/{preset_id}: + get: + tags: + - Triggers + summary: Get trigger preset + description: | + Retrieve a single trigger preset by id. + operationId: platform-trigger-presets-get + x-glean-scopes: + legacy: + - TRIGGERS + platform: + - triggers:read + x-visibility: Public + x-glean-experimental: + id: 5277167d-909b-4eee-95d1-8958b07016bb + introduced: "2026-07-22" + parameters: + - in: path + name: preset_id + description: ID of the preset to retrieve. + required: true + example: "{preset_id}" + schema: + type: string + minLength: 1 responses: "200": - description: OK + description: Successful response. content: application/json: schema: - $ref: '#/components/schemas/CreateAuthTokenResponse' + $ref: "#/components/schemas/PlatformTriggerPresetGetResponse" "400": - description: Invalid Request + $ref: "#/components/responses/PlatformBadRequest" "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" + "403": + $ref: "#/components/responses/PlatformForbidden" + "404": + $ref: "#/components/responses/PlatformNotFound" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" "429": - description: Too Many Requests - x-visibility: Public - x-speakeasy-name-override: createToken - x-speakeasy-group: client.authentication - /rest/api/v1/chat: - post: - operationId: chat - summary: Chat - description: Have a conversation with Glean AI. - tags: - - Chat + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: triggers + x-speakeasy-name-override: getPreset security: - APIToken: [] + /api/trigger-presets/{preset_id}/input-values: + get: + tags: + - Triggers + summary: Search trigger preset input values + description: | + Return up to 300 selectable values for a single picklist input on a preset. Results are intended for typeahead selection and are not cursor-paginated. When `is_truncated` is true, refine `query` to narrow the result set. + operationId: platform-trigger-presets-input-values-list + x-glean-scopes: + legacy: + - TRIGGERS + platform: + - triggers:read + x-visibility: Public + x-glean-experimental: + id: 24c5675d-a57a-48cb-9d71-3dece296f28c + introduced: "2026-08-06" parameters: - - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' - requestBody: - description: Includes chat history for Glean AI to respond to. - 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? - required: true - x-exportParamName: Request + - in: path + name: preset_id + description: ID of the preset the input belongs to. + required: true + example: "{preset_id}" + schema: + type: string + minLength: 1 + - in: query + name: field + description: Field identifier of the input whose values to list. + required: true + example: "{field}" + schema: + type: string + minLength: 1 + - in: query + name: query + description: | + Prefix filter over the input's option values, for typeahead. Matching is on the option value, not its display name. + required: false + schema: + type: string responses: "200": - description: OK + description: Successful response. 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 - "202": - description: | - Request accepted but not yet processed. Returned when another - in-flight request is already running for the same chat session; - the body's `queuedRequestId` identifies the deferred run and - output will be persisted to the chat session referenced by - `chatId`. - content: - application/json: - schema: - $ref: '#/components/schemas/ChatResponse' - examples: - queuedExample: - value: - chatId: abc123 - queuedRequestId: qr-xyz - isSavedToChatHistory: true + $ref: "#/components/schemas/PlatformTriggerPresetInputValueListResponse" "400": - description: Invalid request + $ref: "#/components/responses/PlatformBadRequest" "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" + "403": + $ref: "#/components/responses/PlatformForbidden" + "404": + $ref: "#/components/responses/PlatformNotFound" "408": - description: Request Timeout + $ref: "#/components/responses/PlatformRequestTimeout" "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-group: client.chat - x-speakeasy-name-override: create - x-speakeasy-usage-example: true - /rest/api/v1/deleteallchats: - post: - operationId: deleteallchats - summary: Deletes all saved Chats owned by a user - description: Deletes all saved Chats a user has had and all their contained conversational content. - tags: - - Chat + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: triggers + x-speakeasy-name-override: listPresetInputValues security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' - responses: - "200": - description: OK - "400": - description: Invalid request - "401": - description: Not Authorized - "403": - description: Forbidden - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: deleteAll - x-speakeasy-group: client.chat - /rest/api/v1/deletechats: + /api/trigger-presets/{preset_id}/events/search: post: - operationId: deletechats - summary: Deletes saved Chats - description: Deletes saved Chats and all their contained conversational content. tags: - - Chat - security: - - APIToken: [] + - Triggers + summary: Search events for a trigger preset + description: | + Search recent content events an unsaved trigger built from this preset would match, to preview it before creating the trigger. Read-only — no trigger is created and no webhook delivery is made. Covers the last seven days. + operationId: platform-trigger-presets-events-search + x-glean-scopes: + legacy: + - TRIGGERS + platform: + - triggers:read + x-visibility: Public + x-glean-experimental: + id: a48efd80-78d6-46de-9f23-5b8c63ecd157 + introduced: "2026-08-12" parameters: - - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' + - in: path + name: preset_id + description: ID of the preset to preview. + required: true + example: "{preset_id}" + schema: + type: string + minLength: 1 requestBody: + required: false content: application/json: schema: - $ref: '#/components/schemas/DeleteChatsRequest' - required: true - x-exportParamName: Request + $ref: "#/components/schemas/PlatformTriggerPresetEventSearchRequest" responses: "200": - description: OK + description: Successful response. + content: + application/json: + schema: + $ref: "#/components/schemas/PlatformTriggerEventSearchResponse" "400": - description: Invalid request + $ref: "#/components/responses/PlatformBadRequest" "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" "403": - description: Forbidden + $ref: "#/components/responses/PlatformForbidden" + "404": + $ref: "#/components/responses/PlatformNotFound" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" + "413": + $ref: "#/components/responses/PlatformRequestTooLarge" "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: delete - x-speakeasy-group: client.chat - /rest/api/v1/getchat: + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: triggers + x-speakeasy-name-override: searchPresetEvents + security: + - APIToken: [] + /api/chat#stream: post: - operationId: getchat - summary: Retrieves a Chat - description: Retrieves the chat history between Glean Assistant and the user for a given Chat. tags: - Chat - security: - - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' + summary: Create a streaming chat response + description: | + SDK-only logical operation. HTTP clients must call the base path; the URL fragment is not sent. Run an assistant turn as server-sent events. HTTP clients request this mode by setting `stream` to true in the JSON body. + operationId: platform-chat-create-stream + x-glean-scopes: + legacy: + - CHAT + platform: + - chat:write + x-visibility: Public + x-codegen-request-body-name: payload requestBody: + required: true content: application/json: schema: - $ref: '#/components/schemas/GetChatRequest' - required: true - x-exportParamName: Request + allOf: + - $ref: "#/components/schemas/PlatformChatCreateRequest" + - type: object + required: + - stream + properties: + stream: + type: boolean + const: true + default: true responses: "200": - description: OK + description: Successful response. content: - application/json: + text/event-stream: schema: - $ref: '#/components/schemas/GetChatResponse' + $ref: "#/components/schemas/PlatformChatStreamEventServerSentEvent" "400": - description: Invalid request + $ref: "#/components/responses/PlatformBadRequest" "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" "403": - description: Forbidden - content: - application/json: - schema: - $ref: '#/components/schemas/AccessRequestPermissionDeniedResponse' + $ref: "#/components/responses/PlatformForbidden" + "404": + $ref: "#/components/responses/PlatformNotFound" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" + "413": + $ref: "#/components/responses/PlatformRequestTooLarge" + "422": + $ref: "#/components/responses/PlatformUnprocessableEntity" "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: retrieve - x-speakeasy-group: client.chat - /rest/api/v1/listchats: - post: - operationId: listchats - 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. - tags: - - Chat + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: chat + x-speakeasy-name-override: createStream security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' + /api/skills/sources/preview#stream: + post: + tags: + - Skills + summary: Preview a GitHub skill source as events + description: | + SDK-only logical operation. HTTP clients must call the base path; the URL fragment is not sent. Inspect a GitHub URL as server-sent events. HTTP clients request this mode by setting `stream` to true in the JSON body. + operationId: platform-skills-preview-source-stream + x-glean-scopes: + legacy: + - SKILLS + platform: + - skills:write + x-visibility: Public + x-codegen-request-body-name: request + requestBody: + required: true + content: + application/json: + schema: + allOf: + - $ref: "#/components/schemas/PlatformSkillSourcePreviewRequest" + - type: object + required: + - stream + properties: + stream: + type: boolean + const: true + default: true responses: "200": - description: OK + description: Successful response. content: - application/json: + text/event-stream: schema: - $ref: '#/components/schemas/ListChatsResponse' + $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamEventServerSentEvent" + "400": + $ref: "#/components/responses/PlatformBadRequest" "401": - description: Not Authorized + $ref: "#/components/responses/PlatformUnauthorized" "403": - description: Forbidden + $ref: "#/components/responses/PlatformForbidden" + "408": + $ref: "#/components/responses/PlatformRequestTimeout" + "413": + $ref: "#/components/responses/PlatformRequestTooLarge" + "422": + description: Returned when GitHub authorization is missing for the source URL. `authentication_suggestions` names the GitHub action pack to authorize; POST its `server_id` to the Client API's `/tool-servers/{serverId}/auth` with `returnUrl` in the request body to obtain an `authorizationUrl` to redirect the end user to, then retry the preview once OAuth completes. + content: + application/problem+json: + schema: + $ref: "#/components/schemas/PlatformUnauthorizedAgentToolsProblem" "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: list - x-speakeasy-group: client.chat - /rest/api/v1/getchatapplication: + $ref: "#/components/responses/PlatformTooManyRequests" + "500": + $ref: "#/components/responses/PlatformInternalServerError" + "503": + $ref: "#/components/responses/PlatformServiceUnavailable" + x-speakeasy-group: skills + x-speakeasy-name-override: previewSourceStream + security: + - APIToken: [] + /rest/api/v1/activity: post: - operationId: getchatapplication - summary: Gets the metadata for a custom Chat application - description: Gets the Chat application details for the specified application ID. + operationId: activity + summary: Report document activity + description: Report user activity that occurs on indexed documents such as viewing or editing. This signal improves search quality. tags: - - Chat + - Activity security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' requestBody: content: application/json: schema: - $ref: '#/components/schemas/GetChatApplicationRequest' + $ref: '#/components/schemas/Activity' required: true - x-exportParamName: Request + x-exportParamName: Activity responses: "200": description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/GetChatApplicationResponse' "400": description: Invalid request "401": description: Not Authorized - "403": - description: Forbidden + "429": + description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: retrieveApplication - x-speakeasy-group: client.chat - /rest/api/v1/uploadchatfiles: + x-speakeasy-name-override: report + x-speakeasy-group: client.activity + /rest/api/v1/feedback: post: - operationId: uploadchatfiles - summary: Upload files for Chat - description: Upload files for Chat. + operationId: feedback + 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. tags: - - Chat + - Activity security: - APIToken: [] parameters: - - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' + - name: feedback + in: query + description: A URL encoded versions of Feedback. This is useful for requests. + required: false + schema: + type: string requestBody: content: - multipart/form-data: + application/json: schema: - $ref: '#/components/schemas/UploadChatFilesRequest' - required: true - x-exportParamName: Request + $ref: '#/components/schemas/Feedback' + x-exportParamName: Feedback 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-visibility: Public - x-speakeasy-name-override: uploadFiles - x-speakeasy-group: client.chat - /rest/api/v1/getchatfiles: + x-codegen-request-body-name: payload + x-speakeasy-group: client.activity + /rest/api/v1/createannouncement: post: - operationId: getchatfiles - summary: Get files uploaded by a user for Chat - description: Get files uploaded by a user for Chat. + operationId: createannouncement + summary: Create Announcement + description: Create a textual announcement visible to some set of users based on department and location. tags: - - Chat + - Announcements security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' requestBody: + description: Announcement content content: application/json: schema: - $ref: '#/components/schemas/GetChatFilesRequest' + $ref: '#/components/schemas/CreateAnnouncementRequest' required: true x-exportParamName: Request responses: @@ -2772,36 +3167,36 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/GetChatFilesResponse' + $ref: '#/components/schemas/Announcement' "400": description: Invalid request "401": description: Not Authorized - "403": - description: Forbidden "429": description: Too Many Requests x-visibility: Public - x-speakeasy-name-override: retrieveFiles - x-speakeasy-group: client.chat - /rest/api/v1/deletechatfiles: + x-codegen-request-body-name: payload + x-speakeasy-name-override: create + x-speakeasy-group: client.announcements + /rest/api/v1/deleteannouncement: post: - operationId: deletechatfiles - summary: Delete files uploaded by a user for chat - description: Delete files uploaded by a user for Chat. + operationId: deleteannouncement + summary: Delete Announcement + description: Delete an existing user-generated announcement. tags: - - Chat + - Announcements security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' requestBody: + description: Delete announcement request content: application/json: schema: - $ref: '#/components/schemas/DeleteChatFilesRequest' + $ref: '#/components/schemas/DeleteAnnouncementRequest' required: true + x-exportParamName: Request responses: "200": description: OK @@ -2809,682 +3204,527 @@ paths: description: Invalid request "401": description: Not Authorized - "403": - description: Forbidden "429": description: Too Many Requests x-visibility: Public - x-speakeasy-name-override: deleteFiles - x-speakeasy-group: client.chat - /rest/api/v1/chat-files/{fileId}: - get: - operationId: getChatFile - summary: Download a chat file - description: | - Download the raw content of a file generated or uploaded during a chat session (for example, an image produced by the assistant). Returns the file bytes with a Content-Type header matching the file's MIME type. + x-codegen-request-body-name: payload + x-speakeasy-name-override: delete + x-speakeasy-group: client.announcements + /rest/api/v1/updateannouncement: + post: + operationId: updateannouncement + summary: Update Announcement + description: Update a textual announcement visible to some set of users based on department and location. tags: - - Chat + - Announcements security: - APIToken: [] parameters: - - name: fileId - in: path - description: Identifier of the chat file to download. - required: true - schema: - type: string - - name: preview - in: query - description: | - When true and the file is a PDF, the response is served inline (Content-Disposition: inline) instead of as an attachment. - required: false - schema: - type: boolean + - $ref: '#/components/parameters/locale' + requestBody: + description: Announcement content. Id need to be specified for the announcement. + content: + application/json: + schema: + $ref: '#/components/schemas/UpdateAnnouncementRequest' + required: true + x-exportParamName: Request responses: "200": - description: File content. + description: OK content: - application/octet-stream: + application/json: schema: - type: string - format: binary + $ref: '#/components/schemas/Announcement' "400": - description: File ID missing from path. + description: Invalid request "401": - description: Missing or invalid API token. - "403": - description: Caller does not have access to the file. - "404": - description: File not found. - "500": - description: Internal server error. + description: Not Authorized + "429": + description: Too Many Requests x-visibility: Public - x-speakeasy-name-override: retrieveFile - x-speakeasy-group: client.chat - /rest/api/v1/agents: + x-codegen-request-body-name: payload + x-speakeasy-name-override: update + x-speakeasy-group: client.announcements + /rest/api/v1/createanswer: post: - operationId: createAgent - summary: Create an agent - description: Create an agent. + operationId: createanswer + summary: Create Answer + description: Create a user-generated Answer that contains a question and answer. tags: - - Agents + - Answers security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' requestBody: + description: CreateAnswer request content: application/json: schema: - $ref: '#/components/schemas/CreateWorkflowRequest' + $ref: '#/components/schemas/CreateAnswerRequest' required: true + x-exportParamName: Request responses: "200": - description: Success + description: OK content: application/json: schema: - $ref: '#/components/schemas/CreateWorkflowResponse' + $ref: '#/components/schemas/Answer' "400": - description: Bad request + description: Invalid request "401": description: Not Authorized - "403": - description: Forbidden - "500": - description: Internal server error + "429": + description: Too Many Requests x-visibility: Public - x-speakeasy-group: client.agents + x-codegen-request-body-name: payload x-speakeasy-name-override: create - /rest/api/v1/agents/{agent_id}: - get: - operationId: getAgent - summary: Retrieve an agent - description: Returns details of an [agent](https://developers.glean.com/agents/agents-api) created in the Agent Builder. - tags: - - Agents - security: - - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' - - name: agent_id - in: path - description: The ID of the agent. - required: true - schema: - type: string - title: Agent ID - description: The ID of the agent. - 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 - deprecated: true - x-visibility: Public - x-glean-deprecated: - docs: https://developers.glean.com/api/platform-api/agents-overview - id: e01a59ea-5de0-481f-97b6-d28dd65379e6 - introduced: "2026-08-25" - message: Use GET /api/agents/{agent_id} instead. - removal: "2027-04-15" - x-speakeasy-deprecation-message: "Deprecated on 2026-08-25, removal scheduled for 2027-04-15: Use GET /api/agents/{agent_id} instead." - x-speakeasy-group: client.agents - x-speakeasy-name-override: retrieve + x-speakeasy-group: client.answers + /rest/api/v1/deleteanswer: post: - operationId: editAgent - summary: Edit an agent - description: Creates a draft or publishes an [agent](https://developers.glean.com/agents/agents-api). Use `isDraft=true` to save a draft, or `isDraft=false` (or omit) to publish immediately. Only draft and publish modes are supported. + operationId: deleteanswer + summary: Delete Answer + description: Delete an existing user-generated Answer. tags: - - Agents + - Answers security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' - - name: agent_id - in: path - description: The ID of the agent. - required: true - schema: - type: string - title: Agent ID - description: The ID of the agent. requestBody: + description: DeleteAnswer request content: application/json: schema: - $ref: '#/components/schemas/EditWorkflowRequest' + $ref: '#/components/schemas/DeleteAnswerRequest' required: true + x-exportParamName: Request responses: "200": - description: Success + description: OK "400": - description: Bad request + description: Invalid request "401": description: Not Authorized - "403": - description: Forbidden - "404": - description: Not Found - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - "500": - description: Internal server error + "429": + description: Too Many Requests x-visibility: Public - x-speakeasy-group: client.agents - x-speakeasy-name-override: update - /rest/api/v1/agents/{agent_id}/schemas: - get: - operationId: getAgentSchemas - summary: List an agent's schemas - description: Return [agent](https://developers.glean.com/agents/agents-api)'s input and output schemas. You can use these schemas to detect changes to an agent's input or output structure. + x-codegen-request-body-name: payload + x-speakeasy-name-override: delete + x-speakeasy-group: client.answers + /rest/api/v1/editanswer: + post: + operationId: editanswer + summary: Update Answer + description: Update an existing user-generated Answer. tags: - - Agents + - Answers security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' - - name: agent_id - in: path - description: The ID of the agent. - required: true - schema: - type: string - title: Agent Id - description: The ID of the agent. + requestBody: + description: EditAnswer request + content: + application/json: + schema: + $ref: '#/components/schemas/EditAnswerRequest' + required: true + x-exportParamName: Request responses: "200": - description: Success + description: OK content: application/json: schema: - $ref: '#/components/schemas/AgentSchemas' + $ref: '#/components/schemas/Answer' "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 - deprecated: true + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests x-visibility: Public - x-glean-deprecated: - docs: https://developers.glean.com/api/platform-api/agents-overview - id: 9ca398ba-cf22-4523-9d9c-86e5f82d6ec7 - introduced: "2026-08-25" - message: Use GET /api/agents/{agent_id}/schemas instead. - removal: "2027-04-15" - x-speakeasy-deprecation-message: "Deprecated on 2026-08-25, removal scheduled for 2027-04-15: Use GET /api/agents/{agent_id}/schemas instead." - x-speakeasy-group: client.agents - x-speakeasy-name-override: retrieveSchemas - /rest/api/v1/agents/{agent_id}/import: + x-codegen-request-body-name: payload + x-speakeasy-name-override: update + x-speakeasy-group: client.answers + /rest/api/v1/getanswer: post: - operationId: importAgent - summary: Import an agent - description: 'Imports an [agent](https://developers.glean.com/agents/agents-api) from its on-disk folder representation (spec.yaml, instructions.md, skills/, subagents/) packaged as a zip, and creates or updates the agent. Inverse of the export flow: the folder-to-schema conversion runs server-side. The bundle must contain only regular files; symlinks are resolved by the caller at packaging time.' + operationId: getanswer + summary: Read Answer + description: Read the details of a particular Answer given its ID. tags: - - Agents + - Answers security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' - - $ref: '#/components/parameters/timezoneOffset' - - name: agent_id - in: path - description: The ID of the agent to create or update. - required: true - schema: - type: string - title: Agent ID - description: The ID of the agent to create or update. requestBody: + description: GetAnswer request content: - multipart/form-data: + application/json: schema: - $ref: '#/components/schemas/ImportAgentRequest' + $ref: '#/components/schemas/GetAnswerRequest' required: true + x-exportParamName: Request responses: "200": - description: Success + description: OK content: application/json: schema: - $ref: '#/components/schemas/ImportAgentResponse' + $ref: '#/components/schemas/GetAnswerResponse' "400": - description: Bad request + description: Invalid request "401": description: Not Authorized - "403": - description: Forbidden - "404": - description: Not Found - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - "500": - description: Internal server error + "429": + description: Too Many Requests x-visibility: Public - x-speakeasy-group: client.agents - x-speakeasy-name-override: import - /rest/api/v1/agents/search: + x-codegen-request-body-name: payload + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.answers + /rest/api/v1/listanswers: post: - operationId: searchAgents - summary: Search agents - description: Search for [agents](https://developers.glean.com/agents/agents-api) by agent name. + operationId: listanswers + summary: List Answers + description: List Answers created by the current user. tags: - - Agents + - Answers security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: ListAnswers request content: application/json: schema: - $ref: '#/components/schemas/SearchAgentsRequest' + $ref: '#/components/schemas/ListAnswersRequest' required: true + x-exportParamName: Request responses: "200": - description: Success + description: OK content: application/json: schema: - $ref: '#/components/schemas/SearchAgentsResponse' + $ref: '#/components/schemas/ListAnswersResponse' "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 - deprecated: true - x-visibility: Public - x-glean-deprecated: - docs: https://developers.glean.com/api/platform-api/agents-overview - id: 3ab6f4c0-0b97-4a0b-b5da-e888e4bb7706 - introduced: "2026-08-25" - message: Use POST /api/agents/search instead. - removal: "2027-04-15" - x-speakeasy-deprecation-message: "Deprecated on 2026-08-25, removal scheduled for 2027-04-15: Use POST /api/agents/search instead." - x-speakeasy-group: client.agents - x-speakeasy-name-override: list - /rest/api/v1/agents/runs/stream: - post: - operationId: createAndStreamRun - summary: Create an agent run and stream the response - description: 'Executes an [agent](https://developers.glean.com/agents/agents-api) run and returns the result as a stream of server-sent events (SSE). **Note**: If the agent uses an input form trigger, all form fields (including optional fields) must be included in the `input` object.' - tags: - - Agents - security: - - APIToken: [] - 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 server-sent events (SSE) format. If execution fails after the stream has started, the stream may terminate with an error message in a normal `message` event. - example: | - id: 1 - event: message - data: {"messages":[{"role":"GLEAN_AI","content":[{"text":"Hello","type":"text"}]}]} - - id: 2 - event: message - data: {"messages":[{"role":"GLEAN_AI","content":[{"text":",","type":"text"}]}]} - - id: 3 - event: message - data: {"messages":[{"role":"GLEAN_AI","content":[{"text":" I'm","type":"text"}]}]} - - id: 4 - event: message - data: {"messages":[{"role":"GLEAN_AI","content":[{"text":" your","type":"text"}]}]} - "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: Returned when the agent has tools the caller has not authorized. The response body enumerates the tools that need connecting. - content: - application/json: - schema: - $ref: '#/components/schemas/UnauthorizedAgentToolsError' - "500": - description: Internal server error - deprecated: true - x-visibility: Public - x-glean-deprecated: - docs: https://developers.glean.com/api/platform-api/agents-overview - id: db3f42a5-8820-451e-b57a-14bf6ca3915c - introduced: "2026-08-25" - message: Use POST /api/agents/{agent_id}/runs with stream=true instead. - removal: "2027-04-15" - x-speakeasy-deprecation-message: "Deprecated on 2026-08-25, removal scheduled for 2027-04-15: Use POST /api/agents/{agent_id}/runs with stream=true instead." - x-speakeasy-group: client.agents - x-speakeasy-name-override: runStream - /rest/api/v1/agents/runs/wait: - post: - operationId: createAndWaitRun - summary: Create an agent run and wait for the response - description: 'Executes an [agent](https://developers.glean.com/agents/agents-api) run and returns the final response. **Note**: If the agent uses an input form trigger, all form fields (including optional fields) must be included in the `input` object.' - tags: - - Agents - security: - - APIToken: [] - 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: Returned when the agent has tools the caller has not authorized. The response body enumerates the tools that need connecting. - content: - application/json: - schema: - $ref: '#/components/schemas/UnauthorizedAgentToolsError' - "500": - description: Internal server error + description: Invalid request + "401": + description: Not Authorized + "429": + description: Too Many Requests deprecated: true x-visibility: Public + x-codegen-request-body-name: payload x-glean-deprecated: - docs: https://developers.glean.com/api/platform-api/agents-overview - id: 683b90e1-48d3-4d7a-a32d-b48eb194fcf0 - introduced: "2026-08-25" - message: Use POST /api/agents/{agent_id}/runs instead. - removal: "2027-04-15" - x-speakeasy-deprecation-message: "Deprecated on 2026-08-25, removal scheduled for 2027-04-15: Use POST /api/agents/{agent_id}/runs instead." - x-speakeasy-group: client.agents - x-speakeasy-name-override: run - /rest/api/v1/addcollectionitems: + id: 4c0923bd-64c7-45b9-99a5-b36f2705e618 + introduced: "2026-01-21" + message: Answer boards have been removed and this endpoint no longer serves a purpose + removal: "2026-10-15" + x-speakeasy-deprecation-message: "Deprecated on 2026-01-21, removal scheduled for 2026-10-15: Answer boards have been removed and this endpoint no longer serves a purpose" + x-speakeasy-name-override: list + x-speakeasy-group: client.answers + /rest/api/v1/checkdatasourceauth: post: - operationId: addcollectionitems - summary: Add Collection item - description: Add items to a Collection. + operationId: checkdatasourceauth + summary: Check datasource authorization + description: | + Returns all datasource instances that require per-user OAuth authorization + for the authenticated user, along with a transient auth token that can be + appended to auth URLs to complete OAuth flows. + + Clients construct the full OAuth URL by combining the backend base URL, + the `authUrlRelativePath` from each instance, and the transient auth token: + `/?transient_auth_token=`. tags: - - Collections + - Authentication security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' - requestBody: - description: Data describing the add operation. - content: - application/json: - schema: - $ref: '#/components/schemas/AddCollectionItemsRequest' - required: true - x-exportParamName: Request + parameters: [] responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/AddCollectionItemsResponse' - "400": - description: Invalid request + $ref: '#/components/schemas/CheckDatasourceAuthResponse' "401": description: Not Authorized "429": description: Too Many Requests x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: addItems - x-speakeasy-group: client.collections - /rest/api/v1/createcollection: + x-speakeasy-name-override: checkDatasourceAuth + x-speakeasy-group: client.authentication + /rest/api/v1/createauthtoken: post: - operationId: createcollection - summary: Create Collection - description: Create a publicly visible (empty) Collection of documents. + operationId: createauthtoken + summary: Create authentication token + description: | + Creates an authentication token for the authenticated user. These are + specifically intended to be used with the [Web SDK](https://developers.glean.com/web). + + Note: The tokens generated from this endpoint are **not** valid tokens + for use with the Client API (e.g. `/rest/api/v1/*`). tags: - - Collections + - Authentication security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' - requestBody: - description: Collection content plus any additional metadata for the request. - content: - application/json: - schema: - $ref: '#/components/schemas/CreateCollectionRequest' - required: true - x-exportParamName: Request + parameters: [] responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/CreateCollectionResponse' + $ref: '#/components/schemas/CreateAuthTokenResponse' "400": - description: Invalid request + 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-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-group: client.collections - x-speakeasy-name-override: create - /rest/api/v1/deletecollection: + x-speakeasy-name-override: createToken + x-speakeasy-group: client.authentication + /rest/api/v1/chat: post: - operationId: deletecollection - summary: Delete Collection - description: Delete a Collection given the Collection's ID. + operationId: chat + summary: Chat + description: Have a conversation with Glean AI. tags: - - Collections + - Chat security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' + - $ref: '#/components/parameters/timezoneOffset' requestBody: - description: DeleteCollection request + description: Includes chat history for Glean AI to respond to. content: application/json: schema: - $ref: '#/components/schemas/DeleteCollectionRequest' + $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? 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' + $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 + "202": + description: | + Request accepted but not yet processed. Returned when another + in-flight request is already running for the same chat session; + the body's `queuedRequestId` identifies the deferred run and + output will be persisted to the chat session referenced by + `chatId`. + content: + application/json: + schema: + $ref: '#/components/schemas/ChatResponse' + examples: + queuedExample: + value: + chatId: abc123 + queuedRequestId: qr-xyz + isSavedToChatHistory: true + "400": + description: Invalid request + "401": + description: Not Authorized + "408": + description: Request Timeout "429": description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: delete - x-speakeasy-group: client.collections - /rest/api/v1/deletecollectionitem: + x-speakeasy-group: client.chat + x-speakeasy-name-override: create + x-speakeasy-usage-example: true + /rest/api/v1/deleteallchats: post: - operationId: deletecollectionitem - summary: Delete Collection item - description: Delete a single item from a Collection. + operationId: deleteallchats + summary: Deletes all saved Chats owned by a user + description: Deletes all saved Chats a user has had and all their contained conversational content. tags: - - Collections + - Chat security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' - requestBody: - description: Data describing the delete operation. - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteCollectionItemRequest' - required: true - x-exportParamName: Request + - $ref: '#/components/parameters/timezoneOffset' 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 + "403": + description: Forbidden x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: deleteItem - x-speakeasy-group: client.collections - /rest/api/v1/editcollection: + x-speakeasy-name-override: deleteAll + x-speakeasy-group: client.chat + /rest/api/v1/deletechats: post: - operationId: editcollection - summary: Update Collection - description: Update the properties of an existing Collection. + operationId: deletechats + summary: Deletes saved Chats + description: Deletes saved Chats and all their contained conversational content. tags: - - Collections + - Chat security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' + - $ref: '#/components/parameters/timezoneOffset' requestBody: - description: Collection content plus any additional metadata for the request. content: application/json: schema: - $ref: '#/components/schemas/EditCollectionRequest' + $ref: '#/components/schemas/DeleteChatsRequest' 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' + "403": + description: Forbidden "429": description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: update - x-speakeasy-group: client.collections - /rest/api/v1/editcollectionitem: + x-speakeasy-name-override: delete + x-speakeasy-group: client.chat + /rest/api/v1/getchat: post: - operationId: editcollectionitem - summary: Update Collection item - description: Update the URL, Glean Document ID, description of an item within a Collection given its ID. + operationId: getchat + summary: Retrieves a Chat + description: Retrieves the chat history between Glean Assistant and the user for a given Chat. tags: - - Collections + - Chat security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' + - $ref: '#/components/parameters/timezoneOffset' requestBody: - description: Edit Collection Items request content: application/json: schema: - $ref: '#/components/schemas/EditCollectionItemRequest' + $ref: '#/components/schemas/GetChatRequest' required: true x-exportParamName: Request responses: @@ -3493,70 +3733,69 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/EditCollectionItemResponse' + $ref: '#/components/schemas/GetChatResponse' "400": description: Invalid request "401": description: Not Authorized + "403": + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/AccessRequestPermissionDeniedResponse' "429": description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: updateItem - x-speakeasy-group: client.collections - /rest/api/v1/getcollection: + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.chat + /rest/api/v1/listchats: post: - operationId: getcollection - summary: Read Collection - description: Read the details of a Collection given its ID. Does not fetch items in this Collection. + operationId: listchats + 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. tags: - - Collections + - Chat security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' - requestBody: - description: GetCollection request - content: - application/json: - schema: - $ref: '#/components/schemas/GetCollectionRequest' - required: true - x-exportParamName: Request + - $ref: '#/components/parameters/timezoneOffset' responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/GetCollectionResponse' - "400": - description: Invalid request + $ref: '#/components/schemas/ListChatsResponse' "401": description: Not Authorized + "403": + description: Forbidden "429": description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: retrieve - x-speakeasy-group: client.collections - /rest/api/v1/listcollections: + x-speakeasy-name-override: list + x-speakeasy-group: client.chat + /rest/api/v1/getchatapplication: post: - operationId: listcollections - summary: List Collections - description: List all existing Collections. + operationId: getchatapplication + summary: Gets the metadata for a custom Chat application + description: Gets the Chat application details for the specified application ID. tags: - - Collections + - Chat security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' + - $ref: '#/components/parameters/timezoneOffset' requestBody: - description: ListCollections request content: application/json: schema: - $ref: '#/components/schemas/ListCollectionsRequest' + $ref: '#/components/schemas/GetChatApplicationRequest' required: true x-exportParamName: Request responses: @@ -3565,34 +3804,34 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ListCollectionsResponse' + $ref: '#/components/schemas/GetChatApplicationResponse' "400": description: Invalid request "401": description: Not Authorized - "429": - description: Too Many Requests + "403": + description: Forbidden x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: list - x-speakeasy-group: client.collections - /rest/api/v1/getdocpermissions: - post: - operationId: getdocpermissions - summary: Read document permissions - description: Read the emails of all users who have access to the given document. + x-speakeasy-name-override: retrieveApplication + x-speakeasy-group: client.chat + /rest/api/v1/uploadchatfiles: + post: + operationId: uploadchatfiles + summary: Upload files for Chat + description: Upload files for Chat. tags: - - Documents + - Chat security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' + - $ref: '#/components/parameters/timezoneOffset' requestBody: - description: Document permissions request content: - application/json: + multipart/form-data: schema: - $ref: '#/components/schemas/GetDocPermissionsRequest' + $ref: '#/components/schemas/UploadChatFilesRequest' required: true x-exportParamName: Request responses: @@ -3601,7 +3840,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/GetDocPermissionsResponse' + $ref: '#/components/schemas/UploadChatFilesResponse' "400": description: Invalid request "401": @@ -3611,470 +3850,586 @@ paths: "429": description: Too Many Requests x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: retrievePermissions - x-speakeasy-group: client.documents - /rest/api/v1/getdocuments: + x-speakeasy-name-override: uploadFiles + x-speakeasy-group: client.chat + /rest/api/v1/getchatfiles: post: - operationId: getdocuments - 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: getchatfiles + summary: Get files uploaded by a user for Chat + description: Get files uploaded by a user for Chat. tags: - - Documents + - Chat security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' + - $ref: '#/components/parameters/timezoneOffset' requestBody: - description: Information about documents requested. content: application/json: schema: - $ref: '#/components/schemas/GetDocumentsRequest' + $ref: '#/components/schemas/GetChatFilesRequest' + required: true + x-exportParamName: Request responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/GetDocumentsResponse' + $ref: '#/components/schemas/GetChatFilesResponse' "400": description: Invalid request "401": description: Not Authorized "403": - description: Documents does not exist, or user cannot access documents. + description: Forbidden "429": description: Too Many Requests x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: retrieve - x-speakeasy-group: client.documents - /rest/api/v1/getdocumentsbyfacets: + x-speakeasy-name-override: retrieveFiles + x-speakeasy-group: client.chat + /rest/api/v1/deletechatfiles: post: - operationId: getdocumentsbyfacets - summary: Read documents by facets - description: Read the documents including metadata (does not include enhanced metadata via `/documentmetadata`) macthing the given facet conditions. + operationId: deletechatfiles + summary: Delete files uploaded by a user for chat + description: Delete files uploaded by a user for Chat. tags: - - Documents + - Chat security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' + - $ref: '#/components/parameters/timezoneOffset' requestBody: - description: Information about facet conditions for documents to be retrieved. content: application/json: schema: - $ref: '#/components/schemas/GetDocumentsByFacetsRequest' + $ref: '#/components/schemas/DeleteChatFilesRequest' + required: true responses: "200": description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/GetDocumentsByFacetsResponse' "400": description: Invalid request "401": description: Not Authorized - "404": - description: Not Found + "403": + description: Forbidden "429": description: Too Many Requests x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: retrieveByFacets - x-speakeasy-group: client.documents - /rest/api/v1/insights: - post: - operationId: insights - summary: Get insights - description: Gets the aggregate usage insights data displayed in the Insights Dashboards. + x-speakeasy-name-override: deleteFiles + x-speakeasy-group: client.chat + /rest/api/v1/chat-files/{fileId}: + get: + operationId: getChatFile + summary: Download a chat file + description: | + Download the raw content of a file generated or uploaded during a chat session (for example, an image produced by the assistant). Returns the file bytes with a Content-Type header matching the file's MIME type. tags: - - Insights + - Chat security: - APIToken: [] parameters: - - $ref: '#/components/parameters/locale' - requestBody: - description: Includes request parameters for insights requests. - content: - application/json: - schema: - $ref: '#/components/schemas/InsightsRequest' - required: true - x-exportParamName: InsightsRequest + - name: fileId + in: path + description: Identifier of the chat file to download. + required: true + schema: + type: string + - name: preview + in: query + description: | + When true and the file is a PDF, the response is served inline (Content-Disposition: inline) instead of as an attachment. + required: false + schema: + type: boolean responses: "200": - description: OK + description: File content. content: - application/json: + application/octet-stream: schema: - $ref: '#/components/schemas/InsightsResponse' + type: string + format: binary "400": - description: Invalid request + description: File ID missing from path. "401": - description: Not Authorized - "429": - description: Too Many Requests + description: Missing or invalid API token. + "403": + description: Caller does not have access to the file. + "404": + description: File not found. + "500": + description: Internal server error. x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: retrieve - x-speakeasy-group: client.insights - /rest/api/v1/messages: + x-speakeasy-name-override: retrieveFile + x-speakeasy-group: client.chat + /rest/api/v1/agents: post: - operationId: messages - summary: Read messages - description: Retrieves list of messages from messaging/chat datasources (e.g. Slack, Teams). + operationId: createAgent + summary: Create an agent + description: Create an agent. tags: - - Messages + - Agents security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' + - $ref: '#/components/parameters/timezoneOffset' requestBody: - description: Includes request params such as the id for channel/message and direction. content: application/json: schema: - $ref: '#/components/schemas/MessagesRequest' + $ref: '#/components/schemas/CreateWorkflowRequest' required: true - x-exportParamName: MessagesRequest responses: "200": - description: OK + description: Success content: application/json: schema: - $ref: '#/components/schemas/MessagesResponse' + $ref: '#/components/schemas/CreateWorkflowResponse' "400": - description: Invalid request + description: Bad request "401": description: Not Authorized - "429": - description: Too Many Requests + "403": + description: Forbidden + "500": + description: Internal server error x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: retrieve - x-speakeasy-group: client.messages - /rest/api/v1/editpin: - post: - operationId: editpin - summary: Update pin - description: Update an existing user-generated pin. + x-speakeasy-group: client.agents + x-speakeasy-name-override: create + /rest/api/v1/agents/{agent_id}: + get: + operationId: getAgent + summary: Retrieve an agent + description: Returns details of an [agent](https://developers.glean.com/agents/agents-api) created in the Agent Builder. tags: - - Pins + - Agents security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' - requestBody: - description: Edit pins request - content: - application/json: - schema: - $ref: '#/components/schemas/EditPinRequest' - required: true - x-exportParamName: Request + - $ref: '#/components/parameters/timezoneOffset' + - name: agent_id + in: path + description: The ID of the agent. + required: true + schema: + type: string + title: Agent ID + description: The ID of the agent. responses: "200": - description: OK + description: Success content: application/json: schema: - $ref: '#/components/schemas/PinDocument' + $ref: '#/components/schemas/Agent' "400": - description: Invalid request - "401": - description: Not Authorized - "429": - description: Too Many Requests + description: Bad request + "403": + description: Forbidden + "404": + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + "500": + description: Internal server error + deprecated: true x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: update - x-speakeasy-group: client.pins - /rest/api/v1/getpin: + x-glean-deprecated: + docs: https://developers.glean.com/api/platform-api/agents-overview + id: e01a59ea-5de0-481f-97b6-d28dd65379e6 + introduced: "2026-08-25" + message: Use GET /api/agents/{agent_id} instead. + removal: "2027-04-15" + x-speakeasy-deprecation-message: "Deprecated on 2026-08-25, removal scheduled for 2027-04-15: Use GET /api/agents/{agent_id} instead." + x-speakeasy-group: client.agents + x-speakeasy-name-override: retrieve post: - operationId: getpin - summary: Read pin - description: Read pin details given its ID. + operationId: editAgent + summary: Edit an agent + description: Creates a draft or publishes an [agent](https://developers.glean.com/agents/agents-api). Use `isDraft=true` to save a draft, or `isDraft=false` (or omit) to publish immediately. Only draft and publish modes are supported. tags: - - Pins + - Agents security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' + - $ref: '#/components/parameters/timezoneOffset' + - name: agent_id + in: path + description: The ID of the agent. + required: true + schema: + type: string + title: Agent ID + description: The ID of the agent. requestBody: - description: Get pin request content: application/json: schema: - $ref: '#/components/schemas/GetPinRequest' + $ref: '#/components/schemas/EditWorkflowRequest' required: true - x-exportParamName: Request responses: "200": - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/GetPinResponse' + description: Success "400": - description: Invalid request + description: Bad request "401": description: Not Authorized - "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: retrieve - x-speakeasy-group: client.pins - /rest/api/v1/listpins: - post: - operationId: listpins - summary: List pins - description: Lists all pins. - tags: - - Pins - security: - - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' - requestBody: - description: List pins request - content: - application/json: - schema: - type: object - required: true - x-exportParamName: Request - responses: - "200": - description: OK + "403": + description: Forbidden + "404": + description: Not Found content: application/json: schema: - $ref: '#/components/schemas/ListPinsResponse' - "400": - description: Invalid request - "401": - description: Not Authorized - "429": - description: Too Many Requests + $ref: '#/components/schemas/ErrorResponse' + "500": + description: Internal server error x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: list - x-speakeasy-group: client.pins - /rest/api/v1/pin: - post: - operationId: pin - 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. + x-speakeasy-group: client.agents + x-speakeasy-name-override: update + /rest/api/v1/agents/{agent_id}/schemas: + get: + operationId: getAgentSchemas + summary: List an agent's schemas + description: Return [agent](https://developers.glean.com/agents/agents-api)'s input and output schemas. You can use these schemas to detect changes to an agent's input or output structure. tags: - - Pins + - Agents security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' - requestBody: - description: Details about the document and query for the pin. - content: - application/json: - schema: - $ref: '#/components/schemas/PinRequest' - required: true - x-exportParamName: PinDocument + - $ref: '#/components/parameters/timezoneOffset' + - name: agent_id + in: path + description: The ID of the agent. + required: true + schema: + type: string + title: Agent Id + description: The ID of the agent. responses: "200": - description: OK + description: Success content: application/json: schema: - $ref: '#/components/schemas/PinDocument' + $ref: '#/components/schemas/AgentSchemas' "400": - description: Invalid request - "401": - description: Not Authorized - "429": - description: Too Many Requests + 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 + deprecated: true x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: create - x-speakeasy-group: client.pins - /rest/api/v1/unpin: + x-glean-deprecated: + docs: https://developers.glean.com/api/platform-api/agents-overview + id: 9ca398ba-cf22-4523-9d9c-86e5f82d6ec7 + introduced: "2026-08-25" + message: Use GET /api/agents/{agent_id}/schemas instead. + removal: "2027-04-15" + x-speakeasy-deprecation-message: "Deprecated on 2026-08-25, removal scheduled for 2027-04-15: Use GET /api/agents/{agent_id}/schemas instead." + x-speakeasy-group: client.agents + x-speakeasy-name-override: retrieveSchemas + /rest/api/v1/agents/{agent_id}/import: post: - operationId: unpin - summary: Delete pin - description: Unpin a previously pinned result. + operationId: importAgent + summary: Import an agent + description: 'Imports an [agent](https://developers.glean.com/agents/agents-api) from its on-disk folder representation (spec.yaml, instructions.md, skills/, subagents/) packaged as a zip, and creates or updates the agent. Inverse of the export flow: the folder-to-schema conversion runs server-side. The bundle must contain only regular files; symlinks are resolved by the caller at packaging time.' tags: - - Pins + - Agents security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' + - $ref: '#/components/parameters/timezoneOffset' + - name: agent_id + in: path + description: The ID of the agent to create or update. + required: true + schema: + type: string + title: Agent ID + description: The ID of the agent to create or update. requestBody: - description: Details about the pin being unpinned. content: - application/json: + multipart/form-data: schema: - $ref: '#/components/schemas/Unpin' + $ref: '#/components/schemas/ImportAgentRequest' required: true - x-exportParamName: Unpin responses: "200": - description: OK + description: Success + content: + application/json: + schema: + $ref: '#/components/schemas/ImportAgentResponse' "400": - description: Invalid request + description: Bad request "401": description: Not Authorized "403": - description: Forbidden from unpinning someone else's pin - "429": - description: Too Many Requests + description: Forbidden + "404": + description: Not Found + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + "500": + description: Internal server error x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-name-override: remove - x-speakeasy-group: client.pins - /rest/api/v1/adminsearch: + x-speakeasy-group: client.agents + x-speakeasy-name-override: import + /rest/api/v1/agents/search: post: - operationId: adminsearch - summary: Search the index (admin) - description: Retrieves results for search query without respect for permissions. This is available only to privileged users. + operationId: searchAgents + summary: Search agents + description: Search for [agents](https://developers.glean.com/agents/agents-api) by agent name. tags: - - Search + - Agents security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' requestBody: - description: Admin search request content: application/json: schema: - $ref: '#/components/schemas/SearchRequest' + $ref: '#/components/schemas/SearchAgentsRequest' required: true - x-exportParamName: Request responses: "200": - description: OK + description: Success content: application/json: schema: - $ref: '#/components/schemas/SearchResponse' + $ref: '#/components/schemas/SearchAgentsResponse' "400": - description: Invalid request - "401": - description: Not Authorized + description: Bad request "403": description: Forbidden + "404": + description: Not Found content: application/json: schema: - $ref: '#/components/schemas/ErrorInfo' + $ref: '#/components/schemas/ErrorResponse' "422": - description: Invalid Query + description: Validation Error content: application/json: schema: - $ref: '#/components/schemas/ErrorInfo' - "429": - description: Too Many Requests + $ref: '#/components/schemas/ErrorResponse' + "500": + description: Internal server error + deprecated: true x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-group: client.search - x-speakeasy-name-override: queryAsAdmin - /rest/api/v1/autocomplete: + x-glean-deprecated: + docs: https://developers.glean.com/api/platform-api/agents-overview + id: 3ab6f4c0-0b97-4a0b-b5da-e888e4bb7706 + introduced: "2026-08-25" + message: Use POST /api/agents/search instead. + removal: "2027-04-15" + x-speakeasy-deprecation-message: "Deprecated on 2026-08-25, removal scheduled for 2027-04-15: Use POST /api/agents/search instead." + x-speakeasy-group: client.agents + x-speakeasy-name-override: list + /rest/api/v1/agents/runs/stream: post: - operationId: autocomplete - summary: Autocomplete - description: Retrieve query suggestions, operators and documents for the given partially typed query. + operationId: createAndStreamRun + summary: Create an agent run and stream the response + description: 'Executes an [agent](https://developers.glean.com/agents/agents-api) run and returns the result as a stream of server-sent events (SSE). **Note**: If the agent uses an input form trigger, all form fields (including optional fields) must be included in the `input` object.' tags: - - Search + - Agents security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/locale' requestBody: - description: Autocomplete request content: application/json: schema: - $ref: '#/components/schemas/AutocompleteRequest' + $ref: '#/components/schemas/AgentRunCreate' required: true - x-exportParamName: Request responses: "200": - description: OK + description: Success content: - application/json: + text/event-stream: schema: - $ref: '#/components/schemas/AutocompleteResponse' - "400": - description: Invalid request - "401": - description: Not Authorized - "429": - description: Too Many Requests - x-visibility: Public - x-codegen-request-body-name: payload - x-speakeasy-group: client.search - x-speakeasy-name-override: autocomplete - /rest/api/v1/feed: - post: - operationId: feed - summary: Feed of documents and events - description: The personalized feed/home includes different types of contents including suggestions, recents, calendar events and many more. - tags: - - Search + type: string + description: The server will send a stream of events in server-sent events (SSE) format. If execution fails after the stream has started, the stream may terminate with an error message in a normal `message` event. + example: | + id: 1 + event: message + data: {"messages":[{"role":"GLEAN_AI","content":[{"text":"Hello","type":"text"}]}]} + + id: 2 + event: message + data: {"messages":[{"role":"GLEAN_AI","content":[{"text":",","type":"text"}]}]} + + id: 3 + event: message + data: {"messages":[{"role":"GLEAN_AI","content":[{"text":" I'm","type":"text"}]}]} + + id: 4 + event: message + data: {"messages":[{"role":"GLEAN_AI","content":[{"text":" your","type":"text"}]}]} + "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: Returned when the agent has tools the caller has not authorized. The response body enumerates the tools that need connecting. + content: + application/json: + schema: + $ref: '#/components/schemas/UnauthorizedAgentToolsError' + "500": + description: Internal server error + deprecated: true + x-visibility: Public + x-glean-deprecated: + docs: https://developers.glean.com/api/platform-api/agents-overview + id: db3f42a5-8820-451e-b57a-14bf6ca3915c + introduced: "2026-08-25" + message: Use POST /api/agents/{agent_id}/runs with stream=true instead. + removal: "2027-04-15" + x-speakeasy-deprecation-message: "Deprecated on 2026-08-25, removal scheduled for 2027-04-15: Use POST /api/agents/{agent_id}/runs with stream=true instead." + x-speakeasy-group: client.agents + x-speakeasy-name-override: runStream + /rest/api/v1/agents/runs/wait: + post: + operationId: createAndWaitRun + summary: Create an agent run and wait for the response + description: 'Executes an [agent](https://developers.glean.com/agents/agents-api) run and returns the final response. **Note**: If the agent uses an input form trigger, all form fields (including optional fields) must be included in the `input` object.' + tags: + - Agents + security: + - APIToken: [] + 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: Returned when the agent has tools the caller has not authorized. The response body enumerates the tools that need connecting. + content: + application/json: + schema: + $ref: '#/components/schemas/UnauthorizedAgentToolsError' + "500": + description: Internal server error + deprecated: true + x-visibility: Public + x-glean-deprecated: + docs: https://developers.glean.com/api/platform-api/agents-overview + id: 683b90e1-48d3-4d7a-a32d-b48eb194fcf0 + introduced: "2026-08-25" + message: Use POST /api/agents/{agent_id}/runs instead. + removal: "2027-04-15" + x-speakeasy-deprecation-message: "Deprecated on 2026-08-25, removal scheduled for 2027-04-15: Use POST /api/agents/{agent_id}/runs instead." + x-speakeasy-group: client.agents + x-speakeasy-name-override: run + /rest/api/v1/addcollectionitems: + post: + operationId: addcollectionitems + summary: Add Collection item + description: Add items to a Collection. + tags: + - Collections security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: Includes request params, client data and more for making user's feed. + description: Data describing the add operation. content: application/json: schema: - $ref: '#/components/schemas/FeedRequest' + $ref: '#/components/schemas/AddCollectionItemsRequest' required: true - x-exportParamName: FeedRequest + x-exportParamName: Request responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/FeedResponse' + $ref: '#/components/schemas/AddCollectionItemsResponse' "400": description: Invalid request "401": description: Not Authorized - "408": - description: Request Timeout "429": description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: retrieveFeed - x-speakeasy-group: client.search - /rest/api/v1/recommendations: + x-speakeasy-name-override: addItems + x-speakeasy-group: client.collections + /rest/api/v1/createcollection: post: - operationId: recommendations - summary: Recommend documents - description: Retrieve recommended documents for the given URL or Glean Document ID. + operationId: createcollection + summary: Create Collection + description: Create a publicly visible (empty) Collection of documents. tags: - - Search + - Collections security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: Recommendations request + description: Collection content plus any additional metadata for the request. content: application/json: schema: - $ref: '#/components/schemas/RecommendationsRequest' + $ref: '#/components/schemas/CreateCollectionRequest' required: true x-exportParamName: Request responses: @@ -4083,90 +4438,78 @@ paths: 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 + $ref: '#/components/schemas/CreateCollectionResponse' "400": description: Invalid request "401": description: Not Authorized - "403": - description: Document does not exist or user cannot access document + "422": + description: Semantic error + content: + application/json: + schema: + $ref: '#/components/schemas/CollectionError' "429": description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-group: client.search - x-speakeasy-name-override: recommendations - /rest/api/v1/search: + x-speakeasy-group: client.collections + x-speakeasy-name-override: create + /rest/api/v1/deletecollection: post: - operationId: search - summary: Search - description: Retrieve results from the index for the given query and filters. + operationId: deletecollection + summary: Delete Collection + description: Delete a Collection given the Collection's ID. tags: - - Search + - Collections security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: Search request + description: DeleteCollection request content: application/json: schema: - $ref: '#/components/schemas/SearchRequest' + $ref: '#/components/schemas/DeleteCollectionRequest' 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 + description: Semantic error content: application/json: schema: - $ref: '#/components/schemas/ErrorInfo' + $ref: '#/components/schemas/CollectionError' "429": description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-group: client.search - x-speakeasy-name-override: query - /rest/api/v1/listentities: + x-speakeasy-name-override: delete + x-speakeasy-group: client.collections + /rest/api/v1/deletecollectionitem: post: - operationId: listentities - 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, except when using FULL_DIRECTORY request type for people entities. + operationId: deletecollectionitem + summary: Delete Collection item + description: Delete a single item from a Collection. tags: - - Entities + - Collections security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: List people request + description: Data describing the delete operation. content: application/json: schema: - $ref: '#/components/schemas/ListEntitiesRequest' + $ref: '#/components/schemas/DeleteCollectionItemRequest' required: true x-exportParamName: Request responses: @@ -4175,34 +4518,36 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/ListEntitiesResponse' + $ref: '#/components/schemas/DeleteCollectionItemResponse' "400": description: Invalid request "401": description: Not Authorized + "422": + description: Failed to save deletion "429": description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-group: client.entities - x-speakeasy-name-override: list - /rest/api/v1/people: + x-speakeasy-name-override: deleteItem + x-speakeasy-group: client.collections + /rest/api/v1/editcollection: post: - operationId: people - summary: Read people - description: Read people details for the given IDs. + operationId: editcollection + summary: Update Collection + description: Update the properties of an existing Collection. tags: - - Entities + - Collections security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: People request + description: Collection content plus any additional metadata for the request. content: application/json: schema: - $ref: '#/components/schemas/PeopleRequest' + $ref: '#/components/schemas/EditCollectionRequest' required: true x-exportParamName: Request responses: @@ -4211,88 +4556,76 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/PeopleResponse' + $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-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: readPeople - x-speakeasy-group: client.entities - /rest/api/v1/people/{person_id}/photo: - get: - operationId: getPersonPhoto - summary: Get person photo - description: | - Returns the profile photo bytes for a person whose photo is stored in Glean (crawled from an identity source or user-uploaded via admin console). Photos hosted externally (e.g. Slack CDN) are not served by this endpoint; callers should follow the photoUrl from /people or /listentities directly. Responses include a Cache-Control header (max-age=3600) to reduce redundant fetches. + x-speakeasy-name-override: update + x-speakeasy-group: client.collections + /rest/api/v1/editcollectionitem: + post: + operationId: editcollectionitem + summary: Update Collection item + description: Update the URL, Glean Document ID, description of an item within a Collection given its ID. tags: - - Entities + - Collections security: - APIToken: [] parameters: - - name: person_id - in: path - description: The obfuscated ID of the person whose photo to retrieve. - required: true - schema: - type: string - - name: ds - in: query - description: | - Optional datasource override for crawled photos (e.g. AZURE, GDRIVE, OKTA). When omitted, the datasource is derived from the person's stored photo URL or the deployment's primary person datasource. - required: false - schema: - type: string + - $ref: '#/components/parameters/locale' + requestBody: + description: Edit Collection Items request + content: + application/json: + schema: + $ref: '#/components/schemas/EditCollectionItemRequest' + required: true + x-exportParamName: Request responses: "200": - description: Photo bytes returned successfully. - headers: - Cache-Control: - description: Caching directive for the photo response. - schema: - type: string - example: public, max-age=3600 + description: OK content: - image/png: - schema: - type: string - format: binary - image/jpeg: + application/json: schema: - type: string - format: binary + $ref: '#/components/schemas/EditCollectionItemResponse' "400": - description: Missing person_id parameter. + description: Invalid request "401": - description: Not Authorized. - "404": - description: | - Person not found, person has no photo, or photo is not hosted by Glean (follow photoUrl from /people or /listentities directly). + description: Not Authorized "429": - description: Too Many Requests. + description: Too Many Requests x-visibility: Public - x-speakeasy-name-override: retrievePersonPhoto - x-speakeasy-group: client.entities - /rest/api/v1/createshortcut: + x-codegen-request-body-name: payload + x-speakeasy-name-override: updateItem + x-speakeasy-group: client.collections + /rest/api/v1/getcollection: post: - operationId: createshortcut - summary: Create shortcut - description: Create a user-generated shortcut that contains an alias and destination URL. + operationId: getcollection + summary: Read Collection + description: Read the details of a Collection given its ID. Does not fetch items in this Collection. tags: - - Shortcuts + - Collections security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: CreateShortcut request + description: GetCollection request content: application/json: schema: - $ref: '#/components/schemas/CreateShortcutRequest' + $ref: '#/components/schemas/GetCollectionRequest' required: true x-exportParamName: Request responses: @@ -4301,7 +4634,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/CreateShortcutResponse' + $ref: '#/components/schemas/GetCollectionResponse' "400": description: Invalid request "401": @@ -4310,30 +4643,34 @@ paths: description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: create - x-speakeasy-group: client.shortcuts - /rest/api/v1/deleteshortcut: + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.collections + /rest/api/v1/listcollections: post: - operationId: deleteshortcut - summary: Delete shortcut - description: Delete an existing user-generated shortcut. + operationId: listcollections + summary: List Collections + description: List all existing Collections. tags: - - Shortcuts + - Collections security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: DeleteShortcut request + description: ListCollections request content: application/json: schema: - $ref: '#/components/schemas/DeleteShortcutRequest' + $ref: '#/components/schemas/ListCollectionsRequest' required: true x-exportParamName: Request responses: "200": description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/ListCollectionsResponse' "400": description: Invalid request "401": @@ -4342,25 +4679,25 @@ paths: description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: delete - x-speakeasy-group: client.shortcuts - /rest/api/v1/getshortcut: + x-speakeasy-name-override: list + x-speakeasy-group: client.collections + /rest/api/v1/getdocpermissions: post: - operationId: getshortcut - summary: Read shortcut - description: Read a particular shortcut's details given its ID. + operationId: getdocpermissions + summary: Read document permissions + description: Read the emails of all users who have access to the given document. tags: - - Shortcuts + - Documents security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: GetShortcut request + description: Document permissions request content: application/json: schema: - $ref: '#/components/schemas/GetShortcutRequest' + $ref: '#/components/schemas/GetDocPermissionsRequest' required: true x-exportParamName: Request responses: @@ -4369,115 +4706,117 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/GetShortcutResponse' + $ref: '#/components/schemas/GetDocPermissionsResponse' "400": description: Invalid request "401": description: Not Authorized + "403": + description: Forbidden "429": description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-group: client.shortcuts - x-speakeasy-name-override: retrieve - /rest/api/v1/listshortcuts: + x-speakeasy-name-override: retrievePermissions + x-speakeasy-group: client.documents + /rest/api/v1/getdocuments: post: - operationId: listshortcuts - summary: List shortcuts - description: List shortcuts editable/owned by the currently authenticated user. + operationId: getdocuments + 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. tags: - - Shortcuts + - Documents security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: Filters, sorters, paging params required for pagination + description: Information about documents requested. content: application/json: schema: - $ref: '#/components/schemas/ListShortcutsPaginatedRequest' - required: true - x-exportParamName: Request + $ref: '#/components/schemas/GetDocumentsRequest' responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/ListShortcutsPaginatedResponse' + $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-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-group: client.shortcuts - x-speakeasy-name-override: list - /rest/api/v1/updateshortcut: + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.documents + /rest/api/v1/getdocumentsbyfacets: post: - operationId: updateshortcut - summary: Update shortcut - description: Updates the shortcut with the given ID. + operationId: getdocumentsbyfacets + summary: Read documents by facets + description: Read the documents including metadata (does not include enhanced metadata via `/documentmetadata`) macthing the given facet conditions. tags: - - Shortcuts + - Documents security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: Shortcut content. Id need to be specified for the shortcut. + description: Information about facet conditions for documents to be retrieved. content: application/json: schema: - $ref: '#/components/schemas/UpdateShortcutRequest' - required: true - x-exportParamName: Request + $ref: '#/components/schemas/GetDocumentsByFacetsRequest' responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/UpdateShortcutResponse' + $ref: '#/components/schemas/GetDocumentsByFacetsResponse' "400": description: Invalid request "401": description: Not Authorized + "404": + description: Not Found "429": description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-group: client.shortcuts - x-speakeasy-name-override: update - /rest/api/v1/summarize: + x-speakeasy-name-override: retrieveByFacets + x-speakeasy-group: client.documents + /rest/api/v1/insights: post: - operationId: summarize - summary: Summarize documents - description: Generate an AI summary of the requested documents. + operationId: insights + summary: Get insights + description: Gets the aggregate usage insights data displayed in the Insights Dashboards. tags: - - Summarize + - Insights security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: Includes request params such as the query and specs of the documents to summarize. + description: Includes request parameters for insights requests. content: application/json: schema: - $ref: '#/components/schemas/SummarizeRequest' + $ref: '#/components/schemas/InsightsRequest' required: true - x-exportParamName: Request + x-exportParamName: InsightsRequest responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/SummarizeResponse' + $ref: '#/components/schemas/InsightsResponse' "400": description: Invalid request "401": @@ -4486,70 +4825,70 @@ paths: description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: summarize - x-speakeasy-group: client.documents - /rest/api/v1/addverificationreminder: + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.insights + /rest/api/v1/messages: post: - operationId: addverificationreminder - summary: Create verification - description: Creates a verification reminder for the document. Users can create verification reminders from different product surfaces. + operationId: messages + summary: Read messages + description: Retrieves list of messages from messaging/chat datasources (e.g. Slack, Teams). tags: - - Verification + - Messages security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: Details about the reminder. + description: Includes request params such as the id for channel/message and direction. content: application/json: schema: - $ref: '#/components/schemas/ReminderRequest' + $ref: '#/components/schemas/MessagesRequest' required: true - x-exportParamName: ReminderRequest + x-exportParamName: MessagesRequest responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/Verification' + $ref: '#/components/schemas/MessagesResponse' "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-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: addReminder - x-speakeasy-group: client.verification - /rest/api/v1/listverifications: + x-speakeasy-name-override: retrieve + x-speakeasy-group: client.messages + /rest/api/v1/editpin: post: - operationId: listverifications - 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: editpin + summary: Update pin + description: Update an existing user-generated pin. tags: - - Verification + - Pins security: - APIToken: [] parameters: - - name: count - in: query - description: Maximum number of documents to return - required: false - schema: - type: integer - $ref: '#/components/parameters/locale' + requestBody: + description: Edit pins request + content: + application/json: + schema: + $ref: '#/components/schemas/EditPinRequest' + required: true + x-exportParamName: Request responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/VerificationFeed' + $ref: '#/components/schemas/PinDocument' "400": description: Invalid request "401": @@ -4558,1097 +4897,1201 @@ paths: description: Too Many Requests x-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: list - x-speakeasy-group: client.verification - /rest/api/v1/verify: + x-speakeasy-name-override: update + x-speakeasy-group: client.pins + /rest/api/v1/getpin: post: - operationId: verify - summary: Update verification - description: Verify documents to keep the knowledge up to date within customer corpus. + operationId: getpin + summary: Read pin + description: Read pin details given its ID. tags: - - Verification + - Pins security: - APIToken: [] parameters: - $ref: '#/components/parameters/locale' requestBody: - description: Details about the verification request. + description: Get pin request content: application/json: schema: - $ref: '#/components/schemas/VerifyRequest' + $ref: '#/components/schemas/GetPinRequest' required: true - x-exportParamName: VerifyRequest + x-exportParamName: Request responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/Verification' + $ref: '#/components/schemas/GetPinResponse' "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-visibility: Public x-codegen-request-body-name: payload - x-speakeasy-name-override: verify - x-speakeasy-group: client.verification - /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-speakeasy-name-override: retrieve + x-speakeasy-group: client.pins + /rest/api/v1/listpins: + post: + operationId: listpins + summary: List pins + description: Lists all pins. tags: - - Tools - - Tools + - Pins security: - APIToken: [] parameters: - - name: toolNames - in: query - description: Optional array of tool names to filter by - required: false - style: form - explode: false - schema: - type: array - items: - type: string + - $ref: '#/components/parameters/locale' + requestBody: + description: List pins request + content: + application/json: + schema: + type: object + required: true + x-exportParamName: Request responses: "200": - description: Successful operation + description: OK content: application/json: schema: - $ref: '#/components/schemas/ToolsListResponse' + $ref: '#/components/schemas/ListPinsResponse' "400": - description: Bad Request + description: Invalid request "401": - description: Unauthorized - "404": - description: Not Found + description: Not Authorized "429": description: Too Many Requests x-visibility: Public + x-codegen-request-body-name: payload x-speakeasy-name-override: list - x-speakeasy-group: client.tools - /rest/api/v1/tools/call: + x-speakeasy-group: client.pins + /rest/api/v1/pin: post: - summary: Execute the specified tool - description: Execute the specified tool with provided parameters + operationId: pin + 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. tags: - - Tools - - Tools + - Pins security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: Details about the document and query for the pin. content: application/json: schema: - $ref: '#/components/schemas/ToolsCallRequest' + $ref: '#/components/schemas/PinRequest' required: true + x-exportParamName: PinDocument responses: "200": - description: Successful operation + description: OK content: application/json: schema: - $ref: '#/components/schemas/ToolsCallResponse' + $ref: '#/components/schemas/PinDocument' "400": - description: Bad Request + description: Invalid request "401": - description: Unauthorized - "404": - description: Not Found + description: Not Authorized "429": description: Too Many Requests x-visibility: Public - x-speakeasy-name-override: run - x-speakeasy-group: client.tools - /rest/api/v1/actions/actionpack/{actionPackId}/auth: - get: - operationId: getActionPackAuthStatus - summary: Get end-user authentication status for an action pack. - description: | - Reports whether the calling user is already authenticated against the third-party - tool backing the specified action pack. Intended for headless / server-driven clients - that render an "Authorize" prompt when the user has not yet consented to the tool. + x-codegen-request-body-name: payload + x-speakeasy-name-override: create + x-speakeasy-group: client.pins + /rest/api/v1/unpin: + post: + operationId: unpin + summary: Delete pin + description: Unpin a previously pinned result. tags: - - Tools + - Pins security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' + requestBody: + description: Details about the pin being unpinned. + content: + application/json: + schema: + $ref: '#/components/schemas/Unpin' + required: true + x-exportParamName: Unpin responses: "200": - description: Successful operation - content: - application/json: - schema: - $ref: '#/components/schemas/ActionPackAuthStatusResponse' + description: OK "400": - description: Bad Request + description: Invalid request "401": - description: Unauthorized - "404": - description: Action pack not found + description: Not Authorized + "403": + description: Forbidden from unpinning someone else's pin "429": description: Too Many Requests x-visibility: Public - x-speakeasy-name-override: retrieveActionPackAuthStatus - x-speakeasy-group: client.tools + x-codegen-request-body-name: payload + x-speakeasy-name-override: remove + x-speakeasy-group: client.pins + /rest/api/v1/adminsearch: post: - operationId: authorizeActionPack - summary: Start the OAuth authorization flow for an action pack. - description: | - Starts the third-party OAuth flow for the specified action pack and returns the - redirect URL that the client should navigate the end user to. After the OAuth - callback completes, the user's browser is redirected back to `returnUrl` with a - status query parameter (`?glean_action_auth=success|error&actionPackId=...`). - - `returnUrl` must match the tenant's configured return URL allowlist; otherwise the - request is rejected with 400. + operationId: adminsearch + summary: Search the index (admin) + description: Retrieves results for search query without respect for permissions. This is available only to privileged users. tags: - - Tools + - Search security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: Admin search request content: application/json: schema: - $ref: '#/components/schemas/AuthorizeActionPackRequest' + $ref: '#/components/schemas/SearchRequest' required: true + x-exportParamName: Request responses: "200": - description: Successful operation + description: OK content: application/json: schema: - $ref: '#/components/schemas/AuthorizeActionPackResponse' + $ref: '#/components/schemas/SearchResponse' "400": - description: Invalid request (e.g. returnUrl not in allowlist, unsupported auth type) + description: Invalid request "401": - description: Unauthorized + description: Not Authorized "403": - description: User not entitled to the action pack - "404": - description: Action pack not found + 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-visibility: Public - x-speakeasy-name-override: authorizeActionPack - x-speakeasy-group: client.tools - parameters: - - name: actionPackId - in: path - description: ID of the action pack to query or authorize. - required: true - schema: - type: string - /rest/api/v1/tool-servers/{serverId}/auth: - get: - operationId: getToolServerAuthStatus - summary: Get end-user authentication status for a tool server. - description: | - Returns display information and the calling user's current authentication status - for the specified tool server. + x-codegen-request-body-name: payload + x-speakeasy-group: client.search + x-speakeasy-name-override: queryAsAdmin + /rest/api/v1/autocomplete: + post: + operationId: autocomplete + summary: Autocomplete + description: Retrieve query suggestions, operators and documents for the given partially typed query. tags: - - Tools + - Search security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' + requestBody: + description: Autocomplete request + content: + application/json: + schema: + $ref: '#/components/schemas/AutocompleteRequest' + required: true + x-exportParamName: Request responses: "200": - description: Successful operation + description: OK content: application/json: schema: - $ref: '#/components/schemas/ToolServerAuthStatusResponse' + $ref: '#/components/schemas/AutocompleteResponse' "400": - description: Bad Request + description: Invalid request "401": - description: Unauthorized - "404": - description: Tool server not found + description: Not Authorized "429": description: Too Many Requests x-visibility: Public - x-glean-experimental: - id: 52fde6ec-c18b-4de6-b761-f82008542ae7 - introduced: "2026-07-02" - x-speakeasy-name-override: retrieveToolServerAuthStatus - x-speakeasy-group: client.tools + x-codegen-request-body-name: payload + x-speakeasy-group: client.search + x-speakeasy-name-override: autocomplete + /rest/api/v1/feed: post: - operationId: authorizeToolServer - summary: Start the OAuth authorization flow for a tool server. - description: | - Initiates the third-party OAuth flow for the specified tool server and returns the - authorization URL that the client should navigate the end user to. After the OAuth - callback completes, the user's browser is redirected back to `returnUrl` with query - parameters indicating the result. - - `returnUrl` must match the tenant's configured return URL allowlist; otherwise the - request is rejected with 400. + operationId: feed + summary: Feed of documents and events + description: The personalized feed/home includes different types of contents including suggestions, recents, calendar events and many more. tags: - - Tools + - Search security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: Includes request params, client data and more for making user's feed. content: application/json: schema: - $ref: '#/components/schemas/AuthorizeToolServerRequest' + $ref: '#/components/schemas/FeedRequest' required: true + x-exportParamName: FeedRequest responses: "200": - description: Successful operation + description: OK content: application/json: schema: - $ref: '#/components/schemas/AuthorizeToolServerResponse' + $ref: '#/components/schemas/FeedResponse' "400": - description: Invalid request (e.g. returnUrl not in allowlist, unsupported auth type) + description: Invalid request "401": - description: Unauthorized - "403": - description: User not entitled to the tool server - "404": - description: Tool server not found - "429": - description: Too Many Requests - x-visibility: Public - x-glean-experimental: - id: 1935476e-ecaf-4c1f-a9fd-1e768cf68f30 - introduced: "2026-07-02" - x-speakeasy-name-override: authorizeToolServer - x-speakeasy-group: client.tools - parameters: - - name: serverId - in: path - description: Unique identifier of the tool server. - required: true - schema: - type: string - /rest/api/v1/tool-servers/{serverId}/tools: - get: - operationId: getToolServerTools - summary: Get tool definitions from a tool server. - description: | - Returns the name, description and JSON input schema for the named tools on the - specified tool server. Works for Glean's built-in tools, tool packs and MCP - servers. - - `toolNames` is required. Names that do not exist on the server are returned in - `notFound` rather than failing the request, so a single bad name does not force - callers into one-at-a-time retries. Matching is case-insensitive and treats `-` - and `_` as equivalent. - - Use `serverId=native` for Glean's built-in tools. - tags: - - Tools - security: - - APIToken: [] - parameters: - - name: toolNames - in: query - description: Tool names to look up on this server. Maximum 100. - required: true - style: form - explode: false - schema: - type: array - items: - type: string - responses: - "200": - description: Successful operation - content: - application/json: - schema: - $ref: '#/components/schemas/ToolDefinitionsResponse' - "400": - description: Invalid request (e.g. missing toolNames, or more than 100 names) - "401": - description: Unauthorized - "404": - description: Tool server not found + description: Not Authorized + "408": + description: Request Timeout "429": description: Too Many Requests - "503": - description: Tool schemas could not be resolved from the server x-visibility: Public - x-glean-experimental: - id: 332eb38f-1b5d-4896-88e3-59db5e96e4e1 - introduced: "2026-07-30" - x-speakeasy-name-override: getToolServerTools - x-speakeasy-group: client.tools - parameters: - - name: serverId - in: path - description: Unique identifier of the tool server. - required: true - schema: - type: string - /api/index/v1/indexdocument: + x-codegen-request-body-name: payload + x-speakeasy-name-override: retrieveFeed + x-speakeasy-group: client.search + /rest/api/v1/recommendations: post: - summary: Index document - description: Adds a document to the index or updates an existing document. + operationId: recommendations + summary: Recommend documents + description: Retrieve recommended documents for the given URL or Glean Document ID. tags: - - Documents + - Search security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: Recommendations request content: application/json: schema: - $ref: '#/components/schemas/IndexDocumentRequest' + $ref: '#/components/schemas/RecommendationsRequest' required: true - x-exportParamName: IndexDocumentRequest + 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: Bad Request + description: Invalid request "401": description: Not Authorized - "409": - description: Conflict + "403": + description: Document does not exist or user cannot access document "429": description: Too Many Requests - x-speakeasy-name-override: addOrUpdate - x-speakeasy-group: indexing.documents - /api/index/v1/indexdocuments: + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-group: client.search + x-speakeasy-name-override: recommendations + /rest/api/v1/search: post: - summary: Index documents - description: Adds or updates multiple documents in the index. Please refer to the [bulk indexing](https://developers.glean.com/indexing/documents/bulk-indexing/choosing-indexdocuments-vs-bulkindexdocuments) documentation for an explanation of when to use this endpoint. + operationId: search + summary: Search + description: Retrieve results from the index for the given query and filters. tags: - - Documents + - Search security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: Search request content: application/json: schema: - $ref: '#/components/schemas/IndexDocumentsRequest' + $ref: '#/components/schemas/SearchRequest' required: true - x-exportParamName: IndexDocumentsRequest + x-exportParamName: Request responses: "200": description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/SearchResponse' "400": - description: Bad Request + description: Invalid request "401": description: Not Authorized - "409": - description: Conflict + "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-name-override: index - x-speakeasy-group: indexing.documents - /api/index/v1/bulkindexdocuments: + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-group: client.search + x-speakeasy-name-override: query + /rest/api/v1/listentities: 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/indexing/documents/bulk-upload-model) documentation for an explanation of how to use bulk endpoints. + operationId: listentities + 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, except when using FULL_DIRECTORY request type for people entities. tags: - - Documents + - Entities security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: List people request content: application/json: schema: - $ref: '#/components/schemas/BulkIndexDocumentsRequest' + $ref: '#/components/schemas/ListEntitiesRequest' required: true - x-exportParamName: BulkIndexDocumentsRequest + x-exportParamName: Request responses: "200": description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/ListEntitiesResponse' "400": - description: Bad Request + description: Invalid request "401": description: Not Authorized - "409": - description: Conflict - x-speakeasy-name-override: bulkIndex - x-speakeasy-group: indexing.documents - /api/index/v1/updatepermissions: + "429": + description: Too Many Requests + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-group: client.entities + x-speakeasy-name-override: list + /rest/api/v1/people: post: - summary: Update document permissions - description: Updates the permissions for a given document without modifying document content. + operationId: people + summary: Read people + description: Read people details for the given IDs. tags: - - Documents + - Entities security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: People request content: application/json: schema: - $ref: '#/components/schemas/UpdatePermissionsRequest' + $ref: '#/components/schemas/PeopleRequest' required: true - x-exportParamName: UpdatePermissionsRequest + x-exportParamName: Request responses: "200": description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/PeopleResponse' "400": - description: Bad Request + description: Invalid request "401": description: Not Authorized - "409": - description: Conflict "429": description: Too Many Requests - x-speakeasy-name-override: updatePermissions - x-speakeasy-group: indexing.permissions - /api/index/v1/processalldocuments: - post: - summary: Schedules the processing of uploaded documents + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-name-override: readPeople + x-speakeasy-group: client.entities + /rest/api/v1/people/{person_id}/photo: + get: + operationId: getPersonPhoto + summary: Get person photo 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. + Returns the profile photo bytes for a person whose photo is stored in Glean (crawled from an identity source or user-uploaded via admin console). Photos hosted externally (e.g. Slack CDN) are not served by this endpoint; callers should follow the photoUrl from /people or /listentities directly. Responses include a Cache-Control header (max-age=3600) to reduce redundant fetches. tags: - - Documents + - Entities security: - APIToken: [] - 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 - /api/index/v1/deletedocument: + parameters: + - name: person_id + in: path + description: The obfuscated ID of the person whose photo to retrieve. + required: true + schema: + type: string + - name: ds + in: query + description: | + Optional datasource override for crawled photos (e.g. AZURE, GDRIVE, OKTA). When omitted, the datasource is derived from the person's stored photo URL or the deployment's primary person datasource. + required: false + schema: + type: string + responses: + "200": + description: Photo bytes returned successfully. + headers: + Cache-Control: + description: Caching directive for the photo response. + schema: + type: string + example: public, max-age=3600 + content: + image/png: + schema: + type: string + format: binary + image/jpeg: + schema: + type: string + format: binary + "400": + description: Missing person_id parameter. + "401": + description: Not Authorized. + "404": + description: | + Person not found, person has no photo, or photo is not hosted by Glean (follow photoUrl from /people or /listentities directly). + "429": + description: Too Many Requests. + x-visibility: Public + x-speakeasy-name-override: retrievePersonPhoto + x-speakeasy-group: client.entities + /rest/api/v1/createshortcut: post: - summary: Delete document - description: Deletes the specified document from the index. Succeeds if document is not present. + operationId: createshortcut + summary: Create shortcut + description: Create a user-generated shortcut that contains an alias and destination URL. tags: - - Documents + - Shortcuts security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: CreateShortcut request content: application/json: schema: - $ref: '#/components/schemas/DeleteDocumentRequest' + $ref: '#/components/schemas/CreateShortcutRequest' required: true - x-exportParamName: DeleteDocumentRequest + x-exportParamName: Request responses: "200": description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/CreateShortcutResponse' "400": - description: Bad Request + description: Invalid request "401": description: Not Authorized - "409": - description: Conflict - x-speakeasy-name-override: delete - x-speakeasy-group: indexing.documents - /api/index/v1/indexuser: + "429": + description: Too Many Requests + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-name-override: create + x-speakeasy-group: client.shortcuts + /rest/api/v1/deleteshortcut: post: - summary: Index user - description: Adds a datasource user or updates an existing user. + operationId: deleteshortcut + summary: Delete shortcut + description: Delete an existing user-generated shortcut. tags: - - Permissions + - Shortcuts security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: DeleteShortcut request content: application/json: schema: - $ref: '#/components/schemas/IndexUserRequest' + $ref: '#/components/schemas/DeleteShortcutRequest' required: true - x-exportParamName: IndexUserRequest + x-exportParamName: Request responses: "200": description: OK "400": - description: Bad Request + description: Invalid request "401": description: Not Authorized - "409": - description: Conflict - x-speakeasy-name-override: indexUser - x-speakeasy-group: indexing.permissions - /api/index/v1/bulkindexusers: + "429": + description: Too Many Requests + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-name-override: delete + x-speakeasy-group: client.shortcuts + /rest/api/v1/getshortcut: 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/indexing/documents/bulk-upload-model) documentation for an explanation of how to use bulk endpoints. - Note: Any users deleted from the existing set will have their associated memberships deleted as well. + operationId: getshortcut + summary: Read shortcut + description: Read a particular shortcut's details given its ID. tags: - - Permissions + - Shortcuts security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: GetShortcut request content: application/json: schema: - $ref: '#/components/schemas/BulkIndexUsersRequest' + $ref: '#/components/schemas/GetShortcutRequest' required: true - x-exportParamName: BulkIndexUsersRequest + x-exportParamName: Request responses: "200": description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/GetShortcutResponse' "400": - description: Bad Request + description: Invalid request "401": description: Not Authorized - "409": - description: Conflict - x-speakeasy-name-override: bulkIndexUsers - x-speakeasy-group: indexing.permissions - /api/index/v1/indexgroup: + "429": + description: Too Many Requests + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-group: client.shortcuts + x-speakeasy-name-override: retrieve + /rest/api/v1/listshortcuts: post: - summary: Index group - description: Add or update a group in the datasource. + operationId: listshortcuts + summary: List shortcuts + description: List shortcuts editable/owned by the currently authenticated user. tags: - - Permissions + - Shortcuts security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: Filters, sorters, paging params required for pagination content: application/json: schema: - $ref: '#/components/schemas/IndexGroupRequest' + $ref: '#/components/schemas/ListShortcutsPaginatedRequest' required: true - x-exportParamName: IndexGroupRequest + x-exportParamName: Request responses: "200": description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/ListShortcutsPaginatedResponse' "400": - description: Bad Request + description: Invalid request "401": description: Not Authorized - "409": - description: Conflict - x-speakeasy-name-override: indexGroup - x-speakeasy-group: indexing.permissions - /api/index/v1/bulkindexgroups: + "429": + description: Too Many Requests + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-group: client.shortcuts + x-speakeasy-name-override: list + /rest/api/v1/updateshortcut: 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/indexing/documents/bulk-upload-model) documentation for an explanation of how to use bulk endpoints. - Note: Any groups deleted from the existing set will have their associated memberships deleted as well. + operationId: updateshortcut + summary: Update shortcut + description: Updates the shortcut with the given ID. tags: - - Permissions + - Shortcuts security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: Shortcut content. Id need to be specified for the shortcut. content: application/json: schema: - $ref: '#/components/schemas/BulkIndexGroupsRequest' + $ref: '#/components/schemas/UpdateShortcutRequest' required: true - x-exportParamName: BulkIndexGroupsRequest + x-exportParamName: Request responses: "200": description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/UpdateShortcutResponse' "400": - description: Bad Request + description: Invalid request "401": description: Not Authorized - "409": - description: Conflict - x-speakeasy-name-override: bulkIndexGroups - x-speakeasy-group: indexing.permissions - /api/index/v1/indexmembership: + "429": + description: Too Many Requests + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-group: client.shortcuts + x-speakeasy-name-override: update + /rest/api/v1/summarize: post: - summary: Index membership - description: Add the memberships of a group in the datasource. + operationId: summarize + summary: Summarize documents + description: Generate an AI summary of the requested documents. tags: - - Permissions + - Summarize security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: Includes request params such as the query and specs of the documents to summarize. content: application/json: schema: - $ref: '#/components/schemas/IndexMembershipRequest' + $ref: '#/components/schemas/SummarizeRequest' required: true - x-exportParamName: IndexMembershipRequest + x-exportParamName: Request responses: "200": description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/SummarizeResponse' "400": - description: Bad Request + description: Invalid request "401": description: Not Authorized - "409": - description: Conflict - x-speakeasy-name-override: indexMembership - x-speakeasy-group: indexing.permissions - /api/index/v1/bulkindexmemberships: + "429": + description: Too Many Requests + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-name-override: summarize + x-speakeasy-group: client.documents + /rest/api/v1/addverificationreminder: 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/indexing/documents/bulk-upload-model) documentation for an explanation of how to use bulk endpoints. + operationId: addverificationreminder + summary: Create verification + description: Creates a verification reminder for the document. Users can create verification reminders from different product surfaces. tags: - - Permissions + - Verification security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: Details about the reminder. content: application/json: schema: - $ref: '#/components/schemas/BulkIndexMembershipsRequest' + $ref: '#/components/schemas/ReminderRequest' required: true - x-exportParamName: BulkIndexMembershipsRequest + x-exportParamName: ReminderRequest responses: "200": description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/Verification' "400": - description: Bad Request + description: Invalid request "401": description: Not Authorized - "409": - description: Conflict - x-speakeasy-name-override: bulkIndexMemberships - x-speakeasy-group: indexing.permissions - /api/index/v1/processallmemberships: + "403": + description: Document does not exist, does not support verification or user cannot access document + "429": + description: Too Many Requests + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-name-override: addReminder + x-speakeasy-group: client.verification + /rest/api/v1/listverifications: 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. + operationId: listverifications + summary: List verifications + description: Returns the information to be rendered in verification dashboard. Includes information for each document owned by user regarding their verifications. tags: - - Permissions + - Verification security: - APIToken: [] - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ProcessAllMembershipsRequest' - x-exportParamName: ProcessAllMembershipsRequest + parameters: + - name: count + in: query + description: Maximum number of documents to return + required: false + schema: + type: integer + - $ref: '#/components/parameters/locale' responses: "200": description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/VerificationFeed' "400": - description: Bad Request + description: Invalid request "401": description: Not Authorized - x-speakeasy-name-override: processMemberships - x-speakeasy-group: indexing.permissions - /api/index/v1/deleteuser: + "429": + description: Too Many Requests + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-name-override: list + x-speakeasy-group: client.verification + /rest/api/v1/verify: post: - summary: Delete user - description: | - Delete the user from the datasource. Silently succeeds if user is not present. - Note: All memberships associated with the deleted user will also be deleted. + operationId: verify + summary: Update verification + description: Verify documents to keep the knowledge up to date within customer corpus. tags: - - Permissions + - Verification security: - APIToken: [] + parameters: + - $ref: '#/components/parameters/locale' requestBody: + description: Details about the verification request. content: application/json: schema: - $ref: '#/components/schemas/DeleteUserRequest' + $ref: '#/components/schemas/VerifyRequest' required: true - x-exportParamName: DeleteUserRequest + x-exportParamName: VerifyRequest responses: "200": description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/Verification' "400": - description: Bad Request + description: Invalid request "401": description: Not Authorized - "409": - description: Conflict - x-speakeasy-name-override: deleteUser - x-speakeasy-group: indexing.permissions - /api/index/v1/deletegroup: - post: - summary: Delete group - description: | - Delete group from the datasource. Silently succeeds if group is not present. - Note: All memberships associated with the deleted group will also be deleted. + "403": + description: Document does not exist, does not support verification or user cannot access document + "429": + description: Too Many Requests + x-visibility: Public + x-codegen-request-body-name: payload + x-speakeasy-name-override: verify + x-speakeasy-group: client.verification + /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. tags: - - Permissions + - Tools + - Tools security: - APIToken: [] - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteGroupRequest' - required: true - x-exportParamName: DeleteGroupRequest + parameters: + - name: toolNames + in: query + description: Optional array of tool names to filter by + required: false + style: form + explode: false + schema: + type: array + items: + type: string responses: "200": - description: OK + description: Successful operation + content: + application/json: + schema: + $ref: '#/components/schemas/ToolsListResponse' "400": description: Bad Request "401": - description: Not Authorized - "409": - description: Conflict - x-speakeasy-name-override: deleteGroup - x-speakeasy-group: indexing.permissions - /api/index/v1/deletemembership: + description: Unauthorized + "404": + description: Not Found + "429": + description: Too Many Requests + x-visibility: Public + x-speakeasy-name-override: list + x-speakeasy-group: client.tools + /rest/api/v1/tools/call: post: - summary: Delete membership - description: Delete membership to a group in the specified datasource. Silently succeeds if membership is not present. + summary: Execute the specified tool + description: Execute the specified tool with provided parameters tags: - - Permissions + - Tools + - Tools security: - APIToken: [] requestBody: content: application/json: schema: - $ref: '#/components/schemas/DeleteMembershipRequest' + $ref: '#/components/schemas/ToolsCallRequest' required: true - x-exportParamName: DeleteMembershipRequest responses: "200": - description: OK + description: Successful operation + content: + application/json: + schema: + $ref: '#/components/schemas/ToolsCallResponse' "400": description: Bad Request "401": - description: Not Authorized - "409": - description: Conflict - x-speakeasy-name-override: deleteMembership - x-speakeasy-group: indexing.permissions - /api/index/v1/debug/{datasource}/status: - post: - summary: | - Beta: Get datasource status + description: Unauthorized + "404": + description: Not Found + "429": + description: Too Many Requests + x-visibility: Public + x-speakeasy-name-override: run + x-speakeasy-group: client.tools + /rest/api/v1/actions/actionpack/{actionPackId}/auth: + get: + operationId: getActionPackAuthStatus + summary: Get end-user authentication status for an action pack. 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/indexing/debugging/datasource-config) for more information. + Reports whether the calling user is already authenticated against the third-party + tool backing the specified action pack. Intended for headless / server-driven clients + that render an "Authorize" prompt when the user has not yet consented to the tool. tags: - - Troubleshooting + - Tools security: - APIToken: [] - parameters: - - name: datasource - in: path - description: The datasource to get debug status for. - required: true - schema: - type: string responses: "200": - description: OK + description: Successful operation content: application/json: schema: - $ref: '#/components/schemas/DebugDatasourceStatusResponse' + $ref: '#/components/schemas/ActionPackAuthStatusResponse' "400": description: Bad Request "401": - description: Not Authorized - x-beta: true - x-speakeasy-name-override: status - x-speakeasy-group: indexing.datasource - /api/index/v1/debug/{datasource}/document: + description: Unauthorized + "404": + description: Action pack not found + "429": + description: Too Many Requests + x-visibility: Public + x-speakeasy-name-override: retrieveActionPackAuthStatus + x-speakeasy-group: client.tools post: - summary: | - Beta: Get document information + operationId: authorizeActionPack + summary: Start the OAuth authorization flow for an action pack. description: | - Gives various information that would help in debugging related to a particular document. Currently in beta, might undergo breaking changes without prior notice. + Starts the third-party OAuth flow for the specified action pack and returns the + redirect URL that the client should navigate the end user to. After the OAuth + callback completes, the user's browser is redirected back to `returnUrl` with a + status query parameter (`?glean_action_auth=success|error&actionPackId=...`). - Tip: Refer to the [Troubleshooting tutorial](https://developers.glean.com/indexing/debugging/datasource-config) for more information. + `returnUrl` must match the tenant's configured return URL allowlist; otherwise the + request is rejected with 400. tags: - - Troubleshooting + - Tools security: - APIToken: [] - parameters: - - name: datasource - in: path - description: The datasource to which the document belongs - required: true - schema: - type: string requestBody: content: application/json: schema: - $ref: '#/components/schemas/DebugDocumentRequest' + $ref: '#/components/schemas/AuthorizeActionPackRequest' required: true - x-exportParamName: DebugDocumentRequest responses: "200": - description: OK + description: Successful operation content: application/json: schema: - $ref: '#/components/schemas/DebugDocumentResponse' + $ref: '#/components/schemas/AuthorizeActionPackResponse' "400": - description: Bad Request + description: Invalid request (e.g. returnUrl not in allowlist, unsupported auth type) "401": - description: Not Authorized - x-beta: true - x-speakeasy-group: indexing.documents - x-speakeasy-name-override: debug - /api/index/v1/debug/{datasource}/documents: - post: - 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/indexing/debugging/datasource-config) for more information. - tags: - - Troubleshooting - security: - - APIToken: [] - parameters: - - name: datasource - in: path - description: The datasource to which the document belongs - required: true - schema: - type: string - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DebugDocumentsRequest' + description: Unauthorized + "403": + description: User not entitled to the action pack + "404": + description: Action pack not found + "429": + description: Too Many Requests + x-visibility: Public + x-speakeasy-name-override: authorizeActionPack + x-speakeasy-group: client.tools + parameters: + - name: actionPackId + in: path + description: ID of the action pack to query or authorize. required: true - x-exportParamName: DebugDocumentsRequest + schema: + type: string + /rest/api/v1/tool-servers/{serverId}/auth: + get: + operationId: getToolServerAuthStatus + summary: Get end-user authentication status for a tool server. + description: | + Returns display information and the calling user's current authentication status + for the specified tool server. + tags: + - Tools + security: + - APIToken: [] responses: "200": - description: OK + description: Successful operation content: application/json: schema: - $ref: '#/components/schemas/DebugDocumentsResponse' + $ref: '#/components/schemas/ToolServerAuthStatusResponse' "400": description: Bad Request "401": - description: Not Authorized - x-beta: true - x-speakeasy-group: indexing.documents - x-speakeasy-name-override: debugMany - /api/index/v1/debug/{datasource}/user: + description: Unauthorized + "404": + description: Tool server not found + "429": + description: Too Many Requests + x-visibility: Public + x-glean-experimental: + id: 52fde6ec-c18b-4de6-b761-f82008542ae7 + introduced: "2026-07-02" + x-speakeasy-name-override: retrieveToolServerAuthStatus + x-speakeasy-group: client.tools post: - summary: | - Beta: Get user information + operationId: authorizeToolServer + summary: Start the OAuth authorization flow for a tool server. description: | - Gives various information that would help in debugging related to a particular user. Currently in beta, might undergo breaking changes without prior notice. + Initiates the third-party OAuth flow for the specified tool server and returns the + authorization URL that the client should navigate the end user to. After the OAuth + callback completes, the user's browser is redirected back to `returnUrl` with query + parameters indicating the result. - Tip: Refer to the [Troubleshooting tutorial](https://developers.glean.com/indexing/debugging/datasource-config) for more information. + `returnUrl` must match the tenant's configured return URL allowlist; otherwise the + request is rejected with 400. tags: - - Troubleshooting + - Tools security: - APIToken: [] - parameters: - - name: datasource - in: path - description: The datasource to which the user belongs - required: true - schema: - type: string requestBody: content: application/json: schema: - $ref: '#/components/schemas/DebugUserRequest' + $ref: '#/components/schemas/AuthorizeToolServerRequest' required: true - x-exportParamName: DebugUserRequest responses: "200": - description: OK + description: Successful operation content: application/json: schema: - $ref: '#/components/schemas/DebugUserResponse' + $ref: '#/components/schemas/AuthorizeToolServerResponse' "400": - description: Bad Request + description: Invalid request (e.g. returnUrl not in allowlist, unsupported auth type) "401": - description: Not Authorized - x-beta: true - x-speakeasy-name-override: debug - x-speakeasy-group: indexing.people - /api/index/v1/checkdocumentaccess: - post: - summary: Check document access + description: Unauthorized + "403": + description: User not entitled to the tool server + "404": + description: Tool server not found + "429": + description: Too Many Requests + x-visibility: Public + x-glean-experimental: + id: 1935476e-ecaf-4c1f-a9fd-1e768cf68f30 + introduced: "2026-07-02" + x-speakeasy-name-override: authorizeToolServer + x-speakeasy-group: client.tools + parameters: + - name: serverId + in: path + description: Unique identifier of the tool server. + required: true + schema: + type: string + /rest/api/v1/tool-servers/{serverId}/tools: + get: + operationId: getToolServerTools + summary: Get tool definitions from a tool server. description: | - Check if a given user has access to access a document in a custom datasource + Returns the name, description and JSON input schema for the named tools on the + specified tool server. Works for Glean's built-in tools, tool packs and MCP + servers. - Tip: Refer to the [Troubleshooting tutorial](https://developers.glean.com/indexing/debugging/datasource-config) for more information. + `toolNames` is required. Names that do not exist on the server are returned in + `notFound` rather than failing the request, so a single bad name does not force + callers into one-at-a-time retries. Matching is case-insensitive and treats `-` + and `_` as equivalent. + + Use `serverId=native` for Glean's built-in tools. tags: - - Troubleshooting + - Tools security: - APIToken: [] - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CheckDocumentAccessRequest' - required: true - x-exportParamName: CheckDocumentAccessRequest + parameters: + - name: toolNames + in: query + description: Tool names to look up on this server. Maximum 100. + required: true + style: form + explode: false + schema: + type: array + items: + type: string responses: "200": - description: OK + description: Successful operation content: application/json: schema: - $ref: '#/components/schemas/CheckDocumentAccessResponse' + $ref: '#/components/schemas/ToolDefinitionsResponse' "400": - description: Bad Request + description: Invalid request (e.g. missing toolNames, or more than 100 names) "401": - description: Not Authorized + description: Unauthorized + "404": + description: Tool server not found "429": description: Too Many Requests - x-speakeasy-group: indexing.documents - x-speakeasy-name-override: checkAccess - /api/index/v1/getdocumentstatus: + "503": + description: Tool schemas could not be resolved from the server + x-visibility: Public + x-glean-experimental: + id: 332eb38f-1b5d-4896-88e3-59db5e96e4e1 + introduced: "2026-07-30" + x-speakeasy-name-override: getToolServerTools + x-speakeasy-group: client.tools + parameters: + - name: serverId + in: path + description: Unique identifier of the tool server. + required: true + schema: + type: string + /api/index/v1/indexdocument: post: - 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/indexing/debugging/datasource-document) for richer information. + summary: Index document + description: Adds a document to the index or updates an existing document. tags: - - Troubleshooting + - Documents security: - APIToken: [] requestBody: content: application/json: schema: - $ref: '#/components/schemas/GetDocumentStatusRequest' + $ref: '#/components/schemas/IndexDocumentRequest' required: true - x-exportParamName: GetDocumentStatusRequest + x-exportParamName: IndexDocumentRequest responses: "200": description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/GetDocumentStatusResponse' "400": description: Bad Request "401": description: Not Authorized + "409": + description: Conflict "429": description: Too Many Requests - deprecated: true - x-glean-deprecated: - id: 7eec0433-78fd-49f9-a34f-cca83640ec24 - introduced: "2026-02-03" - message: Endpoint is deprecated - removal: "2026-10-15" - x-speakeasy-deprecation-message: "Deprecated on 2026-02-03, removal scheduled for 2026-10-15: Endpoint is deprecated" + x-speakeasy-name-override: addOrUpdate x-speakeasy-group: indexing.documents - x-speakeasy-name-override: status - /api/index/v1/getdocumentcount: + /api/index/v1/indexdocuments: post: - summary: Get document count - description: | - Fetches document count for the specified custom datasource. - - Tip: Use [/debug/{datasource}/status](https://developers.glean.com/indexing/debugging/datasource-status) for richer information. + summary: Index documents + description: Adds or updates multiple documents in the index. Please refer to the [bulk indexing](https://developers.glean.com/indexing/documents/bulk-indexing/choosing-indexdocuments-vs-bulkindexdocuments) documentation for an explanation of when to use this endpoint. tags: - - Troubleshooting + - Documents security: - APIToken: [] requestBody: content: application/json: schema: - $ref: '#/components/schemas/GetDocumentCountRequest' + $ref: '#/components/schemas/IndexDocumentsRequest' required: true - x-exportParamName: GetDocumentCountRequest + x-exportParamName: IndexDocumentsRequest responses: "200": description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/GetDocumentCountResponse' "400": description: Bad Request "401": description: Not Authorized "409": description: Conflict - deprecated: true - x-glean-deprecated: - id: c164089c-9412-4724-acf6-caf3b0d2a527 - introduced: "2026-02-03" - message: Endpoint is deprecated - removal: "2026-10-15" - x-speakeasy-deprecation-message: "Deprecated on 2026-02-03, removal scheduled for 2026-10-15: Endpoint is deprecated" + "429": + description: Too Many Requests + x-speakeasy-name-override: index x-speakeasy-group: indexing.documents - x-speakeasy-name-override: count - /api/index/v1/getusercount: + /api/index/v1/bulkindexdocuments: post: - summary: Get user count - description: | - Fetches user count for the specified custom datasource. - - Tip: Use [/debug/{datasource}/status](https://developers.glean.com/indexing/debugging/datasource-status) for richer information. + 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/indexing/documents/bulk-upload-model) documentation for an explanation of how to use bulk endpoints. tags: - - Troubleshooting + - Documents security: - APIToken: [] requestBody: content: application/json: schema: - $ref: '#/components/schemas/GetUserCountRequest' + $ref: '#/components/schemas/BulkIndexDocumentsRequest' required: true - x-exportParamName: GetUserCountRequest + x-exportParamName: BulkIndexDocumentsRequest responses: "200": description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/GetUserCountResponse' "400": description: Bad Request "401": description: Not Authorized "409": description: Conflict - deprecated: true - x-glean-deprecated: - id: 4f5df873-385e-4539-8183-cb764b0f06b9 - introduced: "2026-02-03" - message: Endpoint is deprecated - removal: "2026-10-15" - x-speakeasy-deprecation-message: "Deprecated on 2026-02-03, removal scheduled for 2026-10-15: Endpoint is deprecated" - x-speakeasy-name-override: count - x-speakeasy-group: indexing.people - /api/index/v1/betausers: + x-speakeasy-name-override: bulkIndex + x-speakeasy-group: indexing.documents + /api/index/v1/updatepermissions: 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. + summary: Update document permissions + description: Updates the permissions for a given document without modifying document content. tags: - - Permissions + - Documents security: - APIToken: [] requestBody: content: application/json: schema: - $ref: '#/components/schemas/GreenlistUsersRequest' + $ref: '#/components/schemas/UpdatePermissionsRequest' required: true - x-exportParamName: GreenlistUsersRequest + x-exportParamName: UpdatePermissionsRequest responses: "200": description: OK @@ -5658,23 +6101,35 @@ paths: description: Not Authorized "409": description: Conflict - x-speakeasy-name-override: authorizeBetaUsers + "429": + description: Too Many Requests + x-speakeasy-name-override: updatePermissions x-speakeasy-group: indexing.permissions - /api/index/v1/adddatasource: + /api/index/v1/processalldocuments: post: - summary: Add or update datasource - description: Add or update a custom datasource and its schema. + 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: - - Datasources + - Documents security: - APIToken: [] requestBody: content: application/json: schema: - $ref: '#/components/schemas/CustomDatasourceConfig' - required: true - x-exportParamName: DatasourceConfig + $ref: '#/components/schemas/ProcessAllDocumentsRequest' + x-exportParamName: ProcessAllDocumentsRequest responses: "200": description: OK @@ -5682,74 +6137,79 @@ paths: description: Bad Request "401": description: Not Authorized - x-speakeasy-name-override: add - x-speakeasy-group: indexing.datasources - /api/index/v1/getdatasourceconfig: + "429": + description: Too Many Requests + x-speakeasy-name-override: processAll + x-speakeasy-group: indexing.documents + /api/index/v1/deletedocument: post: - summary: Get datasource config - description: Fetches the datasource config for the specified custom datasource. + summary: Delete document + description: Deletes the specified document from the index. Succeeds if document is not present. tags: - - Datasources + - Documents security: - APIToken: [] requestBody: content: application/json: schema: - $ref: '#/components/schemas/GetDatasourceConfigRequest' + $ref: '#/components/schemas/DeleteDocumentRequest' required: true - x-exportParamName: GetDatasourceConfigRequest + x-exportParamName: DeleteDocumentRequest 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 - /api/index/v1/rotatetoken: + x-speakeasy-name-override: delete + x-speakeasy-group: indexing.documents + /api/index/v1/indexuser: 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/indexing/authentication/token-rotation) documentation for more information. + summary: Index user + description: Adds a datasource user or updates an existing user. tags: - - Authentication + - Permissions security: - APIToken: [] + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/IndexUserRequest' + required: true + x-exportParamName: IndexUserRequest 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 - /api/index/v1/indexemployee: + "409": + description: Conflict + x-speakeasy-name-override: indexUser + x-speakeasy-group: indexing.permissions + /api/index/v1/bulkindexusers: post: - summary: Index employee - description: Adds an employee or replaces the existing information about an employee. + 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/indexing/documents/bulk-upload-model) documentation for an explanation of how to use bulk endpoints. + Note: Any users deleted from the existing set will have their associated memberships deleted as well. tags: - - People + - Permissions security: - APIToken: [] requestBody: content: - application/json; charset=UTF-8: + application/json: schema: - $ref: '#/components/schemas/IndexEmployeeRequest' + $ref: '#/components/schemas/BulkIndexUsersRequest' required: true - x-exportParamName: IndexEmployeeRequest + x-exportParamName: BulkIndexUsersRequest responses: "200": description: OK @@ -5759,23 +6219,23 @@ paths: description: Not Authorized "409": description: Conflict - x-speakeasy-name-override: index - x-speakeasy-group: indexing.people - /api/index/v1/bulkindexemployees: + x-speakeasy-name-override: bulkIndexUsers + x-speakeasy-group: indexing.permissions + /api/index/v1/indexgroup: 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/indexing/documents/bulk-upload-model) documentation for an explanation of how to use bulk endpoints. + summary: Index group + description: Add or update a group in the datasource. tags: - - People + - Permissions security: - APIToken: [] requestBody: content: - application/json; charset=UTF-8: + application/json: schema: - $ref: '#/components/schemas/BulkIndexEmployeesRequest' + $ref: '#/components/schemas/IndexGroupRequest' required: true - x-exportParamName: BulkIndexEmployeesRequest + x-exportParamName: IndexGroupRequest responses: "200": description: OK @@ -5785,25 +6245,25 @@ paths: description: Not Authorized "409": description: Conflict - deprecated: true - x-glean-deprecated: - id: ce596f49-55c4-465e-bf3c-5a3a33906e1f - introduced: "2026-02-03" - message: Endpoint is deprecated - removal: "2027-01-15" - x-speakeasy-deprecation-message: "Deprecated on 2026-02-03, removal scheduled for 2027-01-15: Endpoint is deprecated" - x-speakeasy-name-override: bulkIndex - x-speakeasy-group: indexing.people - /api/index/v1/indexemployeelist: {} - /api/index/v1/processallemployeesandteams: + x-speakeasy-name-override: indexGroup + x-speakeasy-group: indexing.permissions + /api/index/v1/bulkindexgroups: post: - summary: Schedules the processing of uploaded employees and teams + summary: Bulk index groups 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. + Replaces the groups in a datasource using paginated batch API calls. Please refer to the [bulk indexing](https://developers.glean.com/indexing/documents/bulk-upload-model) documentation for an explanation of how to use bulk endpoints. + Note: Any groups deleted from the existing set will have their associated memberships deleted as well. tags: - - People + - Permissions security: - APIToken: [] + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/BulkIndexGroupsRequest' + required: true + x-exportParamName: BulkIndexGroupsRequest responses: "200": description: OK @@ -5811,25 +6271,25 @@ paths: description: Bad Request "401": description: Not Authorized - "429": - description: Too Many Requests - x-speakeasy-name-override: processAllEmployeesAndTeams - x-speakeasy-group: indexing.people - /api/index/v1/deleteemployee: + "409": + description: Conflict + x-speakeasy-name-override: bulkIndexGroups + x-speakeasy-group: indexing.permissions + /api/index/v1/indexmembership: post: - summary: Delete employee - description: Delete an employee. Silently succeeds if employee is not present. + summary: Index membership + description: Add the memberships of a group in the datasource. tags: - - People + - Permissions security: - APIToken: [] requestBody: content: - application/json; charset=UTF-8: + application/json: schema: - $ref: '#/components/schemas/DeleteEmployeeRequest' + $ref: '#/components/schemas/IndexMembershipRequest' required: true - x-exportParamName: DeleteEmployeeRequest + x-exportParamName: IndexMembershipRequest responses: "200": description: OK @@ -5839,23 +6299,23 @@ paths: description: Not Authorized "409": description: Conflict - x-speakeasy-name-override: delete - x-speakeasy-group: indexing.people - /api/index/v1/indexteam: + x-speakeasy-name-override: indexMembership + x-speakeasy-group: indexing.permissions + /api/index/v1/bulkindexmemberships: post: - summary: Index team - description: Adds a team or updates information about a team + 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/indexing/documents/bulk-upload-model) documentation for an explanation of how to use bulk endpoints. tags: - - People + - Permissions security: - APIToken: [] requestBody: content: - application/json; charset=UTF-8: + application/json: schema: - $ref: '#/components/schemas/IndexTeamRequest' + $ref: '#/components/schemas/BulkIndexMembershipsRequest' required: true - x-exportParamName: IndexTeamRequest + x-exportParamName: BulkIndexMembershipsRequest responses: "200": description: OK @@ -5865,23 +6325,23 @@ paths: description: Not Authorized "409": description: Conflict - x-speakeasy-name-override: indexTeam - x-speakeasy-group: indexing.people - /api/index/v1/deleteteam: + x-speakeasy-name-override: bulkIndexMemberships + x-speakeasy-group: indexing.permissions + /api/index/v1/processallmemberships: post: - summary: Delete team - description: Delete a team based on provided id. + 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: - - People + - Permissions security: - APIToken: [] requestBody: content: - application/json; charset=UTF-8: + application/json: schema: - $ref: '#/components/schemas/DeleteTeamRequest' - required: true - x-exportParamName: DeleteTeamRequest + $ref: '#/components/schemas/ProcessAllMembershipsRequest' + x-exportParamName: ProcessAllMembershipsRequest responses: "200": description: OK @@ -5889,25 +6349,25 @@ paths: description: Bad Request "401": description: Not Authorized - "409": - description: Conflict - x-speakeasy-name-override: deleteTeam - x-speakeasy-group: indexing.people - /api/index/v1/bulkindexteams: + x-speakeasy-name-override: processMemberships + x-speakeasy-group: indexing.permissions + /api/index/v1/deleteuser: 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/indexing/documents/bulk-upload-model) documentation for an explanation of how to use bulk endpoints. + summary: Delete user + description: | + Delete the user from the datasource. Silently succeeds if user is not present. + Note: All memberships associated with the deleted user will also be deleted. tags: - - People + - Permissions security: - APIToken: [] requestBody: content: - application/json; charset=UTF-8: + application/json: schema: - $ref: '#/components/schemas/BulkIndexTeamsRequest' + $ref: '#/components/schemas/DeleteUserRequest' required: true - x-exportParamName: BulkIndexTeamsRequest + x-exportParamName: DeleteUserRequest responses: "200": description: OK @@ -5917,23 +6377,25 @@ paths: description: Not Authorized "409": description: Conflict - x-speakeasy-name-override: bulkIndexTeams - x-speakeasy-group: indexing.people - /api/index/v1/bulkindexshortcuts: + x-speakeasy-name-override: deleteUser + x-speakeasy-group: indexing.permissions + /api/index/v1/deletegroup: 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://docs.glean.com/user-guide/knowledge/go-links/how-go-links-work) page. - tags: - - Shortcuts + summary: Delete group + description: | + Delete group from the datasource. Silently succeeds if group is not present. + Note: All memberships associated with the deleted group will also be deleted. + tags: + - Permissions security: - APIToken: [] requestBody: content: - application/json; charset=UTF-8: + application/json: schema: - $ref: '#/components/schemas/BulkIndexShortcutsRequest' + $ref: '#/components/schemas/DeleteGroupRequest' required: true - x-exportParamName: BulkIndexShortcutsRequest + x-exportParamName: DeleteGroupRequest responses: "200": description: OK @@ -5943,23 +6405,23 @@ paths: description: Not Authorized "409": description: Conflict - x-speakeasy-name-override: bulkIndex - x-speakeasy-group: indexing.shortcuts - /api/index/v1/uploadshortcuts: + x-speakeasy-name-override: deleteGroup + x-speakeasy-group: indexing.permissions + /api/index/v1/deletemembership: 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. + summary: Delete membership + description: Delete membership to a group in the specified datasource. Silently succeeds if membership is not present. tags: - - Shortcuts + - Permissions security: - APIToken: [] requestBody: content: - application/json; charset=UTF-8: + application/json: schema: - $ref: '#/components/schemas/UploadShortcutsRequest' + $ref: '#/components/schemas/DeleteMembershipRequest' required: true - x-exportParamName: UploadShortcutsRequest + x-exportParamName: DeleteMembershipRequest responses: "200": description: OK @@ -5969,14 +6431,49 @@ paths: description: Not Authorized "409": description: Conflict - x-speakeasy-name-override: upload - x-speakeasy-group: indexing.shortcuts - /api/index/v1/debug/{datasource}/document/events: + x-speakeasy-name-override: deleteMembership + x-speakeasy-group: indexing.permissions + /api/index/v1/debug/{datasource}/status: post: summary: | - Beta: Get document lifecycle events + Beta: Get datasource status description: | - Retrieves lifecycle events for a specific document including upload time, index times and deletions. Rate limited to 1 request per minute per datasource. Currently in beta, might undergo breaking changes without prior notice. + 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/indexing/debugging/datasource-config) for more information. + tags: + - Troubleshooting + security: + - APIToken: [] + 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: + schema: + $ref: '#/components/schemas/DebugDatasourceStatusResponse' + "400": + description: Bad Request + "401": + description: Not Authorized + x-beta: true + x-speakeasy-name-override: status + x-speakeasy-group: indexing.datasource + /api/index/v1/debug/{datasource}/document: + post: + 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/indexing/debugging/datasource-config) for more information. tags: - Troubleshooting security: @@ -5992,2950 +6489,4822 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/DebugDocumentLifecycleRequest' + $ref: '#/components/schemas/DebugDocumentRequest' required: true - x-exportParamName: DebugDocumentLifecycleRequest + x-exportParamName: DebugDocumentRequest responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/DebugDocumentLifecycleResponse' + $ref: '#/components/schemas/DebugDocumentResponse' "400": description: Bad Request "401": description: Not Authorized - "429": - description: Too Many Requests x-beta: true x-speakeasy-group: indexing.documents - x-speakeasy-name-override: debugEvents - /rest/api/index/submissions/{datasourceInstance}/{type}: + x-speakeasy-name-override: debug + /api/index/v1/debug/{datasource}/documents: post: - summary: Submit datasource data - description: Validates and asynchronously processes a datasource-specific submission. + 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/indexing/debugging/datasource-config) for more information. tags: - - Datasources + - Troubleshooting security: - APIToken: [] + parameters: + - name: datasource + in: path + description: The datasource to which the document belongs + required: true + schema: + type: string requestBody: content: application/json: schema: - type: object - additionalProperties: true + $ref: '#/components/schemas/DebugDocumentsRequest' required: true - x-exportParamName: SubmissionRequest + x-exportParamName: DebugDocumentsRequest responses: - "202": - description: Accepted + "200": + description: OK content: application/json: schema: - type: object - properties: - requestId: - type: string - required: - - requestId + $ref: '#/components/schemas/DebugDocumentsResponse' "400": - $ref: '#/components/responses/BadRequestError' + description: Bad Request "401": - $ref: '#/components/responses/UnauthorizedError' - "404": - $ref: '#/components/responses/NotFoundError' - "405": - description: Method Not Allowed - "413": - description: Payload Too Large - "500": - $ref: '#/components/responses/InternalServerError' - "503": - description: Service Unavailable - x-speakeasy-name-override: submit - x-speakeasy-group: indexing.datasources - 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. - parameters: - - name: datasourceInstance - in: path - description: Datasource instance that should process the submission - required: true - schema: - type: string - - name: type - in: path - description: Submission type registered for the datasource - required: true - schema: - type: string - /rest/api/index/document/{docId}/custom-metadata/{groupName}: - put: - summary: Add or update custom metadata - description: Associates custom metadata with a specific document. Custom metadata enables you to enrich documents with additional structured information that can be used for search, filtering, and faceting. + description: Not Authorized + x-beta: true + x-speakeasy-group: indexing.documents + x-speakeasy-name-override: debugMany + /api/index/v1/debug/{datasource}/user: + post: + 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/indexing/debugging/datasource-config) for more information. tags: - - Custom Metadata + - Troubleshooting security: - APIToken: [] + parameters: + - name: datasource + in: path + description: The datasource to which the user belongs + required: true + schema: + type: string requestBody: content: application/json: schema: - $ref: '#/components/schemas/CustomMetadataPutRequest' + $ref: '#/components/schemas/DebugUserRequest' required: true - x-exportParamName: CustomMetadataPutRequest + x-exportParamName: DebugUserRequest responses: "200": - $ref: '#/components/responses/SuccessResponse' + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/DebugUserResponse' "400": - $ref: '#/components/responses/BadRequestError' + description: Bad Request "401": - $ref: '#/components/responses/UnauthorizedError' - "404": - $ref: '#/components/responses/NotFoundError' - "429": - $ref: '#/components/responses/TooManyRequestsError' - "500": - $ref: '#/components/responses/InternalServerError' - x-speakeasy-name-override: upsert - x-speakeasy-group: indexing.customMetadata - delete: - summary: Remove custom metadata - description: Removes all custom metadata for the specified metadata group from a document. + description: Not Authorized + x-beta: true + x-speakeasy-name-override: debug + x-speakeasy-group: indexing.people + /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/indexing/debugging/datasource-config) for more information. tags: - - Custom Metadata + - Troubleshooting security: - APIToken: [] + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CheckDocumentAccessRequest' + required: true + x-exportParamName: CheckDocumentAccessRequest responses: "200": - $ref: '#/components/responses/SuccessResponse' + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/CheckDocumentAccessResponse' "400": - $ref: '#/components/responses/BadRequestError' + description: Bad Request "401": - $ref: '#/components/responses/UnauthorizedError' - "404": - $ref: '#/components/responses/NotFoundError' + description: Not Authorized "429": - $ref: '#/components/responses/TooManyRequestsError' - "500": - $ref: '#/components/responses/InternalServerError' - x-speakeasy-name-override: delete - x-speakeasy-group: indexing.customMetadata - 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. - parameters: - - name: docId - in: path - description: Unique Glean identifier of the document - required: true - schema: - type: string - - name: groupName - in: path - description: Name of the metadata group as specified while adding schema - required: true - schema: - type: string - /rest/api/index/custom-metadata/schema/{groupName}: - get: - summary: Retrieve metadata schema - description: Retrieves the current schema definition for a metadata group. + description: Too Many Requests + x-speakeasy-group: indexing.documents + x-speakeasy-name-override: checkAccess + /api/index/v1/getdocumentstatus: + post: + 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/indexing/debugging/datasource-document) for richer information. tags: - - Custom Metadata + - Troubleshooting security: - APIToken: [] + 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/CustomMetadataSchema' + $ref: '#/components/schemas/GetDocumentStatusResponse' + "400": + description: Bad Request "401": - $ref: '#/components/responses/UnauthorizedError' - "404": - $ref: '#/components/responses/NotFoundError' + description: Not Authorized "429": - $ref: '#/components/responses/TooManyRequestsError' - "500": - $ref: '#/components/responses/InternalServerError' - x-speakeasy-name-override: getSchema - x-speakeasy-group: indexing.customMetadata - put: - summary: Create or update metadata schema - description: Defines or updates the schema for a metadata group. Schemas should be defined before indexing metadata. + description: Too Many Requests + deprecated: true + x-glean-deprecated: + id: 7eec0433-78fd-49f9-a34f-cca83640ec24 + introduced: "2026-02-03" + message: Endpoint is deprecated + removal: "2026-10-15" + x-speakeasy-deprecation-message: "Deprecated on 2026-02-03, removal scheduled for 2026-10-15: Endpoint is deprecated" + x-speakeasy-group: indexing.documents + x-speakeasy-name-override: status + /api/index/v1/getdocumentcount: + post: + summary: Get document count + description: | + Fetches document count for the specified custom datasource. + + Tip: Use [/debug/{datasource}/status](https://developers.glean.com/indexing/debugging/datasource-status) for richer information. tags: - - Custom Metadata + - Troubleshooting security: - APIToken: [] requestBody: content: application/json: schema: - $ref: '#/components/schemas/CustomMetadataSchema' + $ref: '#/components/schemas/GetDocumentCountRequest' required: true - x-exportParamName: CustomMetadataSchema + x-exportParamName: GetDocumentCountRequest responses: "200": - $ref: '#/components/responses/SuccessResponse' + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/GetDocumentCountResponse' "400": - $ref: '#/components/responses/BadRequestError' + description: Bad Request "401": - $ref: '#/components/responses/UnauthorizedError' + description: Not Authorized "409": - description: Conflict - Schema already exists with incompatible changes + description: Conflict + deprecated: true + x-glean-deprecated: + id: c164089c-9412-4724-acf6-caf3b0d2a527 + introduced: "2026-02-03" + message: Endpoint is deprecated + removal: "2026-10-15" + x-speakeasy-deprecation-message: "Deprecated on 2026-02-03, removal scheduled for 2026-10-15: Endpoint is deprecated" + x-speakeasy-group: indexing.documents + x-speakeasy-name-override: count + /api/index/v1/getusercount: + post: + summary: Get user count + description: | + Fetches user count for the specified custom datasource. + + Tip: Use [/debug/{datasource}/status](https://developers.glean.com/indexing/debugging/datasource-status) for richer information. + tags: + - Troubleshooting + security: + - APIToken: [] + 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/ErrorInfoResponse' - "429": - $ref: '#/components/responses/TooManyRequestsError' - "500": - $ref: '#/components/responses/InternalServerError' - x-speakeasy-name-override: upsertSchema - x-speakeasy-group: indexing.customMetadata - delete: - summary: Remove metadata schema - description: Deletes the schema definition for a metadata group. This does not delete existing metadata values on documents. + $ref: '#/components/schemas/GetUserCountResponse' + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + deprecated: true + x-glean-deprecated: + id: 4f5df873-385e-4539-8183-cb764b0f06b9 + introduced: "2026-02-03" + message: Endpoint is deprecated + removal: "2026-10-15" + x-speakeasy-deprecation-message: "Deprecated on 2026-02-03, removal scheduled for 2026-10-15: Endpoint is deprecated" + 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: - - Custom Metadata + - Permissions security: - APIToken: [] + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GreenlistUsersRequest' + required: true + x-exportParamName: GreenlistUsersRequest responses: "200": - $ref: '#/components/responses/SuccessResponse' + description: OK "400": - $ref: '#/components/responses/BadRequestError' + description: Bad Request "401": - $ref: '#/components/responses/UnauthorizedError' - "404": - $ref: '#/components/responses/NotFoundError' - "429": - $ref: '#/components/responses/TooManyRequestsError' - "500": - $ref: '#/components/responses/InternalServerError' - x-speakeasy-name-override: deleteSchema - x-speakeasy-group: indexing.customMetadata - 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. - parameters: - - name: groupName - in: path - description: Name of the metadata group schema - required: true - schema: - type: string - /rest/api/v1/governance/data/policies/{id}: - get: - operationId: getpolicy - summary: Gets specified policy - description: Fetches the specified policy version, or the latest if no version is provided. + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: authorizeBetaUsers + x-speakeasy-group: indexing.permissions + /api/index/v1/adddatasource: + post: + summary: Add or update datasource + description: Add or update a custom datasource and its schema. tags: - - Governance + - Datasources security: - APIToken: [] - 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 + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CustomDatasourceConfig' + required: true + x-exportParamName: DatasourceConfig responses: "200": description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/GetDlpReportResponse' - "403": - description: Permissions error - "500": - description: Internal error - x-visibility: Public - x-speakeasy-group: client.governance.data.policies - x-speakeasy-name-override: retrieve + "400": + description: Bad Request + "401": + description: Not Authorized + x-speakeasy-name-override: add + x-speakeasy-group: indexing.datasources + /api/index/v1/getdatasourceconfig: post: - operationId: updatepolicy - summary: Updates an existing policy - description: Updates an existing policy. + summary: Get datasource config + description: Fetches the datasource config for the specified custom datasource. tags: - - Governance + - Datasources security: - APIToken: [] - 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: + application/json: schema: - $ref: '#/components/schemas/UpdateDlpReportRequest' + $ref: '#/components/schemas/GetDatasourceConfigRequest' required: true + x-exportParamName: GetDatasourceConfigRequest responses: "200": description: OK content: - application/json; charset=UTF-8: + application/json: schema: - $ref: '#/components/schemas/UpdateDlpReportResponse' - "403": - description: Permissions error - "500": - description: Internal error - x-visibility: Public - x-speakeasy-group: client.governance.data.policies - x-speakeasy-name-override: update - /rest/api/v1/governance/data/policies: - get: - operationId: listpolicies - summary: Lists policies - description: Lists policies with filtering. + $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 + /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/indexing/authentication/token-rotation) documentation for more information. tags: - - Governance + - Authentication security: - APIToken: [] - 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-visibility: Public - x-speakeasy-group: client.governance.data.policies - x-speakeasy-name-override: list + $ref: '#/components/schemas/RotateTokenResponse' + "400": + description: Bad Request + "401": + description: Not Authorized + x-speakeasy-name-override: rotateToken + x-speakeasy-group: indexing.authentication + /api/index/v1/indexemployee: post: - operationId: createpolicy - summary: Creates new policy - description: Creates a new policy with specified specifications and returns its id. + summary: Index employee + description: Adds an employee or replaces the existing information about an employee. tags: - - Governance + - People security: - APIToken: [] requestBody: content: application/json; charset=UTF-8: schema: - $ref: '#/components/schemas/CreateDlpReportRequest' + $ref: '#/components/schemas/IndexEmployeeRequest' required: true + x-exportParamName: IndexEmployeeRequest responses: "200": description: OK - content: - application/json; charset=UTF-8: - schema: - $ref: '#/components/schemas/CreateDlpReportResponse' - "403": - description: Permissions error - "500": - description: Internal error - x-visibility: Public - x-speakeasy-group: client.governance.data.policies - x-speakeasy-name-override: create - /rest/api/v1/governance/data/policies/{id}/download: - get: - operationId: downloadpolicycsv - summary: Downloads violations CSV for policy - description: Downloads CSV violations report for a specific policy id. This does not support continuous policies. - tags: - - Governance - security: - - APIToken: [] - 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: - type: string - description: CSV of all the violations found for this policy. "400": - description: Bad request error (e.g., continuous policies are not supported). - "403": - description: Permissions error - "500": - description: Internal error - x-visibility: Public - x-speakeasy-group: client.governance.data.policies - x-speakeasy-name-override: download - /rest/api/v1/governance/data/reports: + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: index + x-speakeasy-group: indexing.people + /api/index/v1/bulkindexemployees: post: - operationId: createreport - summary: Creates new one-time report - description: Creates a new one-time report and executes its batch job. + 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/indexing/documents/bulk-upload-model) documentation for an explanation of how to use bulk endpoints. tags: - - Governance + - People security: - APIToken: [] requestBody: content: application/json; charset=UTF-8: schema: - $ref: '#/components/schemas/UpdateDlpConfigRequest' + $ref: '#/components/schemas/BulkIndexEmployeesRequest' required: true + x-exportParamName: BulkIndexEmployeesRequest responses: "200": description: OK - content: - application/json; charset=UTF-8: - schema: - $ref: '#/components/schemas/UpdateDlpConfigResponse' - "403": - description: Permissions error - "500": - description: Internal error - x-visibility: Public - x-speakeasy-group: client.governance.data.reports - x-speakeasy-name-override: create - /rest/api/v1/governance/data/reports/{id}/download: - get: - operationId: downloadreportcsv - summary: Downloads violations CSV for report - description: Downloads CSV violations report for a specific report id. + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + deprecated: true + x-glean-deprecated: + id: ce596f49-55c4-465e-bf3c-5a3a33906e1f + introduced: "2026-02-03" + message: Endpoint is deprecated + removal: "2027-01-15" + x-speakeasy-deprecation-message: "Deprecated on 2026-02-03, removal scheduled for 2027-01-15: Endpoint is deprecated" + x-speakeasy-name-override: bulkIndex + x-speakeasy-group: indexing.people + /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: - - Governance + - People security: - APIToken: [] - 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: - type: string - description: CSV of all the violations found for this report. - "403": - description: Permissions error - "500": - description: Internal error - x-visibility: Public - x-speakeasy-group: client.governance.data.reports - x-speakeasy-name-override: download - /rest/api/v1/governance/data/reports/{id}/status: - get: - operationId: getreportstatus - summary: Fetches report run status - description: Fetches the status of the run corresponding to the report-id. + 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 + /api/index/v1/deleteemployee: + post: + summary: Delete employee + description: Delete an employee. Silently succeeds if employee is not present. tags: - - Governance + - People security: - APIToken: [] - parameters: - - name: id - in: path - description: The id of the report to get run status for. - required: true - schema: - type: string + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: '#/components/schemas/DeleteEmployeeRequest' + required: true + x-exportParamName: DeleteEmployeeRequest 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-visibility: Public - x-speakeasy-group: client.governance.data.reports - x-speakeasy-name-override: status - /rest/api/v1/governance/documents/visibilityoverrides: - get: - operationId: getdocvisibility - summary: Fetches documents visibility - description: Fetches the visibility override status of the documents passed. + description: OK + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: delete + x-speakeasy-group: indexing.people + /api/index/v1/indexteam: + post: + summary: Index team + description: Adds a team or updates information about a team tags: - - Governance - security: - - APIToken: [] - 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-visibility: Public - x-speakeasy-group: client.governance.documents.visibilityoverrides - x-speakeasy-name-override: list - post: - operationId: setdocvisibility - summary: Hide or unhide docs - description: Sets the visibility-override state of the documents specified, effectively hiding or un-hiding documents. - tags: - - Governance + - People security: - APIToken: [] requestBody: content: application/json; charset=UTF-8: schema: - $ref: '#/components/schemas/UpdateDocumentVisibilityOverridesRequest' + $ref: '#/components/schemas/IndexTeamRequest' required: true + x-exportParamName: IndexTeamRequest responses: "200": description: OK - content: - application/json; charset=UTF-8: - schema: - $ref: '#/components/schemas/UpdateDocumentVisibilityOverridesResponse' - "403": - description: Permissions error - "500": - description: Internal error - x-visibility: Public - x-speakeasy-group: client.governance.documents.visibilityoverrides - x-speakeasy-name-override: create - /rest/api/v1/governance/data/findings/exports: + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: indexTeam + x-speakeasy-group: indexing.people + /api/index/v1/deleteteam: post: - operationId: createfindingsexport - summary: Creates findings export - description: Creates a new DLP findings export job. + summary: Delete team + description: Delete a team based on provided id. tags: - - Governance + - People security: - APIToken: [] requestBody: content: application/json; charset=UTF-8: schema: - $ref: '#/components/schemas/DlpExportFindingsRequest' + $ref: '#/components/schemas/DeleteTeamRequest' required: true + x-exportParamName: DeleteTeamRequest responses: "200": description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/ExportInfo' - "403": - description: Permissions error - "500": - description: Internal error - x-visibility: Public - x-speakeasy-group: client.governance.data.findings - x-speakeasy-name-override: create - get: - operationId: listfindingsexports - summary: Lists findings exports - description: Lists all DLP findings exports. + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: deleteTeam + x-speakeasy-group: indexing.people + /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/indexing/documents/bulk-upload-model) documentation for an explanation of how to use bulk endpoints. tags: - - Governance + - People security: - APIToken: [] + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: '#/components/schemas/BulkIndexTeamsRequest' + required: true + x-exportParamName: BulkIndexTeamsRequest responses: "200": description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/ListDlpFindingsExportsResponse' - "403": - description: Permissions error - "500": - description: Internal error - x-visibility: Public - x-speakeasy-group: client.governance.data.findings - x-speakeasy-name-override: list - /rest/api/v1/governance/data/findings/exports/{id}: - get: - operationId: downloadfindingsexport - summary: Downloads findings export - description: Downloads a DLP findings export as a CSV file. - tags: - - Governance - security: - - APIToken: [] - parameters: - - name: id - in: path - description: The ID of the export to download. - required: true - schema: - type: string - responses: - "200": - description: Downloads CSV of exported findings. - content: - text/csv; charset=UTF-8: - schema: - type: string - description: CSV of all the exported findings. - "403": - description: Permissions error - "500": - description: Internal error - x-visibility: Public - x-speakeasy-group: client.governance.data.findings - x-speakeasy-name-override: download - delete: - operationId: deletefindingsexport - summary: Deletes findings export - description: Deletes a DLP findings export. + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: bulkIndexTeams + x-speakeasy-group: indexing.people + /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://docs.glean.com/user-guide/knowledge/go-links/how-go-links-work) page. tags: - - Governance + - Shortcuts security: - APIToken: [] - parameters: - - name: id - in: path - description: The ID of the export to delete. - required: true - schema: - type: integer - format: int64 + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: '#/components/schemas/BulkIndexShortcutsRequest' + required: true + x-exportParamName: BulkIndexShortcutsRequest responses: "200": description: OK - "403": - description: Permissions error - "500": - description: Internal error - x-visibility: Public - x-speakeasy-group: client.governance.data.findings - x-speakeasy-name-override: delete - /rest/api/v1/configure/datasources/{datasourceId}/instances/{instanceId}: - get: - operationId: getDatasourceInstanceConfiguration - summary: Get datasource instance configuration - description: | - Gets the greenlisted configuration values for a datasource instance. Returns only configuration keys that are exposed via the public API greenlist. + "400": + description: Bad Request + "401": + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: bulkIndex + x-speakeasy-group: indexing.shortcuts + /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: - - Datasources + - Shortcuts security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/datasourceId' - - $ref: '#/components/parameters/instanceId' + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: '#/components/schemas/UploadShortcutsRequest' + required: true + x-exportParamName: UploadShortcutsRequest responses: "200": description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/DatasourceConfigurationResponse' "400": - description: Invalid request - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' + description: Bad Request "401": - description: Not authorized - "403": - description: Forbidden - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - "404": - description: Datasource instance not found - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - x-visibility: Public - x-speakeasy-group: client.datasources - x-speakeasy-name-override: retrieveConfiguration - patch: - operationId: updateDatasourceInstanceConfiguration - summary: Update datasource instance configuration + description: Not Authorized + "409": + description: Conflict + x-speakeasy-name-override: upload + x-speakeasy-group: indexing.shortcuts + /api/index/v1/debug/{datasource}/document/events: + post: + summary: | + Beta: Get document lifecycle events description: | - Updates the greenlisted configuration values for a datasource instance. Only configuration keys that are exposed via the public API greenlist may be set. Returns the full greenlisted configuration after the update is applied. + Retrieves lifecycle events for a specific document including upload time, index times and deletions. Rate limited to 1 request per minute per datasource. Currently in beta, might undergo breaking changes without prior notice. tags: - - Datasources + - Troubleshooting security: - APIToken: [] parameters: - - $ref: '#/components/parameters/datasourceId' - - $ref: '#/components/parameters/instanceId' + - name: datasource + in: path + description: The datasource to which the document belongs + required: true + schema: + type: string requestBody: content: application/json: schema: - $ref: '#/components/schemas/UpdateDatasourceConfigurationRequest' + $ref: '#/components/schemas/DebugDocumentLifecycleRequest' required: true + x-exportParamName: DebugDocumentLifecycleRequest responses: "200": description: OK content: application/json: schema: - $ref: '#/components/schemas/DatasourceConfigurationResponse' + $ref: '#/components/schemas/DebugDocumentLifecycleResponse' "400": - description: Invalid request - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' + description: Bad Request "401": - description: Not authorized - "403": - description: Forbidden - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - "404": - description: Datasource instance not found - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - x-visibility: Public - x-speakeasy-group: client.datasources - x-speakeasy-name-override: updateConfiguration - /rest/api/v1/datasource/{datasourceInstanceId}/credentialstatus: - get: - operationId: getDatasourceCredentialStatus - summary: Get datasource instance credential status - description: | - Returns the current credential status for a datasource instance. Access is limited to callers with the ADMIN scope; the handler enforces this check. + description: Not Authorized + "429": + description: Too Many Requests + x-beta: true + x-speakeasy-group: indexing.documents + x-speakeasy-name-override: debugEvents + /rest/api/index/submissions/{datasourceInstance}/{type}: + post: + summary: Submit datasource data + description: Validates and asynchronously processes a datasource-specific submission. tags: - Datasources security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/datasourceInstanceId' + requestBody: + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + x-exportParamName: SubmissionRequest responses: - "200": - description: OK + "202": + description: Accepted content: application/json: schema: - $ref: '#/components/schemas/DatasourceCredentialStatusResponse' + type: object + properties: + requestId: + type: string + required: + - requestId "400": - description: Invalid request - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' + $ref: '#/components/responses/BadRequestError' "401": - description: Not authorized - "403": - description: Forbidden - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' + $ref: '#/components/responses/UnauthorizedError' "404": - description: Datasource instance not found - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - x-visibility: Public - x-speakeasy-group: client.datasources - x-speakeasy-name-override: retrieveCredentialStatus - /rest/api/v1/datasource/{datasourceInstanceId}/credentials: - post: - operationId: rotateDatasourceCredentials - summary: Rotate datasource instance credentials - description: | - Rotates the credentials that a datasource instance uses to connect to its upstream system. Replaces the active credential material with the supplied values and returns the credential status after rotation. Access is limited to callers with the ADMIN scope; the handler enforces this check. - Only keys recognized as credential material for the datasource type may be set in `credentials.values` (e.g. `clientSecret`, `apiToken`, `privateKey`, depending on the configured auth method). Unrecognized keys, or keys that correspond to non-credential configuration, cause a 400; other instance configuration must be updated via PATCH /configure/datasources/{datasourceId}/instances/{instanceId}. + $ref: '#/components/responses/NotFoundError' + "405": + description: Method Not Allowed + "413": + description: Payload Too Large + "500": + $ref: '#/components/responses/InternalServerError' + "503": + description: Service Unavailable + x-speakeasy-name-override: submit + x-speakeasy-group: indexing.datasources + 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. + parameters: + - name: datasourceInstance + in: path + description: Datasource instance that should process the submission + required: true + schema: + type: string + - name: type + in: path + description: Submission type registered for the datasource + required: true + schema: + type: string + /rest/api/index/document/{docId}/custom-metadata/{groupName}: + put: + summary: Add or update custom metadata + description: Associates custom metadata with a specific document. Custom metadata enables you to enrich documents with additional structured information that can be used for search, filtering, and faceting. tags: - - Datasources + - Custom Metadata security: - APIToken: [] - parameters: - - $ref: '#/components/parameters/datasourceInstanceId' requestBody: content: application/json: schema: - $ref: '#/components/schemas/RotateDatasourceCredentialsRequest' + $ref: '#/components/schemas/CustomMetadataPutRequest' required: true + x-exportParamName: CustomMetadataPutRequest responses: "200": - description: OK - content: - application/json: - schema: - $ref: '#/components/schemas/DatasourceCredentialStatusResponse' + $ref: '#/components/responses/SuccessResponse' "400": - description: Invalid request - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' + $ref: '#/components/responses/BadRequestError' "401": - description: Not authorized - "403": - description: Forbidden - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' + $ref: '#/components/responses/UnauthorizedError' "404": - description: Datasource instance not found + $ref: '#/components/responses/NotFoundError' + "429": + $ref: '#/components/responses/TooManyRequestsError' + "500": + $ref: '#/components/responses/InternalServerError' + x-speakeasy-name-override: upsert + x-speakeasy-group: indexing.customMetadata + delete: + summary: Remove custom metadata + description: Removes all custom metadata for the specified metadata group from a document. + tags: + - Custom Metadata + security: + - APIToken: [] + responses: + "200": + $ref: '#/components/responses/SuccessResponse' + "400": + $ref: '#/components/responses/BadRequestError' + "401": + $ref: '#/components/responses/UnauthorizedError' + "404": + $ref: '#/components/responses/NotFoundError' + "429": + $ref: '#/components/responses/TooManyRequestsError' + "500": + $ref: '#/components/responses/InternalServerError' + x-speakeasy-name-override: delete + x-speakeasy-group: indexing.customMetadata + 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. + parameters: + - name: docId + in: path + description: Unique Glean identifier of the document + required: true + schema: + type: string + - name: groupName + in: path + description: Name of the metadata group as specified while adding schema + required: true + schema: + type: string + /rest/api/index/custom-metadata/schema/{groupName}: + get: + summary: Retrieve metadata schema + description: Retrieves the current schema definition for a metadata group. + tags: + - Custom Metadata + security: + - APIToken: [] + responses: + "200": + description: OK content: application/json: schema: - $ref: '#/components/schemas/ErrorResponse' - x-visibility: Public - x-speakeasy-group: client.datasources - x-speakeasy-name-override: rotateCredentials - /rest/api/v1/chat#stream: - post: + $ref: '#/components/schemas/CustomMetadataSchema' + "401": + $ref: '#/components/responses/UnauthorizedError' + "404": + $ref: '#/components/responses/NotFoundError' + "429": + $ref: '#/components/responses/TooManyRequestsError' + "500": + $ref: '#/components/responses/InternalServerError' + x-speakeasy-name-override: getSchema + x-speakeasy-group: indexing.customMetadata + put: + summary: Create or update metadata schema + description: Defines or updates the schema for a metadata group. Schemas should be defined before indexing metadata. tags: - - Chat - summary: Chat - description: Have a conversation with Glean AI. - operationId: chatStream + - Custom Metadata security: - APIToken: [] - 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. + $ref: '#/components/schemas/CustomMetadataSchema' required: true - x-exportParamName: Request + x-exportParamName: CustomMetadataSchema responses: - '200': + "200": + $ref: '#/components/responses/SuccessResponse' + "400": + $ref: '#/components/responses/BadRequestError' + "401": + $ref: '#/components/responses/UnauthorizedError' + "409": + description: Conflict - Schema already exists with incompatible changes + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorInfoResponse' + "429": + $ref: '#/components/responses/TooManyRequestsError' + "500": + $ref: '#/components/responses/InternalServerError' + x-speakeasy-name-override: upsertSchema + x-speakeasy-group: indexing.customMetadata + delete: + summary: Remove metadata schema + description: Deletes the schema definition for a metadata group. This does not delete existing metadata values on documents. + tags: + - Custom Metadata + security: + - APIToken: [] + responses: + "200": + $ref: '#/components/responses/SuccessResponse' + "400": + $ref: '#/components/responses/BadRequestError' + "401": + $ref: '#/components/responses/UnauthorizedError' + "404": + $ref: '#/components/responses/NotFoundError' + "429": + $ref: '#/components/responses/TooManyRequestsError' + "500": + $ref: '#/components/responses/InternalServerError' + x-speakeasy-name-override: deleteSchema + x-speakeasy-group: indexing.customMetadata + 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. + parameters: + - name: groupName + in: path + description: Name of the metadata group schema + required: true + schema: + type: string + /rest/api/v1/governance/data/policies/{id}: + get: + operationId: getpolicy + summary: Gets specified policy + description: Fetches the specified policy version, or the latest if no version is provided. + tags: + - Governance + security: + - APIToken: [] + 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: - text/plain: + application/json: 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 -components: - securitySchemes: - APIToken: - type: http - scheme: bearer - description: >- - HTTP bearer token. Accepts a Glean-issued API token, an OAuth access token from the Glean OAuth Authorization Server (including Dynamic Client Registration clients), or an OAuth access token issued by an external identity provider. External-IdP OAuth tokens must also include the `X-Glean-Auth-Type: OAUTH` request header. OAuth is supported on the Client API only; the Indexing API requires a Glean-issued token. - schemas: - PlatformWarning: + $ref: '#/components/schemas/GetDlpReportResponse' + "403": + description: Permissions error + "500": + description: Internal error + x-visibility: Public + x-speakeasy-group: client.governance.data.policies + x-speakeasy-name-override: retrieve + post: + operationId: updatepolicy + summary: Updates an existing policy + description: Updates an existing policy. + tags: + - Governance + security: + - APIToken: [] + 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-visibility: Public + x-speakeasy-group: client.governance.data.policies + x-speakeasy-name-override: update + /rest/api/v1/governance/data/policies: + get: + operationId: listpolicies + summary: Lists policies + description: Lists policies with filtering. + tags: + - Governance + security: + - APIToken: [] + 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-visibility: Public + x-speakeasy-group: client.governance.data.policies + x-speakeasy-name-override: list + post: + operationId: createpolicy + summary: Creates new policy + description: Creates a new policy with specified specifications and returns its id. + tags: + - Governance + security: + - APIToken: [] + 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-visibility: Public + x-speakeasy-group: client.governance.data.policies + x-speakeasy-name-override: create + /rest/api/v1/governance/data/policies/{id}/download: + get: + operationId: downloadpolicycsv + summary: Downloads violations CSV for policy + description: Downloads CSV violations report for a specific policy id. This does not support continuous policies. + tags: + - Governance + security: + - APIToken: [] + 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: + type: string + description: CSV of all the violations found for this policy. + "400": + description: Bad request error (e.g., continuous policies are not supported). + "403": + description: Permissions error + "500": + description: Internal error + x-visibility: Public + x-speakeasy-group: client.governance.data.policies + x-speakeasy-name-override: download + /rest/api/v1/governance/data/reports: + post: + operationId: createreport + summary: Creates new one-time report + description: Creates a new one-time report and executes its batch job. + tags: + - Governance + security: + - APIToken: [] + 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-visibility: Public + x-speakeasy-group: client.governance.data.reports + x-speakeasy-name-override: create + /rest/api/v1/governance/data/reports/{id}/download: + get: + operationId: downloadreportcsv + summary: Downloads violations CSV for report + description: Downloads CSV violations report for a specific report id. + tags: + - Governance + security: + - APIToken: [] + 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: + type: string + description: CSV of all the violations found for this report. + "403": + description: Permissions error + "500": + description: Internal error + x-visibility: Public + x-speakeasy-group: client.governance.data.reports + x-speakeasy-name-override: download + /rest/api/v1/governance/data/reports/{id}/status: + get: + operationId: getreportstatus + summary: Fetches report run status + description: Fetches the status of the run corresponding to the report-id. + tags: + - Governance + security: + - APIToken: [] + 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-visibility: Public + x-speakeasy-group: client.governance.data.reports + x-speakeasy-name-override: status + /rest/api/v1/governance/documents/visibilityoverrides: + get: + operationId: getdocvisibility + summary: Fetches documents visibility + description: Fetches the visibility override status of the documents passed. + tags: + - Governance + security: + - APIToken: [] + 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-visibility: Public + x-speakeasy-group: client.governance.documents.visibilityoverrides + x-speakeasy-name-override: list + post: + operationId: setdocvisibility + summary: Hide or unhide docs + description: Sets the visibility-override state of the documents specified, effectively hiding or un-hiding documents. + tags: + - Governance + security: + - APIToken: [] + 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-visibility: Public + x-speakeasy-group: client.governance.documents.visibilityoverrides + x-speakeasy-name-override: create + /rest/api/v1/governance/data/findings/exports: + post: + operationId: createfindingsexport + summary: Creates findings export + description: Creates a new DLP findings export job. + tags: + - Governance + security: + - APIToken: [] + requestBody: + content: + application/json; charset=UTF-8: + schema: + $ref: '#/components/schemas/DlpExportFindingsRequest' + required: true + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/ExportInfo' + "403": + description: Permissions error + "500": + description: Internal error + x-visibility: Public + x-speakeasy-group: client.governance.data.findings + x-speakeasy-name-override: create + get: + operationId: listfindingsexports + summary: Lists findings exports + description: Lists all DLP findings exports. + tags: + - Governance + security: + - APIToken: [] + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/ListDlpFindingsExportsResponse' + "403": + description: Permissions error + "500": + description: Internal error + x-visibility: Public + x-speakeasy-group: client.governance.data.findings + x-speakeasy-name-override: list + /rest/api/v1/governance/data/findings/exports/{id}: + get: + operationId: downloadfindingsexport + summary: Downloads findings export + description: Downloads a DLP findings export as a CSV file. + tags: + - Governance + security: + - APIToken: [] + parameters: + - name: id + in: path + description: The ID of the export to download. + required: true + schema: + type: string + responses: + "200": + description: Downloads CSV of exported findings. + content: + text/csv; charset=UTF-8: + schema: + type: string + description: CSV of all the exported findings. + "403": + description: Permissions error + "500": + description: Internal error + x-visibility: Public + x-speakeasy-group: client.governance.data.findings + x-speakeasy-name-override: download + delete: + operationId: deletefindingsexport + summary: Deletes findings export + description: Deletes a DLP findings export. + tags: + - Governance + security: + - APIToken: [] + parameters: + - name: id + in: path + description: The ID of the export to delete. + required: true + schema: + type: integer + format: int64 + responses: + "200": + description: OK + "403": + description: Permissions error + "500": + description: Internal error + x-visibility: Public + x-speakeasy-group: client.governance.data.findings + x-speakeasy-name-override: delete + /rest/api/v1/configure/datasources/{datasourceId}/instances/{instanceId}: + get: + operationId: getDatasourceInstanceConfiguration + summary: Get datasource instance configuration + description: | + Gets the greenlisted configuration values for a datasource instance. Returns only configuration keys that are exposed via the public API greenlist. + tags: + - Datasources + security: + - APIToken: [] + parameters: + - $ref: '#/components/parameters/datasourceId' + - $ref: '#/components/parameters/instanceId' + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/DatasourceConfigurationResponse' + "400": + description: Invalid request + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + "401": + description: Not authorized + "403": + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + "404": + description: Datasource instance not found + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + x-visibility: Public + x-speakeasy-group: client.datasources + x-speakeasy-name-override: retrieveConfiguration + patch: + operationId: updateDatasourceInstanceConfiguration + summary: Update datasource instance configuration + description: | + Updates the greenlisted configuration values for a datasource instance. Only configuration keys that are exposed via the public API greenlist may be set. Returns the full greenlisted configuration after the update is applied. + tags: + - Datasources + security: + - APIToken: [] + parameters: + - $ref: '#/components/parameters/datasourceId' + - $ref: '#/components/parameters/instanceId' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UpdateDatasourceConfigurationRequest' + required: true + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/DatasourceConfigurationResponse' + "400": + description: Invalid request + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + "401": + description: Not authorized + "403": + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + "404": + description: Datasource instance not found + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + x-visibility: Public + x-speakeasy-group: client.datasources + x-speakeasy-name-override: updateConfiguration + /rest/api/v1/datasource/{datasourceInstanceId}/credentialstatus: + get: + operationId: getDatasourceCredentialStatus + summary: Get datasource instance credential status + description: | + Returns the current credential status for a datasource instance. Access is limited to callers with the ADMIN scope; the handler enforces this check. + tags: + - Datasources + security: + - APIToken: [] + parameters: + - $ref: '#/components/parameters/datasourceInstanceId' + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/DatasourceCredentialStatusResponse' + "400": + description: Invalid request + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + "401": + description: Not authorized + "403": + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + "404": + description: Datasource instance not found + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + x-visibility: Public + x-speakeasy-group: client.datasources + x-speakeasy-name-override: retrieveCredentialStatus + /rest/api/v1/datasource/{datasourceInstanceId}/credentials: + post: + operationId: rotateDatasourceCredentials + summary: Rotate datasource instance credentials + description: | + Rotates the credentials that a datasource instance uses to connect to its upstream system. Replaces the active credential material with the supplied values and returns the credential status after rotation. Access is limited to callers with the ADMIN scope; the handler enforces this check. + Only keys recognized as credential material for the datasource type may be set in `credentials.values` (e.g. `clientSecret`, `apiToken`, `privateKey`, depending on the configured auth method). Unrecognized keys, or keys that correspond to non-credential configuration, cause a 400; other instance configuration must be updated via PATCH /configure/datasources/{datasourceId}/instances/{instanceId}. + tags: + - Datasources + security: + - APIToken: [] + parameters: + - $ref: '#/components/parameters/datasourceInstanceId' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RotateDatasourceCredentialsRequest' + required: true + responses: + "200": + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/DatasourceCredentialStatusResponse' + "400": + description: Invalid request + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + "401": + description: Not authorized + "403": + description: Forbidden + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + "404": + description: Datasource instance not found + content: + application/json: + schema: + $ref: '#/components/schemas/ErrorResponse' + x-visibility: Public + x-speakeasy-group: client.datasources + x-speakeasy-name-override: rotateCredentials + /rest/api/v1/chat#stream: + post: + tags: + - Chat + summary: Chat + description: Have a conversation with Glean AI. + operationId: chatStream + security: + - APIToken: [] + 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 +components: + securitySchemes: + APIToken: + type: http + scheme: bearer + description: >- + HTTP bearer token. Accepts a Glean-issued API token, an OAuth access token from the Glean OAuth Authorization Server (including Dynamic Client Registration clients), or an OAuth access token issued by an external identity provider. External-IdP OAuth tokens must also include the `X-Glean-Auth-Type: OAUTH` request header. OAuth is supported on the Client API only; the Indexing API requires a Glean-issued token. + schemas: + PlatformWarning: + type: object + additionalProperties: false + required: + - code + - message + description: Non-blocking warning attached to a successful Platform response. + properties: + code: + type: string + minLength: 1 + description: | + Open snake_case warning code. Clients must tolerate unknown values; the set of codes is not a closed enum. + example: results_incomplete + message: + type: string + minLength: 1 + description: Human-readable warning message. + PlatformAgentsSearchRequest: + type: object + additionalProperties: false + example: + name: HR Policy Agent + properties: + name: + type: string + description: Case-insensitive substring to match against agent names. If omitted or empty, no name filter is applied. + example: HR Policy Agent + PlatformAgentCapabilities: + type: object + additionalProperties: true + properties: + ap.io.messages: + type: boolean + description: Whether the agent supports messages as input. + ap.io.streaming: + type: boolean + description: Whether the agent supports streaming output. + PlatformAgent: + type: object + required: + - agent_id + - name + - capabilities + properties: + agent_id: + type: string + description: ID of the agent. + example: mho4lwzylcozgoc2 + name: + type: string + description: Name of the agent. + example: HR Policy Agent + description: + type: string + description: Description of the agent. + metadata: + type: object + description: Agent metadata. + additionalProperties: true + capabilities: + $ref: "#/components/schemas/PlatformAgentCapabilities" + PlatformAgentsSearchResponse: + type: object + required: + - agents + - request_id + properties: + agents: + type: array + description: Agents matching the search request. + items: + $ref: "#/components/schemas/PlatformAgent" + request_id: + type: string + description: Platform-generated request ID for support correlation. + PlatformProblemDetailCode: + type: string + description: Stable machine-readable error code. + enum: + - invalid_request + - missing_required_field + - invalid_parameter + - invalid_cursor + - expired_cursor + - invalid_filter + - invalid_datasource + - authentication_required + - token_expired + - insufficient_permissions + - spend_limit_exceeded + - resource_not_found + - method_not_allowed + - request_timeout + - request_too_large + - token_limit_exceeded + - conflict + - gone + - unprocessable_query + - tools_unauthorized + - rate_limit_exceeded + - internal_error + - service_unavailable + x-glean-problem-detail-codes: + invalid_request: + status: 400 + title: Invalid Request + missing_required_field: + status: 400 + title: Missing Required Field + invalid_parameter: + status: 400 + title: Invalid Parameter + invalid_cursor: + status: 400 + title: Invalid Pagination Cursor + expired_cursor: + status: 400 + title: Expired Pagination Cursor + invalid_filter: + status: 400 + title: Invalid Filter + invalid_datasource: + status: 400 + title: Invalid Datasource + authentication_required: + status: 401 + title: Authentication Required + token_expired: + status: 401 + title: Token Expired + insufficient_permissions: + status: 403 + title: Insufficient Permissions + spend_limit_exceeded: + status: 403 + title: Spend Limit Exceeded + resource_not_found: + status: 404 + title: Resource Not Found + method_not_allowed: + status: 405 + title: Method Not Allowed + request_timeout: + status: 408 + title: Request Timeout + request_too_large: + status: 413 + title: Request Too Large + token_limit_exceeded: + status: 413 + title: Token Limit Exceeded + conflict: + status: 409 + title: Conflict + gone: + status: 410 + title: Gone + unprocessable_query: + status: 422 + title: Unprocessable Query + tools_unauthorized: + status: 422 + title: Tools Unauthorized + rate_limit_exceeded: + status: 429 + title: Rate Limit Exceeded + internal_error: + status: 500 + title: Internal Error + service_unavailable: + status: 503 + title: Service Unavailable + example: invalid_cursor + PlatformProblemDetailError: + type: object + required: + - pointer + - detail + description: Field-level validation problem for a single offending field. + properties: + pointer: + type: string + description: RFC 6901 JSON Pointer to the offending field. + example: /messages/0/role + detail: + type: string + description: Human-readable explanation for this field. + example: "Must be one of: USER, GLEAN_AI." + code: + $ref: "#/components/schemas/PlatformProblemDetailCode" + PlatformProblemDetail: + type: object + required: + - type + - title + - status + - detail + - code + - request_id + description: | + Error response following RFC 9457, extended with `code` and `documentation_url` for machine-readable classification and self-service remediation. + properties: + type: + type: string + format: uri + description: URI identifying the error type. + example: https://developers.glean.com/errors/invalid-cursor + title: + type: string + description: Short, human-readable summary of the error. + example: Invalid Pagination Cursor + status: + type: integer + description: HTTP status code mirrored from the response. + example: 400 + detail: + type: string + description: Human-readable explanation specific to this occurrence. + example: | + The provided cursor has expired. Start a new search to get a fresh cursor. + code: + $ref: "#/components/schemas/PlatformProblemDetailCode" + documentation_url: + type: string + format: uri + description: Direct URL to documentation for this error code. + example: https://developers.glean.com/errors/invalid-cursor + request_id: + type: string + description: Platform-generated request ID for support correlation. + example: req_7f8a9b0c1d2e + errors: + type: array + description: Field-level validation problems, one entry per offending field. + items: + $ref: "#/components/schemas/PlatformProblemDetailError" + PlatformAgentGetResponse: + type: object + required: + - agent + - request_id + properties: + agent: + $ref: "#/components/schemas/PlatformAgent" + request_id: + type: string + description: Platform-generated request ID for support correlation. + PlatformActionSummary: + type: object + required: + - tool_id + - display_name + properties: + tool_id: + type: string + description: Unique identifier of the action. + display_name: + type: string + description: Display name of the action. + type: + type: string + description: Tool type. + auth_type: + type: string + description: Authentication type required by the action. + write_action_type: + type: string + description: Write-action execution type. + is_setup_finished: + type: boolean + description: Whether this action has been fully configured. + data_source: + type: string + description: Kind of knowledge the action accesses or modifies. + PlatformAgentSchemasResponse: + type: object + required: + - agent_id + - input_schema + - output_schema + - request_id + properties: + agent_id: + type: string + description: ID of the agent. + name: + type: string + description: Name of the agent. + input_schema: + type: object + description: Agent input schema in JSON Schema format. + additionalProperties: true + output_schema: + type: object + description: Agent output schema in JSON Schema format. + additionalProperties: true + tools: + type: array + description: Tools that the agent can invoke, when requested. + items: + $ref: "#/components/schemas/PlatformActionSummary" + request_id: + type: string + description: Platform-generated request ID for support correlation. + PlatformMessageRole: + type: string + description: Role of the message author. + example: USER + enum: + - USER + - GLEAN_AI + PlatformContentType: + type: string + enum: + - text + PlatformChatDocumentSource: + type: object + additionalProperties: false + required: + - type + properties: + type: + type: string + x-discriminator: true + enum: + - DOCUMENT + document_id: + type: string + minLength: 1 + url: + type: string + minLength: 1 + title: + type: string + datasource: + type: string + anyOf: + - required: + - document_id + properties: + document_id: + type: string + minLength: 1 + - required: + - url + properties: + url: + type: string + minLength: 1 + PlatformChatPersonSource: + type: object + additionalProperties: false + required: + - type + - person_id + properties: + type: + type: string + x-discriminator: true + enum: + - PERSON + person_id: + type: string + minLength: 1 + name: + type: string + url: + type: string + PlatformChatFileSource: + type: object + additionalProperties: false + required: + - type + - file_id + properties: + type: + type: string + x-discriminator: true + enum: + - FILE + file_id: + type: string + minLength: 1 + title: + type: string + url: + type: string + datasource: + type: string + PlatformChatCustomEntitySource: type: object additionalProperties: false required: - - code - - message - description: Non-blocking warning attached to a successful Platform response. + - type + - entity_id properties: - code: + type: + type: string + x-discriminator: true + enum: + - CUSTOM_ENTITY + entity_id: type: string minLength: 1 - description: | - Open snake_case warning code. Clients must tolerate unknown values; the set of codes is not a closed enum. - example: results_incomplete - message: + name: + type: string + title: + type: string + url: + type: string + datasource: + type: string + PlatformChatCitationSource: + description: Four-variant citation source union. + x-multiple-discriminators: true + oneOf: + - $ref: "#/components/schemas/PlatformChatDocumentSource" + - $ref: "#/components/schemas/PlatformChatPersonSource" + - $ref: "#/components/schemas/PlatformChatFileSource" + - $ref: "#/components/schemas/PlatformChatCustomEntitySource" + discriminator: + propertyName: type + mapping: + DOCUMENT: "#/components/schemas/PlatformChatDocumentSource" + PERSON: "#/components/schemas/PlatformChatPersonSource" + FILE: "#/components/schemas/PlatformChatFileSource" + CUSTOM_ENTITY: "#/components/schemas/PlatformChatCustomEntitySource" + PlatformChatCitationSnippet: + type: object + additionalProperties: false + required: + - text + properties: + text: type: string minLength: 1 - description: Human-readable warning message. - PlatformAgentsSearchRequest: + page_number: + type: + - integer + - "null" + PlatformChatCitationAnnotation: + type: object + additionalProperties: false + required: + - type + - sources + properties: + type: + type: string + enum: + - CITATION + sources: + type: array + minItems: 1 + items: + $ref: "#/components/schemas/PlatformChatCitationSource" + start_index: + type: + - integer + - "null" + minimum: 0 + end_index: + type: + - integer + - "null" + minimum: 0 + snippets: + type: + - array + - "null" + items: + $ref: "#/components/schemas/PlatformChatCitationSnippet" + PlatformMessageTextBlock: + type: object + required: + - text + - type + properties: + text: + type: string + description: Text content. + type: + $ref: "#/components/schemas/PlatformContentType" + annotations: + type: array + readOnly: true + items: + $ref: "#/components/schemas/PlatformChatCitationAnnotation" + PlatformMessage: + type: object + required: + - role + - content + properties: + role: + $ref: "#/components/schemas/PlatformMessageRole" + content: + type: array + minItems: 1 + description: Content blocks in the message. + items: + $ref: "#/components/schemas/PlatformMessageTextBlock" + PlatformAgentRunCreateRequest: type: object additionalProperties: false + description: | + Request to run an agent. A request MUST supply either `messages` (a non-empty conversation) or `input` (for input-form triggered agents). example: - name: HR Policy Agent + messages: + - role: USER + content: + - text: What is our parental leave policy? + type: text properties: - name: + input: + type: object + description: Input fields for an input-form triggered agent. + additionalProperties: true + messages: + type: array + minItems: 1 + description: | + Messages to pass to the agent. When provided, the array MUST contain at least one message and each message MUST specify a valid `role` and non-empty `content`. + items: + $ref: "#/components/schemas/PlatformMessage" + metadata: + type: object + description: Metadata to pass to the agent. + additionalProperties: true + stream: + type: boolean + description: Whether to stream the run response as server-sent events. Not supported in DURABLE mode. + default: false + execution_mode: + type: string + enum: + - REQUEST_BOUND + - DURABLE + default: REQUEST_BOUND + description: | + REQUEST_BOUND preserves the existing wait/stream behavior. DURABLE starts a fresh, persisted execution with a 30-minute execution timeout and returns immediately. DURABLE requires stream to be false or omitted and does not accept metadata.chat_session_id. It does not bypass tool approval requirements or provide automatic QE-crash resumption. Expiry is read-triggered: the next GET of the run marks an active turn FAILED if more than 40 minutes have passed since the turn was accepted. There is no periodic sweep, so the stored run can remain RUNNING until it is read. Expiry never replays execution or expires approval-paused runs, and failure does not prove that external tool work has stopped. + PlatformAgentRunCreate: + type: object + required: + - agent_id + properties: + agent_id: + type: string + description: ID of the agent being run. + input: + type: object + description: Input fields for an input-form triggered agent. + additionalProperties: true + messages: + type: array + description: Messages passed to the agent. + items: + $ref: "#/components/schemas/PlatformMessage" + metadata: + type: object + description: Metadata passed to the agent. + additionalProperties: true + PlatformAgentExecutionStatus: + type: string + description: Status of the agent run. + enum: + - error + - success + PlatformAgentRun: + allOf: + - $ref: "#/components/schemas/PlatformAgentRunCreate" + - type: object + required: + - status + properties: + status: + $ref: "#/components/schemas/PlatformAgentExecutionStatus" + PlatformAgentRunWaitResponse: + type: object + required: + - request_id + properties: + run: + $ref: "#/components/schemas/PlatformAgentRun" + messages: + type: array + description: Messages returned by the completed run. + items: + $ref: "#/components/schemas/PlatformMessage" + request_id: + type: string + description: Platform-generated request ID for support correlation. + PlatformAgentRunState: + type: string + enum: + - QUEUED + - RUNNING + - REQUIRES_INPUT + - SUCCEEDED + - FAILED + - CANCELLING + - CANCELLED + - EXPIRED + description: State of the persisted workflow execution. REQUIRES_INPUT is nonterminal. + PlatformAgentRunToolApproval: + type: object + description: Pending approval for a specific persisted tool invocation and its arguments. + required: + - interaction_id + - type + - display_name + - description + - arguments + properties: + interaction_id: + type: string + description: Identifies this specific invocation approval, not the tool definition. + type: + type: string + enum: + - TOOL_APPROVAL + description: Interaction type identifying a tool execution approval request. + tool_id: + type: string + description: Platform tool identifier when recorded. Omitted for requests without one, such as some MCP tools. + display_name: + type: string + description: Display name of the tool requesting approval. + description: + type: string + description: Description of the tool associated with this approval request. + arguments: + type: object + additionalProperties: true + description: Arguments from the persisted approval request. Older platform tools use flattened parameters. + expires_at: type: string - description: Case-insensitive substring to match against agent names. If omitted or empty, no name filter is applied. - example: HR Policy Agent - PlatformAgentCapabilities: + format: date-time + description: Approval deadline, when one is set. Omitted when the approval has no expiration. + PlatformAgentRunError: type: object - additionalProperties: true + description: Caller-safe details of an agent run execution failure. + required: + - code + - message properties: - ap.io.messages: - type: boolean - description: Whether the agent supports messages as input. - ap.io.streaming: - type: boolean - description: Whether the agent supports streaming output. - PlatformAgent: + code: + type: string + description: Machine-readable execution failure code. + message: + type: string + description: Caller-safe execution failure description. + PlatformDurableAgentRun: type: object + description: Agent run state, pending tool approvals, and output available independently of the creation request. required: + - run_id - agent_id - - name - - capabilities + - state + - created_at + - updated_at + - pending_interactions properties: + run_id: + type: string + description: ID of the run, preserved across approval continuations. agent_id: type: string - description: ID of the agent. - example: mho4lwzylcozgoc2 - name: + description: ID of the agent that owns the run. + state: + $ref: "#/components/schemas/PlatformAgentRunState" + description: Current lifecycle state of the run. + created_at: type: string - description: Name of the agent. - example: HR Policy Agent - description: + format: date-time + description: Timestamp when the run was first persisted. + updated_at: type: string - description: Description of the agent. - metadata: + format: date-time + description: | + Latest persisted activity timestamp across the execution and its messages, including checkpoint messages. This is not a worker heartbeat or an exact state-transition timestamp. + expires_at: + type: string + format: date-time + description: Execution deadline, when one is set. Not the run history retention deadline. + pending_interactions: + type: array + description: Unanswered tool approvals when the run is in REQUIRES_INPUT. Empty in other states. + items: + $ref: "#/components/schemas/PlatformAgentRunToolApproval" + output: type: object - description: Agent metadata. additionalProperties: true - capabilities: - $ref: "#/components/schemas/PlatformAgentCapabilities" - PlatformAgentsSearchResponse: + description: Accumulated text-only agent output under the messages key, when available. + error: + $ref: "#/components/schemas/PlatformAgentRunError" + description: Caller-safe failure details when the run is in FAILED. + PlatformAgentRunResponse: type: object + description: Persisted agent run snapshot with a request ID for support correlation. required: - - agents + - run - request_id properties: - agents: - type: array - description: Agents matching the search request. - items: - $ref: "#/components/schemas/PlatformAgent" + run: + $ref: "#/components/schemas/PlatformDurableAgentRun" + description: Current persisted snapshot of the requested agent run. request_id: type: string description: Platform-generated request ID for support correlation. - PlatformProblemDetailCode: - type: string - description: Stable machine-readable error code. - enum: - - invalid_request - - missing_required_field - - invalid_parameter - - invalid_cursor - - expired_cursor - - invalid_filter - - invalid_datasource - - authentication_required - - token_expired - - insufficient_permissions - - spend_limit_exceeded - - resource_not_found - - method_not_allowed - - request_timeout - - request_too_large - - token_limit_exceeded - - conflict - - gone - - unprocessable_query - - tools_unauthorized - - rate_limit_exceeded - - internal_error - - service_unavailable - x-glean-problem-detail-codes: - invalid_request: - status: 400 - title: Invalid Request - missing_required_field: - status: 400 - title: Missing Required Field - invalid_parameter: - status: 400 - title: Invalid Parameter - invalid_cursor: - status: 400 - title: Invalid Pagination Cursor - expired_cursor: - status: 400 - title: Expired Pagination Cursor - invalid_filter: - status: 400 - title: Invalid Filter - invalid_datasource: - status: 400 - title: Invalid Datasource - authentication_required: - status: 401 - title: Authentication Required - token_expired: - status: 401 - title: Token Expired - insufficient_permissions: - status: 403 - title: Insufficient Permissions - spend_limit_exceeded: - status: 403 - title: Spend Limit Exceeded - resource_not_found: - status: 404 - title: Resource Not Found - method_not_allowed: - status: 405 - title: Method Not Allowed - request_timeout: - status: 408 - title: Request Timeout - request_too_large: - status: 413 - title: Request Too Large - token_limit_exceeded: - status: 413 - title: Token Limit Exceeded - conflict: - status: 409 - title: Conflict - gone: - status: 410 - title: Gone - unprocessable_query: - status: 422 - title: Unprocessable Query - tools_unauthorized: - status: 422 - title: Tools Unauthorized - rate_limit_exceeded: - status: 429 - title: Rate Limit Exceeded - internal_error: - status: 500 - title: Internal Error - service_unavailable: - status: 503 - title: Service Unavailable - example: invalid_cursor - PlatformProblemDetailError: + PlatformAuthenticationSuggestion: type: object + description: One tool the caller must authorize before the agent can run. required: - - pointer - - detail - description: Field-level validation problem for a single offending field. + - server_id properties: - pointer: + tool_name: type: string - description: RFC 6901 JSON Pointer to the offending field. - example: /messages/0/role - detail: + description: Human-readable tool name. + server_id: type: string - description: Human-readable explanation for this field. - example: "Must be one of: USER, GLEAN_AI." - code: - $ref: "#/components/schemas/PlatformProblemDetailCode" - PlatformProblemDetail: + description: Identifier to POST to `/tool-servers/{serverId}/auth` (Client API) with `returnUrl` in the request body to obtain an `authorizationUrl` to redirect the end user to. + PlatformUnauthorizedAgentToolsProblem: + description: Problem detail extended with `authentication_suggestions` naming each tool the caller must authorize. + allOf: + - $ref: "#/components/schemas/PlatformProblemDetail" + - type: object + required: + - authentication_suggestions + properties: + authentication_suggestions: + type: array + description: One entry per tool the caller must authorize. + items: + $ref: "#/components/schemas/PlatformAuthenticationSuggestion" + PlatformAgentRunCancellationRequest: type: object + additionalProperties: false + description: Request cooperative cancellation of a run owned by the caller. required: - - type - - title - - status - - detail - - code - - request_id - description: | - Error response following RFC 9457, extended with `code` and `documentation_url` for machine-readable classification and self-service remediation. + - run_id + example: + run_id: "{run_id}" properties: - type: - type: string - format: uri - description: URI identifying the error type. - example: https://developers.glean.com/errors/invalid-cursor - title: + run_id: type: string - description: Short, human-readable summary of the error. - example: Invalid Pagination Cursor - status: - type: integer - description: HTTP status code mirrored from the response. - example: 400 - detail: + minLength: 1 + maxLength: 256 + description: ID of the run to cancel. Must belong to the agent identified in the path. + PlatformAgentRunApprovalDecision: + type: object + additionalProperties: false + description: Approve or reject the invocation identified by a pending interaction ID. + required: + - interaction_id + - decision + properties: + interaction_id: type: string - description: Human-readable explanation specific to this occurrence. - example: | - The provided cursor has expired. Start a new search to get a fresh cursor. - code: - $ref: "#/components/schemas/PlatformProblemDetailCode" - documentation_url: + minLength: 1 + maxLength: 256 + description: The interaction_id returned in the run's pending_interactions. + decision: type: string - format: uri - description: Direct URL to documentation for this error code. - example: https://developers.glean.com/errors/invalid-cursor - request_id: + enum: + - APPROVE + - REJECT + description: The decision for this invocation only. Rejection follows normal workflow behavior. + PlatformAgentRunResponsesRequest: + type: object + additionalProperties: false + description: Invocation-scoped decisions for the complete pending approval batch. + required: + - run_id + - responses + example: + run_id: "{run_id}" + responses: + - interaction_id: "{interaction_id}" + decision: APPROVE + properties: + run_id: type: string - description: Platform-generated request ID for support correlation. - example: req_7f8a9b0c1d2e - errors: + minLength: 1 + maxLength: 256 + description: ID of the run whose pending approvals are being answered. Must belong to the agent identified in the path. + responses: type: array - description: Field-level validation problems, one entry per offending field. + minItems: 1 + maxItems: 100 + description: One decision per pending interaction. Interaction IDs must be unique. items: - $ref: "#/components/schemas/PlatformProblemDetailError" - PlatformAgentGetResponse: + $ref: "#/components/schemas/PlatformAgentRunApprovalDecision" + PlatformChatInputMessage: type: object + additionalProperties: false required: - - agent - - request_id + - role + - content properties: - agent: - $ref: "#/components/schemas/PlatformAgent" - request_id: + role: type: string - description: Platform-generated request ID for support correlation. - PlatformActionSummary: + enum: + - USER + - ASSISTANT + content: + type: string + minLength: 1 + PlatformChatTextFormat: type: object + additionalProperties: false + description: Unconstrained plain-text assistant output. required: - - tool_id - - display_name + - type properties: - tool_id: - type: string - description: Unique identifier of the action. - display_name: - type: string - description: Display name of the action. type: type: string - description: Tool type. - auth_type: - type: string - description: Authentication type required by the action. - write_action_type: - type: string - description: Write-action execution type. - is_setup_finished: - type: boolean - description: Whether this action has been fully configured. - data_source: - type: string - description: Kind of knowledge the action accesses or modifies. - PlatformAgentSchemasResponse: + description: Discriminator. Must be TEXT. + enum: + - TEXT + PlatformChatJsonSchemaFormat: type: object + additionalProperties: false + description: Constrains the assistant response to a caller-supplied JSON Schema. required: - - agent_id - - input_schema - - output_schema - - request_id + - type + - name + - schema properties: - agent_id: + type: type: string - description: ID of the agent. + description: Discriminator. Must be JSON_SCHEMA. + enum: + - JSON_SCHEMA name: type: string - description: Name of the agent. - input_schema: - type: object - description: Agent input schema in JSON Schema format. - additionalProperties: true - output_schema: + minLength: 1 + maxLength: 64 + description: A stable identifier for the schema. + description: + type: string + maxLength: 1024 + description: An optional human-readable description of the schema. + schema: type: object - description: Agent output schema in JSON Schema format. additionalProperties: true - tools: - type: array - description: Tools that the agent can invoke, when requested. - items: - $ref: "#/components/schemas/PlatformActionSummary" - request_id: + description: A JSON Schema object describing the desired output shape. + strict: + type: boolean + default: true + description: | + When true, the provider validates the response against the schema. Unsupported by some providers; defaults to true. + PlatformChatCreateRequest: + type: object + additionalProperties: false + required: + - input + example: + input: Summarize our parental leave policy as JSON. + text: + format: + type: JSON_SCHEMA + name: policy_summary + schema: + type: object + properties: + eligible_employees: + type: string + duration_weeks: + type: integer + required: + - eligible_employees + - duration_weeks + strict: true + properties: + input: + description: | + Either a plain string (single user turn) or a chronological array of `USER`/`ASSISTANT` messages. The final array message must be `USER`. + oneOf: + - type: string + minLength: 1 + - type: array + minItems: 1 + items: + $ref: "#/components/schemas/PlatformChatInputMessage" + stream: + type: boolean + description: | + When true, the HTTP response is `text/event-stream`. When false or omitted, the HTTP response is `application/json`. + default: false + store: + type: boolean + description: | + When true (default), persist the interaction and return a `conversation_id`. When false, run ephemerally with no persistence. + default: true + conversation_id: type: string - description: Platform-generated request ID for support correlation. - PlatformMessageRole: - type: string - description: Role of the message author. - example: USER - enum: - - USER - - GLEAN_AI - PlatformContentType: + minLength: 1 + description: | + Continue an existing stored conversation. Incompatible with message-array `input` and with `store: false`. + text: + type: object + additionalProperties: false + description: | + Optional configuration for the assistant's text response. When `format.type` is `JSON_SCHEMA`, the response is constrained to the supplied JSON schema and returned in `output[*].content[*].structured_output`. Structured output is not supported when `stream` is true. + properties: + format: + description: | + Output format for the assistant text. TEXT is unconstrained. JSON_SCHEMA constrains the response to the supplied schema. + oneOf: + - $ref: "#/components/schemas/PlatformChatTextFormat" + - $ref: "#/components/schemas/PlatformChatJsonSchemaFormat" + PlatformChatStreamResponseId: type: string - enum: - - text - PlatformChatDocumentSource: + minLength: 1 + pattern: ^resp_[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$ + description: | + Platform-owned, non-persisted response envelope identifier in `resp_` form. The same identifier is used for every event in one streamed response. + PlatformChatOutputTextContent: type: object additionalProperties: false required: - type + - text properties: type: type: string - x-discriminator: true enum: - - DOCUMENT - document_id: - type: string - minLength: 1 - url: - type: string - minLength: 1 - title: - type: string - datasource: + - OUTPUT_TEXT + text: type: string - anyOf: - - required: - - document_id - properties: - document_id: - type: string - minLength: 1 - - required: - - url - properties: - url: - type: string - minLength: 1 - PlatformChatPersonSource: + structured_output: + type: + - object + - "null" + description: | + Parsed and validated JSON object when structured output was requested. Present only when the request included `text.format.type: JSON_SCHEMA`. + annotations: + type: array + items: + $ref: "#/components/schemas/PlatformChatCitationAnnotation" + PlatformChatOutputMessage: type: object additionalProperties: false required: - type - - person_id + - role + - content properties: type: type: string - x-discriminator: true enum: - - PERSON - person_id: - type: string - minLength: 1 - name: - type: string - url: + - MESSAGE + role: type: string - PlatformChatFileSource: + enum: + - ASSISTANT + content: + type: array + minItems: 1 + maxItems: 1 + items: + $ref: "#/components/schemas/PlatformChatOutputTextContent" + PlatformChatCompletedResponse: type: object additionalProperties: false required: - - type - - file_id + - id + - object + - created_at + - status + - output + - store + - request_id properties: - type: + id: + $ref: "#/components/schemas/PlatformChatStreamResponseId" + object: type: string - x-discriminator: true enum: - - FILE - file_id: - type: string - minLength: 1 - title: + - RESPONSE + created_at: type: string - url: + format: date-time + description: RFC 3339 UTC timestamp when the response was created. + status: type: string - datasource: + enum: + - COMPLETED + output: + type: array + minItems: 1 + maxItems: 1 + items: + $ref: "#/components/schemas/PlatformChatOutputMessage" + store: + type: boolean + conversation_id: + type: + - string + - "null" + minLength: 1 + description: Present when the interaction was persisted. + request_id: type: string - PlatformChatCustomEntitySource: + minLength: 1 + PlatformChatStreamResponseCreated: type: object additionalProperties: false required: - type - - entity_id + - response_id properties: type: type: string - x-discriminator: true enum: - - CUSTOM_ENTITY - entity_id: - type: string - minLength: 1 - name: - type: string - title: - type: string - url: - type: string - datasource: - type: string - PlatformChatCitationSource: - description: Four-variant citation source union. - x-multiple-discriminators: true - oneOf: - - $ref: "#/components/schemas/PlatformChatDocumentSource" - - $ref: "#/components/schemas/PlatformChatPersonSource" - - $ref: "#/components/schemas/PlatformChatFileSource" - - $ref: "#/components/schemas/PlatformChatCustomEntitySource" - discriminator: - propertyName: type - mapping: - DOCUMENT: "#/components/schemas/PlatformChatDocumentSource" - PERSON: "#/components/schemas/PlatformChatPersonSource" - FILE: "#/components/schemas/PlatformChatFileSource" - CUSTOM_ENTITY: "#/components/schemas/PlatformChatCustomEntitySource" - PlatformChatCitationSnippet: + - RESPONSE_CREATED + response_id: + $ref: "#/components/schemas/PlatformChatStreamResponseId" + PlatformChatStreamProgress: type: object additionalProperties: false required: + - type + - response_id - text properties: + type: + type: string + enum: + - RESPONSE_PROGRESS + response_id: + $ref: "#/components/schemas/PlatformChatStreamResponseId" text: type: string minLength: 1 - page_number: - type: - - integer - - "null" - PlatformChatCitationAnnotation: + description: | + Verbatim concatenated fragment text from an assistant UPDATE wire message. Display-oriented passthrough only; not part of the final answer and not present on terminal response snapshots. + PlatformChatStreamOutputTextDelta: type: object additionalProperties: false required: - type - - sources + - response_id + - delta properties: type: type: string enum: - - CITATION - sources: - type: array - minItems: 1 - items: - $ref: "#/components/schemas/PlatformChatCitationSource" - start_index: - type: - - integer - - "null" - minimum: 0 - end_index: - type: - - integer - - "null" - minimum: 0 - snippets: - type: - - array - - "null" - items: - $ref: "#/components/schemas/PlatformChatCitationSnippet" - PlatformMessageTextBlock: + - RESPONSE_OUTPUT_TEXT_DELTA + response_id: + $ref: "#/components/schemas/PlatformChatStreamResponseId" + delta: + type: string + PlatformChatStreamOutputTextDone: type: object + additionalProperties: false required: - - text - type + - response_id + - text properties: - text: - type: string - description: Text content. type: - $ref: "#/components/schemas/PlatformContentType" - annotations: - type: array - readOnly: true - items: - $ref: "#/components/schemas/PlatformChatCitationAnnotation" - PlatformMessage: - type: object - required: - - role - - content - properties: - role: - $ref: "#/components/schemas/PlatformMessageRole" - content: - type: array - minItems: 1 - description: Content blocks in the message. - items: - $ref: "#/components/schemas/PlatformMessageTextBlock" - PlatformAgentRunCreateRequest: - type: object - additionalProperties: false - description: | - Request to run an agent. A request MUST supply either `messages` (a non-empty conversation) or `input` (for input-form triggered agents). - example: - messages: - - role: USER - content: - - text: What is our parental leave policy? - type: text - properties: - input: - type: object - description: Input fields for an input-form triggered agent. - additionalProperties: true - messages: - type: array - minItems: 1 - description: | - Messages to pass to the agent. When provided, the array MUST contain at least one message and each message MUST specify a valid `role` and non-empty `content`. - items: - $ref: "#/components/schemas/PlatformMessage" - metadata: - type: object - description: Metadata to pass to the agent. - additionalProperties: true - stream: - type: boolean - description: Whether to stream the run response as server-sent events. Not supported in DURABLE mode. - default: false - execution_mode: type: string enum: - - REQUEST_BOUND - - DURABLE - default: REQUEST_BOUND - description: | - REQUEST_BOUND preserves the existing wait/stream behavior. DURABLE starts a fresh, persisted execution with a 30-minute execution timeout and returns immediately. DURABLE requires stream to be false or omitted and does not accept metadata.chat_session_id. It does not bypass tool approval requirements or provide automatic QE-crash resumption. Expiry is read-triggered: the next GET of the run marks an active turn FAILED if more than 40 minutes have passed since the turn was accepted. There is no periodic sweep, so the stored run can remain RUNNING until it is read. Expiry never replays execution or expires approval-paused runs, and failure does not prove that external tool work has stopped. - PlatformAgentRunCreate: + - RESPONSE_OUTPUT_TEXT_DONE + response_id: + $ref: "#/components/schemas/PlatformChatStreamResponseId" + text: + type: string + PlatformChatStreamResponseCompleted: type: object + additionalProperties: false required: - - agent_id - properties: - agent_id: - type: string - description: ID of the agent being run. - input: - type: object - description: Input fields for an input-form triggered agent. - additionalProperties: true - messages: - type: array - description: Messages passed to the agent. - items: - $ref: "#/components/schemas/PlatformMessage" - metadata: - type: object - description: Metadata passed to the agent. - additionalProperties: true - PlatformAgentExecutionStatus: - type: string - description: Status of the agent run. - enum: - - error - - success - PlatformAgentRun: - allOf: - - $ref: "#/components/schemas/PlatformAgentRunCreate" - - type: object - required: - - status - properties: - status: - $ref: "#/components/schemas/PlatformAgentExecutionStatus" - PlatformAgentRunWaitResponse: + - type + - response_id + - response + properties: + type: + type: string + enum: + - RESPONSE_COMPLETED + response_id: + $ref: "#/components/schemas/PlatformChatStreamResponseId" + response: + $ref: "#/components/schemas/PlatformChatCompletedResponse" + PlatformChatResponseError: + type: object + additionalProperties: false + required: + - message + properties: + code: + type: + - string + - "null" + description: | + Open snake_case error code aligned with ProblemDetail codes when present. Clients must tolerate unknown values; the set of codes is not a closed enum. Limit failures use `spend_limit_exceeded` (billing spend limit) and `token_limit_exceeded` (model context/token limit). + example: spend_limit_exceeded + message: + type: string + minLength: 1 + PlatformChatFailedResponse: type: object + additionalProperties: false required: + - id + - object + - created_at + - status + - output + - store - request_id + - error properties: - run: - $ref: "#/components/schemas/PlatformAgentRun" - messages: + id: + $ref: "#/components/schemas/PlatformChatStreamResponseId" + object: + type: string + enum: + - RESPONSE + created_at: + type: string + format: date-time + description: RFC 3339 UTC timestamp when the response was created. + status: + type: string + enum: + - FAILED + output: type: array - description: Messages returned by the completed run. + maxItems: 1 items: - $ref: "#/components/schemas/PlatformMessage" + $ref: "#/components/schemas/PlatformChatOutputMessage" + store: + type: boolean + conversation_id: + type: + - string + - "null" + minLength: 1 + description: Present when the interaction was persisted. request_id: type: string - description: Platform-generated request ID for support correlation. - PlatformAgentRunState: - type: string - enum: - - QUEUED - - RUNNING - - REQUIRES_INPUT - - SUCCEEDED - - FAILED - - CANCELLING - - CANCELLED - - EXPIRED - description: State of the persisted workflow execution. REQUIRES_INPUT is nonterminal. - PlatformAgentRunToolApproval: + minLength: 1 + error: + $ref: "#/components/schemas/PlatformChatResponseError" + PlatformChatStreamResponseFailed: type: object - description: Pending approval for a specific persisted tool invocation and its arguments. + additionalProperties: false required: - - interaction_id - type - - display_name - - description - - arguments + - response_id + - response properties: - interaction_id: - type: string - description: Identifies this specific invocation approval, not the tool definition. type: type: string enum: - - TOOL_APPROVAL - description: Interaction type identifying a tool execution approval request. - tool_id: + - RESPONSE_FAILED + response_id: + $ref: "#/components/schemas/PlatformChatStreamResponseId" + response: + $ref: "#/components/schemas/PlatformChatFailedResponse" + PlatformChatStreamEvent: + description: | + JSON object written to the SSE `data` field. This schema is the payload for SDK transform, not the raw HTTP body. Do not run JSON response conformance on stream bodies. A typical wire frame is: + id: 1 + event: RESPONSE_CREATED + data: {"type":"RESPONSE_CREATED","response_id":"resp_e65a0a77-97a2-4c91-be60-eae7f6238015"} + example: + type: RESPONSE_CREATED + response_id: resp_e65a0a77-97a2-4c91-be60-eae7f6238015 + oneOf: + - $ref: "#/components/schemas/PlatformChatStreamResponseCreated" + - $ref: "#/components/schemas/PlatformChatStreamProgress" + - $ref: "#/components/schemas/PlatformChatStreamOutputTextDelta" + - $ref: "#/components/schemas/PlatformChatStreamOutputTextDone" + - $ref: "#/components/schemas/PlatformChatStreamResponseCompleted" + - $ref: "#/components/schemas/PlatformChatStreamResponseFailed" + discriminator: + propertyName: type + mapping: + RESPONSE_CREATED: "#/components/schemas/PlatformChatStreamResponseCreated" + RESPONSE_PROGRESS: "#/components/schemas/PlatformChatStreamProgress" + RESPONSE_OUTPUT_TEXT_DELTA: "#/components/schemas/PlatformChatStreamOutputTextDelta" + RESPONSE_OUTPUT_TEXT_DONE: "#/components/schemas/PlatformChatStreamOutputTextDone" + RESPONSE_COMPLETED: "#/components/schemas/PlatformChatStreamResponseCompleted" + RESPONSE_FAILED: "#/components/schemas/PlatformChatStreamResponseFailed" + PlatformSkillStatus: + type: string + enum: + - DRAFT + - ENABLED + - DISABLED + description: | + The caller's effective activation. The owner sees the skill's stored status. Another caller sees their personal setting, or DISABLED when they have none. DRAFT is the stored draft state and is not set by update. Effective activation may also reflect workspace governance policy. + PlatformSkillOrigin: + type: string + enum: + - CUSTOM + - GITHUB + description: Source category for the skill. + PlatformSkillSyncStatus: + type: string + enum: + - UP_TO_DATE + - UPDATE_AVAILABLE + - SYNC_FAILED + description: Current external-source sync status. + PlatformSkillSourceProvenance: + type: object + properties: + source_url: type: string - description: Platform tool identifier when recorded. Omitted for requests without one, such as some MCP tools. - display_name: + description: URL of the external source the skill was imported from. + commit_sha: type: string - description: Display name of the tool requesting approval. - description: + description: Source commit SHA for the imported skill. + imported_at: type: string - description: Description of the tool associated with this approval request. - arguments: - type: object - additionalProperties: true - description: Arguments from the persisted approval request. Older platform tools use flattened parameters. - expires_at: + format: date-time + description: Time the skill was imported. + last_synced_at: type: string format: date-time - description: Approval deadline, when one is set. Omitted when the approval has no expiration. - PlatformAgentRunError: + description: Time the skill was last synced from its source. + sync_status: + $ref: "#/components/schemas/PlatformSkillSyncStatus" + sync_error: + type: string + description: Human-readable sync failure reason, present only when sync_status is SYNC_FAILED. + PlatformPersonReference: type: object - description: Caller-safe details of an agent run execution failure. + description: A lightweight reference to a person, used where a payload merely points at someone. required: - - code - - message + - name properties: - code: + id: type: string - description: Machine-readable execution failure code. - message: + description: Opaque Glean person ID. + name: type: string - description: Caller-safe execution failure description. - PlatformDurableAgentRun: + description: Display name. + PlatformSkill: type: object - description: Agent run state, pending tool approvals, and output available independently of the creation request. required: - - run_id - - agent_id - - state + - skill_id + - display_name + - description + - latest_version + - latest_minor_version + - status + - origin + - owner - created_at - updated_at - - pending_interactions properties: - run_id: + skill_id: type: string - description: ID of the run, preserved across approval continuations. - agent_id: + description: Glean skill ID. + display_name: type: string - description: ID of the agent that owns the run. - state: - $ref: "#/components/schemas/PlatformAgentRunState" - description: Current lifecycle state of the run. + description: Human-readable skill name. + description: + type: string + description: Human-readable skill description. + latest_version: + type: integer + description: Latest major version number for the skill. + latest_minor_version: + type: integer + description: Latest minor version number for the skill. + status: + $ref: "#/components/schemas/PlatformSkillStatus" + origin: + $ref: "#/components/schemas/PlatformSkillOrigin" + source_provenance: + $ref: "#/components/schemas/PlatformSkillSourceProvenance" + owner: + $ref: "#/components/schemas/PlatformPersonReference" created_at: type: string format: date-time - description: Timestamp when the run was first persisted. + description: Time the skill was created. updated_at: type: string - format: date-time - description: | - Latest persisted activity timestamp across the execution and its messages, including checkpoint messages. This is not a worker heartbeat or an exact state-transition timestamp. - expires_at: - type: string - format: date-time - description: Execution deadline, when one is set. Not the run history retention deadline. - pending_interactions: - type: array - description: Unanswered tool approvals when the run is in REQUIRES_INPUT. Empty in other states. - items: - $ref: "#/components/schemas/PlatformAgentRunToolApproval" - output: - type: object - additionalProperties: true - description: Accumulated text-only agent output under the messages key, when available. - error: - $ref: "#/components/schemas/PlatformAgentRunError" - description: Caller-safe failure details when the run is in FAILED. - PlatformAgentRunResponse: + format: date-time + description: Time the skill was last updated. + PlatformSkillsListResponse: type: object - description: Persisted agent run snapshot with a request ID for support correlation. required: - - run + - results + - has_more + - next_cursor - request_id properties: - run: - $ref: "#/components/schemas/PlatformDurableAgentRun" - description: Current persisted snapshot of the requested agent run. + results: + type: array + description: Skills available to the user. + items: + $ref: "#/components/schemas/PlatformSkill" + has_more: + type: boolean + description: Whether additional results are available. + next_cursor: + type: + - string + - "null" + description: Cursor for the next page, or null when no more results are available. request_id: type: string description: Platform-generated request ID for support correlation. - PlatformAuthenticationSuggestion: - type: object - description: One tool the caller must authorize before the agent can run. - required: - - server_id - properties: - tool_name: - type: string - description: Human-readable tool name. - server_id: - type: string - description: Identifier to POST to `/tool-servers/{serverId}/auth` (Client API) with `returnUrl` in the request body to obtain an `authorizationUrl` to redirect the end user to. - PlatformUnauthorizedAgentToolsProblem: - description: Problem detail extended with `authentication_suggestions` naming each tool the caller must authorize. - allOf: - - $ref: "#/components/schemas/PlatformProblemDetail" - - type: object - required: - - authentication_suggestions - properties: - authentication_suggestions: - type: array - description: One entry per tool the caller must authorize. - items: - $ref: "#/components/schemas/PlatformAuthenticationSuggestion" - PlatformAgentRunCancellationRequest: + PlatformSkillCreateRequest: type: object additionalProperties: false - description: Request cooperative cancellation of a run owned by the caller. required: - - run_id - example: - run_id: "{run_id}" + - file properties: - run_id: + file: type: string - minLength: 1 - maxLength: 256 - description: ID of the run to cancel. Must belong to the agent identified in the path. - PlatformAgentRunApprovalDecision: + format: binary + description: SKILL.md, .zip, or .skill bundle to create. + PlatformSkillCreateResponse: type: object - additionalProperties: false - description: Approve or reject the invocation identified by a pending interaction ID. required: - - interaction_id - - decision + - skill + - request_id properties: - interaction_id: - type: string - minLength: 1 - maxLength: 256 - description: The interaction_id returned in the run's pending_interactions. - decision: + skill: + $ref: "#/components/schemas/PlatformSkill" + request_id: type: string - enum: - - APPROVE - - REJECT - description: The decision for this invocation only. Rejection follows normal workflow behavior. - PlatformAgentRunResponsesRequest: + description: Platform-generated request ID for support correlation. + PlatformSkillImportRequest: type: object additionalProperties: false - description: Invocation-scoped decisions for the complete pending approval batch. required: - - run_id - - responses + - source_urls example: - run_id: "{run_id}" - responses: - - interaction_id: "{interaction_id}" - decision: APPROVE + source_urls: + - https://github.com/anthropics/skills/tree/main/skills/skill-creator properties: - run_id: - type: string - minLength: 1 - maxLength: 256 - description: ID of the run whose pending approvals are being answered. Must belong to the agent identified in the path. - responses: + source_urls: type: array minItems: 1 maxItems: 100 - description: One decision per pending interaction. Interaction IDs must be unique. + uniqueItems: true + description: Resolved GitHub skill URLs selected from a source preview. items: - $ref: "#/components/schemas/PlatformAgentRunApprovalDecision" - PlatformChatInputMessage: + type: string + minLength: 1 + maxLength: 2048 + PlatformSkillImportResponse: type: object - additionalProperties: false required: - - role - - content + - skills + - request_id properties: - role: - type: string - enum: - - USER - - ASSISTANT - content: + skills: + type: array + minItems: 1 + description: | + Imported skills in request order. The import is atomic: either every source persists or none does. + items: + $ref: "#/components/schemas/PlatformSkill" + request_id: type: string - minLength: 1 - PlatformChatTextFormat: + description: Platform-generated request ID for support correlation. + PlatformSkillValidationRequest: type: object additionalProperties: false - description: Unconstrained plain-text assistant output. required: - - type + - file properties: - type: + file: type: string - description: Discriminator. Must be TEXT. - enum: - - TEXT - PlatformChatJsonSchemaFormat: + format: binary + description: SKILL.md, .zip, or .skill bundle to validate. + PlatformSkillValidationMetadata: type: object - additionalProperties: false - description: Constrains the assistant response to a caller-supplied JSON Schema. required: - - type - - name - - schema + - display_name + - description properties: - type: - type: string - description: Discriminator. Must be JSON_SCHEMA. - enum: - - JSON_SCHEMA - name: + display_name: type: string - minLength: 1 - maxLength: 64 - description: A stable identifier for the schema. + description: Skill name parsed from SKILL.md frontmatter. description: type: string - maxLength: 1024 - description: An optional human-readable description of the schema. - schema: - type: object - additionalProperties: true - description: A JSON Schema object describing the desired output shape. - strict: + description: Skill description parsed from SKILL.md frontmatter. + PlatformSkillValidationFile: + type: object + required: + - path + - size_bytes + - is_manifest + properties: + path: + type: string + description: Normalized relative path in the skill bundle. + size_bytes: + type: integer + description: File size in bytes. + is_manifest: type: boolean - default: true - description: | - When true, the provider validates the response against the schema. Unsupported by some providers; defaults to true. - PlatformChatCreateRequest: + description: Whether this file is the skill manifest. + PlatformSkillValidationResponse: + type: object + required: + - metadata + - files + - warnings + - request_id + properties: + metadata: + $ref: "#/components/schemas/PlatformSkillValidationMetadata" + files: + type: array + description: Normalized files in the bundle after stripping an optional single root folder. + items: + $ref: "#/components/schemas/PlatformSkillValidationFile" + warnings: + type: array + description: Non-blocking validation warnings. + items: + $ref: "#/components/schemas/PlatformWarning" + request_id: + type: string + description: Platform-generated request ID for support correlation. + PlatformSkillSourcePreviewRequest: type: object additionalProperties: false required: - - input + - source_url example: - input: Summarize our parental leave policy as JSON. - text: - format: - type: JSON_SCHEMA - name: policy_summary - schema: - type: object - properties: - eligible_employees: - type: string - duration_weeks: - type: integer - required: - - eligible_employees - - duration_weeks - strict: true - properties: - input: - description: | - Either a plain string (single user turn) or a chronological array of `USER`/`ASSISTANT` messages. The final array message must be `USER`. - oneOf: - - type: string - minLength: 1 - - type: array - minItems: 1 - items: - $ref: "#/components/schemas/PlatformChatInputMessage" - stream: - type: boolean - description: | - When true, the HTTP response is `text/event-stream`. When false or omitted, the HTTP response is `application/json`. - default: false - store: - type: boolean - description: | - When true (default), persist the interaction and return a `conversation_id`. When false, run ephemerally with no persistence. - default: true - conversation_id: + source_url: https://github.com/anthropics/skills + properties: + source_url: type: string minLength: 1 - description: | - Continue an existing stored conversation. Incompatible with message-array `input` and with `store: false`. - text: - type: object - additionalProperties: false - description: | - Optional configuration for the assistant's text response. When `format.type` is `JSON_SCHEMA`, the response is constrained to the supplied JSON schema and returned in `output[*].content[*].structured_output`. Structured output is not supported when `stream` is true. - properties: - format: - description: | - Output format for the assistant text. TEXT is unconstrained. JSON_SCHEMA constrains the response to the supplied schema. - oneOf: - - $ref: "#/components/schemas/PlatformChatTextFormat" - - $ref: "#/components/schemas/PlatformChatJsonSchemaFormat" - PlatformChatStreamResponseId: - type: string - minLength: 1 - pattern: ^resp_[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$ - description: | - Platform-owned, non-persisted response envelope identifier in `resp_` form. The same identifier is used for every event in one streamed response. - PlatformChatOutputTextContent: + maxLength: 2048 + description: GitHub URL for a skill directory, SKILL.md file, or repository to inspect. + stream: + type: boolean + default: false + description: Whether to stream repository scan progress using server-sent events. + PlatformSkillSourcePreviewFile: type: object - additionalProperties: false required: - - type - - text + - path + - content properties: - type: + path: type: string - enum: - - OUTPUT_TEXT - text: + description: Relative path within the skill bundle. + content: type: string - structured_output: - type: - - object - - "null" - description: | - Parsed and validated JSON object when structured output was requested. Present only when the request included `text.format.type: JSON_SCHEMA`. - annotations: - type: array - items: - $ref: "#/components/schemas/PlatformChatCitationAnnotation" - PlatformChatOutputMessage: + description: UTF-8 file content. + PlatformSkillSourcePreview: type: object - additionalProperties: false required: - - type - - role - - content + - display_name + - description + - source_url + - commit_sha + - main_content + - files + - file_tree properties: - type: + display_name: type: string - enum: - - MESSAGE - role: + description: Skill name parsed from SKILL.md frontmatter. + description: type: string - enum: - - ASSISTANT - content: + description: Skill description parsed from SKILL.md frontmatter. + source_url: + type: string + description: Resolved URL for this skill within the source. + commit_sha: + type: string + description: Commit SHA used to produce the preview. + main_content: + type: string + description: SKILL.md content fetched as part of the preview. + files: type: array - minItems: 1 - maxItems: 1 + description: Supporting files fetched with the skill. items: - $ref: "#/components/schemas/PlatformChatOutputTextContent" - PlatformChatCompletedResponse: + $ref: "#/components/schemas/PlatformSkillSourcePreviewFile" + file_tree: + type: array + description: Relative paths discovered for the skill. + items: + type: string + PlatformSkillSourcePreviewFailureCode: + type: string + enum: + - INVALID_SKILL + - SKILL_FETCH_FAILED + description: Stable machine-readable reason a discovered entry was excluded. + PlatformSkillSourcePreviewFailure: type: object - additionalProperties: false required: - - id - - object - - created_at - - status - - output - - store - - request_id + - source_url + - code + - detail properties: - id: - $ref: "#/components/schemas/PlatformChatStreamResponseId" - object: - type: string - enum: - - RESPONSE - created_at: + source_url: type: string - format: date-time - description: RFC 3339 UTC timestamp when the response was created. - status: + description: Resolved URL for the entry that could not be previewed. + code: + $ref: "#/components/schemas/PlatformSkillSourcePreviewFailureCode" + detail: type: string - enum: - - COMPLETED - output: + description: Safe explanation of why the entry was excluded. + PlatformSkillSourcePreviewResponse: + type: object + required: + - skills + - failures + - request_id + properties: + skills: type: array minItems: 1 - maxItems: 1 + description: Valid skills discovered at the source URL. items: - $ref: "#/components/schemas/PlatformChatOutputMessage" - store: - type: boolean - conversation_id: - type: - - string - - "null" - minLength: 1 - description: Present when the interaction was persisted. + $ref: "#/components/schemas/PlatformSkillSourcePreview" + failures: + type: array + description: Discovered entries that could not be included in the preview. + items: + $ref: "#/components/schemas/PlatformSkillSourcePreviewFailure" request_id: type: string - minLength: 1 - PlatformChatStreamResponseCreated: + description: Platform-generated request ID for support correlation. + PlatformSkillSourcePreviewStreamScan: type: object additionalProperties: false + description: Repository scan started; names every skill path found. required: - type - - response_id + - total + - skill_paths properties: type: type: string enum: - - RESPONSE_CREATED - response_id: - $ref: "#/components/schemas/PlatformChatStreamResponseId" - PlatformChatStreamProgress: + - SCAN + description: Event type, also sent as the SSE `event` name. + total: + type: integer + minimum: 0 + description: Number of skill paths found in the scan. + skill_paths: + type: array + description: Skill paths found in the scan. + items: + type: string + description: One skill path found in the scan. + PlatformSkillSourcePreviewStreamProgress: type: object additionalProperties: false + description: One skill finished inspecting; names the skill in progress. required: - type - - response_id - - text + - completed + - total + - current_skill properties: type: type: string enum: - - RESPONSE_PROGRESS - response_id: - $ref: "#/components/schemas/PlatformChatStreamResponseId" - text: + - PROGRESS + description: Event type, also sent as the SSE `event` name. + completed: + type: integer + minimum: 0 + description: Number of skills inspected so far. + total: + type: integer + minimum: 0 + description: Number of skills to inspect. + current_skill: type: string - minLength: 1 - description: | - Verbatim concatenated fragment text from an assistant UPDATE wire message. Display-oriented passthrough only; not part of the final answer and not present on terminal response snapshots. - PlatformChatStreamOutputTextDelta: + description: Path of the skill being inspected. + PlatformSkillSourcePreviewStreamSkill: type: object additionalProperties: false + description: One skill previewed; carries the previewed skill. required: - type - - response_id - - delta + - skill properties: type: type: string enum: - - RESPONSE_OUTPUT_TEXT_DELTA - response_id: - $ref: "#/components/schemas/PlatformChatStreamResponseId" - delta: + - SKILL + description: Event type, also sent as the SSE `event` name. + skill: + $ref: "#/components/schemas/PlatformSkillSourcePreview" + description: The previewed skill. + PlatformSkillSourcePreviewStreamResult: + type: object + additionalProperties: false + description: Terminal success event carrying the fully assembled preview. + required: + - type + - response + properties: + type: type: string - PlatformChatStreamOutputTextDone: + enum: + - RESULT + description: Event type, also sent as the SSE `event` name. + response: + $ref: "#/components/schemas/PlatformSkillSourcePreviewResponse" + description: The fully assembled preview response. + PlatformSkillSourcePreviewStreamError: type: object additionalProperties: false + description: Terminal failure event carrying the failure as a problem detail. Most GitHub authorization failures return HTTP 422 before the stream opens. If authorization fails after the stream opens, `error.code` is `tools_unauthorized` and `authentication_suggestions` is present. required: - type - - response_id - - text + - error properties: type: type: string enum: - - RESPONSE_OUTPUT_TEXT_DONE - response_id: - $ref: "#/components/schemas/PlatformChatStreamResponseId" - text: + - ERROR + description: Event type, also sent as the SSE `event` name. + error: + $ref: "#/components/schemas/PlatformProblemDetail" + description: The failure as a problem detail. + authentication_suggestions: + type: array + minItems: 1 + description: Present only when `error.code` is `tools_unauthorized`. Names the GitHub action pack to authorize, with the same retry flow as the 422 response. + items: + $ref: "#/components/schemas/PlatformAuthenticationSuggestion" + PlatformSkillSourcePreviewStreamEvent: + description: | + JSON object written to the SSE `data` field of a streaming source preview. This schema is the payload for SDK transform, not the raw HTTP body. Do not run JSON response conformance on stream bodies. Each frame also carries an `event` name matching the payload `type`. The stream ends with the RESULT event on success or the ERROR event on failure. A typical wire frame is: + event: SCAN + data: {"type":"SCAN","total":1,"skill_paths":["https://github.com/acme/skills/tree/main/skills/example"]} + example: + type: SCAN + total: 1 + skill_paths: + - https://github.com/acme/skills/tree/main/skills/example + oneOf: + - $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamScan" + - $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamProgress" + - $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamSkill" + - $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamResult" + - $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamError" + discriminator: + propertyName: type + mapping: + SCAN: "#/components/schemas/PlatformSkillSourcePreviewStreamScan" + PROGRESS: "#/components/schemas/PlatformSkillSourcePreviewStreamProgress" + SKILL: "#/components/schemas/PlatformSkillSourcePreviewStreamSkill" + RESULT: "#/components/schemas/PlatformSkillSourcePreviewStreamResult" + ERROR: "#/components/schemas/PlatformSkillSourcePreviewStreamError" + PlatformSkillGetResponse: + type: object + required: + - skill + - request_id + properties: + skill: + $ref: "#/components/schemas/PlatformSkill" + request_id: type: string - PlatformChatStreamResponseCompleted: + description: Platform-generated request ID for support correlation. + PlatformSkillUpdateStatus: + type: string + enum: + - ENABLED + - DISABLED + description: | + Activation to apply for the authenticated caller. For the owner, this updates the skill's stored status. For any other caller, it updates only that caller's setting. + PlatformSkillUpdateRequest: type: object additionalProperties: false required: - - type - - response_id - - response + - status + example: + status: ENABLED + properties: + status: + $ref: "#/components/schemas/PlatformSkillUpdateStatus" + PlatformSkillUpdateResponse: + type: object + required: + - skill + - request_id properties: - type: + skill: + $ref: "#/components/schemas/PlatformSkill" + request_id: type: string - enum: - - RESPONSE_COMPLETED - response_id: - $ref: "#/components/schemas/PlatformChatStreamResponseId" - response: - $ref: "#/components/schemas/PlatformChatCompletedResponse" - PlatformChatResponseError: + description: Platform-generated request ID for support correlation. + PlatformSkillSyncResponse: type: object - additionalProperties: false required: - - message + - commit_sha + - is_updated + - request_id properties: - code: - type: - - string - - "null" - description: | - Open snake_case error code aligned with ProblemDetail codes when present. Clients must tolerate unknown values; the set of codes is not a closed enum. Limit failures use `spend_limit_exceeded` (billing spend limit) and `token_limit_exceeded` (model context/token limit). - example: spend_limit_exceeded - message: + commit_sha: type: string minLength: 1 - PlatformChatFailedResponse: + description: Git commit SHA now associated with the skill. + is_updated: + type: boolean + description: Whether this request created a new skill version. + request_id: + type: string + description: Platform-generated request ID for support correlation. + PlatformSkillVersion: type: object - additionalProperties: false required: - - id - - object + - skill_id + - version + - minor_version + - is_latest + - created_by - created_at - - status - - output - - store - - request_id - - error + - updated_at properties: - id: - $ref: "#/components/schemas/PlatformChatStreamResponseId" - object: + skill_id: type: string - enum: - - RESPONSE + description: Glean skill ID. + version: + type: integer + description: Major version number. + minor_version: + type: integer + description: Minor version number. + is_latest: + type: boolean + description: Whether this is the latest version of the skill. + created_by: + $ref: "#/components/schemas/PlatformPersonReference" created_at: type: string format: date-time - description: RFC 3339 UTC timestamp when the response was created. - status: + description: Time this version was created. + updated_at: type: string - enum: - - FAILED - output: + format: date-time + description: Time this version was last updated. + source_provenance: + $ref: "#/components/schemas/PlatformSkillSourceProvenance" + PlatformSkillVersionsListResponse: + type: object + required: + - results + - has_more + - next_cursor + - request_id + properties: + results: type: array - maxItems: 1 + description: Versions available for the skill. items: - $ref: "#/components/schemas/PlatformChatOutputMessage" - store: + $ref: "#/components/schemas/PlatformSkillVersion" + has_more: type: boolean - conversation_id: + description: Whether additional results are available. + next_cursor: type: - string - "null" - minLength: 1 - description: Present when the interaction was persisted. + description: Cursor for the next page, or null when no more results are available. request_id: type: string - minLength: 1 - error: - $ref: "#/components/schemas/PlatformChatResponseError" - PlatformChatStreamResponseFailed: + description: Platform-generated request ID for support correlation. + PlatformSkillVersionCreateRequest: type: object additionalProperties: false required: - - type - - response_id - - response + - file properties: - type: + file: type: string - enum: - - RESPONSE_FAILED - response_id: - $ref: "#/components/schemas/PlatformChatStreamResponseId" - response: - $ref: "#/components/schemas/PlatformChatFailedResponse" - PlatformChatStreamEvent: - description: | - JSON object written to the SSE `data` field. This schema is the payload for SDK transform, not the raw HTTP body. Do not run JSON response conformance on stream bodies. A typical wire frame is: - id: 1 - event: RESPONSE_CREATED - data: {"type":"RESPONSE_CREATED","response_id":"resp_e65a0a77-97a2-4c91-be60-eae7f6238015"} - example: - type: RESPONSE_CREATED - response_id: resp_e65a0a77-97a2-4c91-be60-eae7f6238015 - oneOf: - - $ref: "#/components/schemas/PlatformChatStreamResponseCreated" - - $ref: "#/components/schemas/PlatformChatStreamProgress" - - $ref: "#/components/schemas/PlatformChatStreamOutputTextDelta" - - $ref: "#/components/schemas/PlatformChatStreamOutputTextDone" - - $ref: "#/components/schemas/PlatformChatStreamResponseCompleted" - - $ref: "#/components/schemas/PlatformChatStreamResponseFailed" - discriminator: - propertyName: type - mapping: - RESPONSE_CREATED: "#/components/schemas/PlatformChatStreamResponseCreated" - RESPONSE_PROGRESS: "#/components/schemas/PlatformChatStreamProgress" - RESPONSE_OUTPUT_TEXT_DELTA: "#/components/schemas/PlatformChatStreamOutputTextDelta" - RESPONSE_OUTPUT_TEXT_DONE: "#/components/schemas/PlatformChatStreamOutputTextDone" - RESPONSE_COMPLETED: "#/components/schemas/PlatformChatStreamResponseCompleted" - RESPONSE_FAILED: "#/components/schemas/PlatformChatStreamResponseFailed" - PlatformSkillStatus: - type: string - enum: - - DRAFT - - ENABLED - - DISABLED - description: Current skill status. - PlatformSkillOrigin: - type: string - enum: - - CUSTOM - description: Source category for the skill. - PlatformSkillSyncStatus: + format: binary + description: SKILL.md, .zip, or .skill bundle to store as a new version. + PlatformSkillVersionCreateResponse: + type: object + required: + - version + - request_id + properties: + version: + $ref: "#/components/schemas/PlatformSkillVersion" + request_id: + type: string + description: Platform-generated request ID for support correlation. + PlatformSkillVersionGetResponse: + type: object + required: + - version + - request_id + properties: + version: + $ref: "#/components/schemas/PlatformSkillVersion" + request_id: + type: string + description: Platform-generated request ID for support correlation. + PlatformFilterOperator: type: string + description: Supported filter operator. enum: - - UP_TO_DATE - - UPDATE_AVAILABLE - - SYNC_FAILED - description: Current external-source sync status. - PlatformSkillSourceProvenance: + - EQUALS + - NOT_EQUALS + - GT + - GTE + - LT + - LTE + PlatformFilter: type: object + additionalProperties: false + required: + - field + - values + description: | + A single filter criterion. For `EQUALS`, multiple values within a filter are OR'd; for `NOT_EQUALS`, listed values are excluded. Separate filters are AND'd with each other and with inline operators in `query`. Repeated same-field `EQUALS` filters are rejected. properties: - source_url: - type: string - description: URL of the external source the skill was imported from. - commit_sha: + field: type: string - description: Source commit SHA for the imported skill. - imported_at: + minLength: 1 + description: | + Filter field name. Built-in names (case-sensitive, lowercase only): `type`, `owner`, `from`, `author`, `channel`, `status`, `assignee`, `reporter`, `component`, `mentions`, and `collection`. Built-ins accept only `EQUALS` and `NOT_EQUALS`. Any other nonblank name is accepted as a custom filter without spelling, existence, or type checks; behavior depends on your connected sources. + example: type + values: + type: array + minItems: 1 + items: + type: string + minLength: 1 + description: | + One or more values to match. Prefer values returned by filter discovery unchanged. For people (`USER`) fields, values may be email addresses or display names. + example: + - spreadsheet + - presentation + operator: + allOf: + - $ref: "#/components/schemas/PlatformFilterOperator" + description: | + Comparison operator. Defaults to `EQUALS`. Built-in fields support only `EQUALS` and `NOT_EQUALS`. Range operators (`GT`, `GTE`, `LT`, `LTE`) require exactly one value; express ranges with multiple filters on the same field. Custom fields may support different operators depending on the data source. + PlatformTimeRange: + type: object + additionalProperties: false + description: Filter results to those last updated within this range. + properties: + start: type: string format: date-time - description: Time the skill was imported. - last_synced_at: + description: Inclusive lower bound in ISO 8601 format. + end: type: string format: date-time - description: Time the skill was last synced from its source. - sync_status: - $ref: "#/components/schemas/PlatformSkillSyncStatus" - sync_error: - type: string - description: Human-readable sync failure reason, present only when sync_status is SYNC_FAILED. - PlatformPersonReference: + description: Exclusive upper bound in ISO 8601 format. + PlatformSearchRequest: type: object - description: A lightweight reference to a person, used where a payload merely points at someone. + additionalProperties: false required: - - name - properties: - id: - type: string - description: Opaque Glean person ID. - name: + - query + example: + query: quarterly planning 2026 + properties: + query: type: string - description: Display name. - PlatformSkill: + minLength: 1 + description: | + The search query string. Supports inline operators such as `from:jane type:document app:confluence`. Inline operators are AND'd with structured `filters`. + page_size: + type: integer + minimum: 1 + maximum: 100 + default: 10 + description: Number of results to return per page. + cursor: + type: + - string + - "null" + description: | + Opaque pagination token from a previous response's `next_cursor` field. Omit on the first request. + datasources: + type: array + minItems: 1 + items: + type: string + minLength: 1 + description: | + Restrict results to specific datasource identifiers returned by `GET /api/search/filters`. Scopes by datasource type and may include results from multiple instances of that type. + filters: + type: array + minItems: 1 + items: + $ref: "#/components/schemas/PlatformFilter" + description: | + Structured filters applied to search results. Multiple values within a filter with `EQUALS` are OR'd; separate filters are AND'd. Conflicting constraints on the same field (for example, `type:document` in `query` and `type:spreadsheet` in a filter) return an empty result set. See `Filter.field` for built-in field names and operators. Other nonblank field names are accepted as custom filters without validation; behavior depends on your connected sources. + time_range: + $ref: "#/components/schemas/PlatformTimeRange" + PlatformResult: type: object + additionalProperties: false required: - - id - - display_name - - description - - latest_version - - latest_minor_version - - status - - origin - - owner - - created_at - - updated_at + - url + - title + - datasource properties: - id: + url: type: string - description: Glean skill ID. - display_name: + format: uri + minLength: 1 + description: Canonical URL of the result. + example: https://company.atlassian.net/wiki/spaces/ENG/pages/12345 + title: type: string - description: Human-readable skill name. - description: + minLength: 1 + description: Result title. + example: Q2 2026 Platform Roadmap + snippets: + type: array + items: + type: string + minLength: 1 + description: Query-relevant plain-text excerpts from the result body. + example: + - The platform team will focus on API stability and... + datasource: type: string - description: Human-readable skill description. - latest_version: - type: integer - description: Latest major version number for the skill. - latest_minor_version: - type: integer - description: Latest minor version number for the skill. - status: - $ref: "#/components/schemas/PlatformSkillStatus" - origin: - $ref: "#/components/schemas/PlatformSkillOrigin" - source_provenance: - $ref: "#/components/schemas/PlatformSkillSourceProvenance" + minLength: 1 + description: The datasource this result originates from. + example: confluence + document_type: + type: + - string + - "null" + minLength: 1 + description: The document type within the datasource. + example: page + creator: + $ref: "#/components/schemas/PlatformPersonReference" owner: $ref: "#/components/schemas/PlatformPersonReference" - created_at: - type: string - format: date-time - description: Time the skill was created. updated_at: - type: string + type: + - string + - "null" format: date-time - description: Time the skill was last updated. - PlatformSkillsListResponse: + description: When the result was last modified. + created_at: + type: + - string + - "null" + format: date-time + description: When the result was created. + PlatformSearchResponse: type: object + additionalProperties: false required: - - skills + - results - has_more - next_cursor - request_id + - warnings properties: - skills: + results: type: array - description: Skills available to the user. items: - $ref: "#/components/schemas/PlatformSkill" + $ref: "#/components/schemas/PlatformResult" + description: | + Ordered list of ranked document results. People cards, Q&A blocks, and other UI-only result types are not included. has_more: type: boolean - description: Whether additional results are available. + description: Indicates whether additional pages of results are available. next_cursor: type: - string - "null" - description: Cursor for the next page, or null when no more results are available. + description: Opaque token to pass as `cursor` in the next request. request_id: type: string + minLength: 1 description: Platform-generated request ID for support correlation. - PlatformSkillCreateRequest: + warnings: + type: array + description: | + Non-blocking warnings for this response. Required; use `[]` when there are none. Clients must tolerate unknown warning codes. `results_incomplete` means some results may be unavailable for the requested datasource scope while `results`, `has_more`, and `next_cursor` remain present. Warning messages are generic and do not include query text or internal identifiers. + items: + $ref: "#/components/schemas/PlatformWarning" + PlatformFilterFieldInfo: type: object additionalProperties: false required: - - file + - field + - type + - operators properties: - file: + field: type: string - format: binary - description: SKILL.md, .zip, or .skill bundle to create. - PlatformSkillCreateResponse: - type: object - required: - - skill - - request_id - properties: - skill: - $ref: "#/components/schemas/PlatformSkill" - request_id: + minLength: 1 + description: Field name usable in the `filters` array for `POST /api/search`. + example: status + type: type: string - description: Platform-generated request ID for support correlation. - PlatformSkillImportRequest: - type: object - additionalProperties: false - required: - - source_urls - example: - source_urls: - - https://github.com/anthropics/skills/tree/main/skills/skill-creator - properties: - source_urls: + minLength: 1 + description: | + Open field-type string. Current values are `STRING` for text and keyword fields and `USER` for people fields (`owner`, `from`, `author`, `assignee`, `reporter`, `mentions`). Clients must tolerate unknown values. + example: STRING + operators: type: array minItems: 1 - maxItems: 100 - uniqueItems: true - description: Resolved GitHub skill URLs selected from a source preview. + description: | + Comparison operators supported for this field. Built-in fields expose `EQUALS` and `NOT_EQUALS`. + items: + $ref: "#/components/schemas/PlatformFilterOperator" + values: + type: array + description: | + Suggested filter values observed for the supplied `query`. Omitted in catalog-only responses. Present as an array, including `[]`, when `query` is provided. Values are a bounded, non-exhaustive sample in search-provider order and may include duplicates; blank values are omitted. No additional endpoint-specific truncation is applied. Grouping in the search UI is not preserved; each value applies to the field broadly. An empty array does not mean no valid value exists. Availability varies by data source; federated and MCP integrations may return page-derived values or none at all. Reusing a suggested value in `POST /api/search` does not guarantee matching results or identical filter behavior. For `USER` fields, values may be email addresses or display names. items: type: string minLength: 1 - maxLength: 2048 - PlatformSkillImportResponse: + PlatformDatasourceFilterInfo: type: object + additionalProperties: false required: - - skills - - request_id + - datasource + - filters properties: - skills: + datasource: + type: string + minLength: 1 + description: | + Datasource identifier usable in `POST /api/search` `datasources`. + example: jira + filters: type: array - minItems: 1 - description: Independently persisted skills in request order. + description: | + Common built-in filter fields for this datasource. May be empty. A built-in omitted here can still be valid in `POST /api/search`; see `Filter.field` for the full built-in name list. items: - $ref: "#/components/schemas/PlatformSkill" - request_id: - type: string - description: Platform-generated request ID for support correlation. - PlatformSkillValidationRequest: + $ref: "#/components/schemas/PlatformFilterFieldInfo" + PlatformSearchFiltersResponse: type: object additionalProperties: false - required: - - file - properties: - file: - type: string - format: binary - description: SKILL.md, .zip, or .skill bundle to validate. - PlatformSkillValidationMetadata: - type: object - required: - - display_name - - description - properties: - display_name: - type: string - description: Skill name parsed from SKILL.md frontmatter. - description: - type: string - description: Skill description parsed from SKILL.md frontmatter. - PlatformSkillValidationFile: - type: object - required: - - path - - size_bytes - - is_manifest - properties: - path: - type: string - description: Normalized relative path in the skill bundle. - size_bytes: - type: integer - description: File size in bytes. - is_manifest: - type: boolean - description: Whether this file is the skill manifest. - PlatformSkillValidationResponse: - type: object - required: - - metadata - - files - - warnings + required: + - datasources - request_id properties: - metadata: - $ref: "#/components/schemas/PlatformSkillValidationMetadata" - files: - type: array - description: Normalized files in the bundle after stripping an optional single root folder. - items: - $ref: "#/components/schemas/PlatformSkillValidationFile" - warnings: + datasources: type: array - description: Non-blocking validation warnings. + description: | + Datasources visible to the authenticated user. Each `datasource` is an identifier you can pass to `POST /api/search` `datasources`. An empty array means no visible datasources. items: - $ref: "#/components/schemas/PlatformWarning" + $ref: "#/components/schemas/PlatformDatasourceFilterInfo" request_id: type: string + minLength: 1 description: Platform-generated request ID for support correlation. - PlatformSkillSourcePreviewRequest: + PlatformPerMemberSettings: type: object additionalProperties: false + description: Resolution settings for the per-member limit family. required: - - source_url - example: - source_url: https://github.com/anthropics/skills + - idp_groups properties: - source_url: + idp_groups: type: string - minLength: 1 - maxLength: 2048 - description: GitHub URL for a skill directory, SKILL.md file, or repository to inspect. - stream: - type: boolean - default: false - description: Whether to stream repository scan progress using server-sent events. - PlatformSkillSourcePreviewFile: + enum: + - HIGHEST + - LOWEST + description: | + How to resolve effective usage limits when a user belongs to multiple IdP groups. + PlatformMultipleMembershipResolutionSettings: type: object + additionalProperties: false + description: Settings for resolving limits across multiple memberships. required: - - path - - content + - per_member properties: - path: - type: string - description: Relative path within the skill bundle. - content: - type: string - description: UTF-8 file content. - PlatformSkillSourcePreview: + per_member: + $ref: "#/components/schemas/PlatformPerMemberSettings" + description: Resolution settings for the per-member limit family. + PlatformLimitIncreaseRequestSettings: type: object + additionalProperties: false + description: | + Settings that govern usage limit increase requests. required: - - display_name - - description - - source_url - - commit_sha - - main_content - - files - - file_tree + - business_justification properties: - display_name: - type: string - description: Skill name parsed from SKILL.md frontmatter. - description: - type: string - description: Skill description parsed from SKILL.md frontmatter. - source_url: - type: string - description: Resolved URL for this skill within the source. - commit_sha: - type: string - description: Commit SHA used to produce the preview. - main_content: + business_justification: type: string - description: SKILL.md content fetched as part of the preview. - files: - type: array - description: Supporting files fetched with the skill. - items: - $ref: "#/components/schemas/PlatformSkillSourcePreviewFile" - file_tree: - type: array - description: Relative paths discovered for the skill. - items: - type: string - PlatformSkillSourcePreviewFailureCode: - type: string - enum: - - INVALID_SKILL - - SKILL_FETCH_FAILED - description: Stable machine-readable reason a discovered entry was excluded. - PlatformSkillSourcePreviewFailure: + enum: + - OPTIONAL + - REQUIRED + description: | + Whether a business justification is required when requesting a usage limit increase. + PlatformUsageSettingsResource: type: object - required: - - source_url - - code - - detail - properties: - source_url: - type: string - description: Resolved URL for the entry that could not be previewed. - code: - $ref: "#/components/schemas/PlatformSkillSourcePreviewFailureCode" - detail: + additionalProperties: false + description: | + Workspace-wide usage settings. + properties: + multiple_membership_resolution: + $ref: "#/components/schemas/PlatformMultipleMembershipResolutionSettings" + description: Settings for resolving limits across multiple memberships. + limit_increase_requests: + $ref: "#/components/schemas/PlatformLimitIncreaseRequestSettings" + description: Settings that govern usage limit increase requests. + updated_at: type: string - description: Safe explanation of why the entry was excluded. - PlatformSkillSourcePreviewResponse: + format: date-time + description: | + ISO 8601 timestamp of the last settings update. + PlatformUsageSettingsResponse: type: object + additionalProperties: false + description: | + Response envelope for usage settings operations. required: - - skills - - failures + - usage_settings - request_id properties: - skills: - type: array - minItems: 1 - description: Valid skills discovered at the source URL. - items: - $ref: "#/components/schemas/PlatformSkillSourcePreview" - failures: - type: array - description: Discovered entries that could not be included in the preview. - items: - $ref: "#/components/schemas/PlatformSkillSourcePreviewFailure" + usage_settings: + $ref: "#/components/schemas/PlatformUsageSettingsResource" + description: Current workspace-wide usage settings. request_id: type: string - description: Platform-generated request ID for support correlation. - PlatformSkillGetResponse: + description: | + Opaque request identifier. + PlatformUsageSettingsUpdateRequest: + type: object + additionalProperties: false + description: | + Request body for updating workspace-wide usage settings. + required: [] + anyOf: + - required: + - multiple_membership_resolution + - required: + - limit_increase_requests + properties: + multiple_membership_resolution: + $ref: "#/components/schemas/PlatformMultipleMembershipResolutionSettings" + description: Settings for resolving limits across multiple memberships. + limit_increase_requests: + $ref: "#/components/schemas/PlatformLimitIncreaseRequestSettings" + description: Settings that govern usage limit increase requests. + PlatformUsageTargetType: + type: string + description: Kind of governed population or inherited policy source. + enum: + - ORGANIZATION + - DEFAULT_USER + - DEFAULT_AGENT + - USER + - AGENT + - IDP_GROUP + - DEPARTMENT + x-enumDescriptions: + ORGANIZATION: Shared limit across the organization for the selected spend client. + DEFAULT_USER: Default per-user limit for the selected spend client. + DEFAULT_AGENT: Default aggregate limit applied to agents without an agent-specific limit. + USER: Limit for one user, identified by canonical user ID or email, and the selected spend client. + AGENT: Aggregate limit for one canonical agent ID, independent of spend client. + IDP_GROUP: Response-only source of an inherited per-user IdP-group limit. + DEPARTMENT: Response-only source of an inherited per-user department limit. + x-speakeasy-enum-descriptions: + ORGANIZATION: Shared limit across the organization for the selected spend client. + DEFAULT_USER: Default per-user limit for the selected spend client. + DEFAULT_AGENT: Default aggregate limit applied to agents without an agent-specific limit. + USER: Limit for one user, identified by canonical user ID or email, and the selected spend client. + AGENT: Aggregate limit for one canonical agent ID, independent of spend client. + IDP_GROUP: Response-only source of an inherited per-user IdP-group limit. + DEPARTMENT: Response-only source of an inherited per-user department limit. + PlatformUsageTarget: type: object + description: | + Population governed by a usage limit. A target identifies policy, not access. Administrative operations require their dedicated scope and billing permissions. Non-admin evaluation accepts the authenticated USER or an AGENT the caller currently has permission to edit. Billing permission does not widen this route. Organization and user limits are scoped to a spend client; agent limits remain aggregate. Subagents cannot be configured or evaluated independently because nested spend can be attributed to the top-level agent. Reset can still remove existing subagent rules. A USER target is identified by user_id, email, or both; email is resolved to the canonical user_id, which responses always return. + additionalProperties: false required: - - skill - - request_id + - type properties: - skill: - $ref: "#/components/schemas/PlatformSkill" - request_id: + type: + $ref: "#/components/schemas/PlatformUsageTargetType" + description: Kind of governed population. + user_id: type: string - description: Platform-generated request ID for support correlation. - PlatformSkillUpdateStatus: + minLength: 1 + maxLength: 512 + description: | + Canonical user ID; valid only when type is USER. A USER target requires user_id, email, or both. + email: + type: string + minLength: 3 + maxLength: 320 + pattern: ^[^\s@\x00-\x1f\x7f]+@[^\s@\x00-\x1f\x7f]+$ + x-glean-experimental: + id: 1e7ce9ed-56af-44b2-81c1-f39e656919ea + introduced: "2026-09-29" + description: | + Email address of the user, including a known alias email; valid only when type is USER. Matching is case-insensitive and resolves to the canonical user_id. When user_id is also supplied, both must identify the same user. Email is never part of the stored limit key. Responses include the user's directory email when one is available. + agent_id: + type: string + minLength: 1 + maxLength: 512 + description: Canonical agent ID; required only when type is AGENT. + allOf: + - oneOf: + - anyOf: + - required: + - user_id + - required: + - email + properties: + type: + description: Kind of governed population. + enum: + - USER + not: + required: + - agent_id + - required: + - agent_id + properties: + type: + description: Kind of governed population. + enum: + - AGENT + not: + anyOf: + - required: + - user_id + - required: + - email + - properties: + type: + description: Kind of governed population. + enum: + - ORGANIZATION + - DEFAULT_USER + - DEFAULT_AGENT + not: + anyOf: + - required: + - user_id + - required: + - email + - required: + - agent_id + PlatformPeriodType: type: string + description: Kind of period over which usage is counted. enum: - - ENABLED - - DISABLED - description: New status for the skill. - PlatformSkillUpdateRequest: + - RECURRING_CALENDAR_MONTH + x-enumDescriptions: + RECURRING_CALENDAR_MONTH: Resets at the start of each calendar month. + x-speakeasy-enum-descriptions: + RECURRING_CALENDAR_MONTH: Resets at the start of each calendar month. + PlatformPeriod: type: object + description: Period over which usage is counted for a limit. additionalProperties: false required: - - status - example: - status: ENABLED + - type properties: - status: - $ref: "#/components/schemas/PlatformSkillUpdateStatus" - PlatformSkillUpdateResponse: + type: + $ref: "#/components/schemas/PlatformPeriodType" + description: Kind of usage period. + PlatformUsageSelector: type: object + description: | + Usage counted against a configured limit, or the spend context for evaluation. Configured organization and user limits require a client; aggregate agent limits omit it. Omission never selects Glean or acts as a client wildcard. + additionalProperties: false required: - - skill - - request_id + - period properties: - skill: - $ref: "#/components/schemas/PlatformSkill" - request_id: + client_id: type: string - description: Platform-generated request ID for support correlation. - PlatformSkillSyncResultStatus: + x-glean-experimental: + id: 3a8dfb97-fbe9-4173-ac61-4fd6e6faa847 + introduced: "2026-09-23" + minLength: 1 + maxLength: 256 + pattern: ^[^\x00-\x1f\x7f]+$ + not: + enum: + - __deleted_clients__ + description: | + Opaque spend-client ID, such as glean or an external gateway spend-client ID. This is not inferred from the authenticating OAuth application and is not automatically prefixed or normalized. Synthetic UI aggregation IDs and control characters are not valid spend-client IDs. + period: + $ref: "#/components/schemas/PlatformPeriod" + description: Reset cadence for counted usage. + PlatformAllocationMode: type: string + description: How a usage limit budget is shared across the target population. enum: - - UP_TO_DATE - description: Synchronization status after a successful refresh. - PlatformSkillSyncResponse: + - SHARED_POOL + - PER_MEMBER + x-enumDescriptions: + SHARED_POOL: A single shared budget for the target population. + PER_MEMBER: A separate budget for each member of the target population. + x-speakeasy-enum-descriptions: + SHARED_POOL: A single shared budget for the target population. + PER_MEMBER: A separate budget for each member of the target population. + PlatformAmountMode: + type: string + description: Kind of value a usage limit carries. + enum: + - FINITE + - UNLIMITED + x-enumDescriptions: + FINITE: A finite cap; amount is required. + UNLIMITED: No cap. + x-speakeasy-enum-descriptions: + FINITE: A finite cap; amount is required. + UNLIMITED: No cap. + PlatformUsageUnit: + type: string + description: Unit used by a usage limit and its counters. + enum: + - USD + - CREDITS + x-enumDescriptions: + USD: United States dollars. + CREDITS: Glean usage credits. + x-speakeasy-enum-descriptions: + USD: United States dollars. + CREDITS: Glean usage credits. + PlatformEnforcement: + type: string + description: Enforcement behavior when a usage limit is reached. + enum: + - HARD + - SOFT + x-enumDescriptions: + HARD: Configured hard cap; when enforced, requests are blocked at the limit. + SOFT: Configured soft cap; when enforced, requests are allowed but flagged at the limit. + x-speakeasy-enum-descriptions: + HARD: Configured hard cap; when enforced, requests are blocked at the limit. + SOFT: Configured soft cap; when enforced, requests are allowed but flagged at the limit. + PlatformUsageLimitValue: type: object + description: Value and enforcement configuration for a usage limit. + additionalProperties: false required: - - sync_status - - commit_sha - - updated - - request_id + - mode properties: - sync_status: - $ref: "#/components/schemas/PlatformSkillSyncResultStatus" - commit_sha: + mode: + $ref: "#/components/schemas/PlatformAmountMode" + description: Whether the limit has a finite cap or is unlimited. + amount: type: string minLength: 1 - description: Git commit SHA now associated with the skill. - updated: - type: boolean - description: Whether this request created a new skill version. - request_id: - type: string - description: Platform-generated request ID for support correlation. - PlatformSkillVersion: - type: object + maxLength: 24 + pattern: ^(0|[1-9][0-9]*)(\.[0-9]{1,6})?$ + description: | + Plain non-negative decimal amount with at most six fractional digits; required when mode is FINITE and forbidden when mode is UNLIMITED. Limits use single-precision (float32) storage: inputs are rounded to that precision, and responses report the stored value rounded to six fractional digits. For example, 100.10 can be returned as 100.099998. This storage limitation does not reduce the precision of measured usage counters. + unit: + $ref: "#/components/schemas/PlatformUsageUnit" + description: | + Unit for the selected spend domain; must match its billing denomination. Aggregate agent limits use the workspace plan denomination. + enforcement: + $ref: "#/components/schemas/PlatformEnforcement" + description: How the limit is enforced when reached. + allOf: + - oneOf: + - required: + - amount + - unit + - enforcement + properties: + mode: + description: Whether the limit has a finite cap or is unlimited. + enum: + - FINITE + - properties: + mode: + description: Whether the limit has a finite cap or is unlimited. + enum: + - UNLIMITED + not: + anyOf: + - required: + - amount + - required: + - unit + - required: + - enforcement + PlatformUsageLimit: + type: object + description: A configured usage limit and its value. + additionalProperties: false required: - - skill_id - - version - - minor_version - - is_latest - - created_by - - created_at - - updated_at + - target + - usage_selector + - value properties: - skill_id: - type: string - description: Glean skill ID. - version: - type: integer - description: Major version number. - minor_version: - type: integer - description: Minor version number. - is_latest: - type: boolean - description: Whether this is the latest version of the skill. - created_by: - $ref: "#/components/schemas/PlatformPersonReference" - created_at: - type: string - format: date-time - description: Time this version was created. - updated_at: - type: string - format: date-time - description: Time this version was last updated. - source_provenance: - $ref: "#/components/schemas/PlatformSkillSourceProvenance" - PlatformSkillVersionsListResponse: - type: object + target: + $ref: "#/components/schemas/PlatformUsageTarget" + description: Population governed by this limit. + usage_selector: + $ref: "#/components/schemas/PlatformUsageSelector" + description: Usage counted against this limit. + allocation_mode: + $ref: "#/components/schemas/PlatformAllocationMode" + description: | + Required for ORGANIZATION, DEFAULT_USER, and DEFAULT_AGENT. Must not be provided for USER or AGENT targets. + value: + $ref: "#/components/schemas/PlatformUsageLimitValue" + description: Value, unit, and enforcement mode for the limit. + allOf: + - oneOf: + - required: + - allocation_mode + properties: + target: + description: Population governed by this limit. + properties: + type: + description: Kind of governed population. + enum: + - ORGANIZATION + allocation_mode: + description: How this limit budget is allocated. + enum: + - SHARED_POOL + - required: + - allocation_mode + properties: + target: + description: Population governed by this limit. + properties: + type: + description: Kind of governed population. + enum: + - DEFAULT_USER + - DEFAULT_AGENT + allocation_mode: + description: How this limit budget is allocated. + enum: + - PER_MEMBER + - properties: + target: + description: Population governed by this limit. + properties: + type: + description: Kind of governed population. + enum: + - USER + - AGENT + not: + required: + - allocation_mode + - oneOf: + - properties: + target: + description: Population governed by this client-scoped limit. + properties: + type: + description: Kind of client-scoped population. + enum: + - ORGANIZATION + - DEFAULT_USER + - USER + usage_selector: + description: Spend client and period for this limit. + required: + - client_id + - properties: + target: + description: Population governed by this aggregate agent limit. + properties: + type: + description: Kind of aggregate agent population. + enum: + - DEFAULT_AGENT + - AGENT + usage_selector: + description: Aggregate period without a client partition. + not: + required: + - client_id + PlatformListUsageLimitsResponse: + type: object + description: Response body for listing configured usage limits. + additionalProperties: false required: - - versions + - results - has_more - - next_cursor - request_id properties: - versions: + results: type: array - description: Versions available for the skill. + description: | + Bounded page of configured limits. Denomination and legacy-fallback filtering can produce a short or empty page; continue with next_cursor while has_more is true. items: - $ref: "#/components/schemas/PlatformSkillVersion" + $ref: "#/components/schemas/PlatformUsageLimit" has_more: type: boolean - description: Whether additional results are available. + description: Whether additional results are available after this page. next_cursor: type: - string - "null" - description: Cursor for the next page, or null when no more results are available. + description: Opaque cursor; null or absent when has_more is false. request_id: type: string - description: Platform-generated request ID for support correlation. - PlatformSkillVersionCreateRequest: + description: Request identifier for correlating this response. + PlatformUpsertUsageLimitResponse: type: object + description: Response envelope for an upserted usage limit. additionalProperties: false required: - - file + - usage_limit + - request_id properties: - file: + usage_limit: + $ref: "#/components/schemas/PlatformUsageLimit" + description: The normalized usage limit. + request_id: type: string - format: binary - description: SKILL.md, .zip, or .skill bundle to store as a new version. - PlatformSkillVersionCreateResponse: + description: Request identifier for correlating this response. + PlatformUsageLimitKey: type: object + description: Natural key for one configured usage limit. + additionalProperties: false required: - - version + - target + - usage_selector + properties: + target: + $ref: "#/components/schemas/PlatformUsageTarget" + description: Population governed by the limit. + usage_selector: + $ref: "#/components/schemas/PlatformUsageSelector" + description: Usage counted against the limit. + allOf: + - oneOf: + - properties: + target: + description: Population governed by this client-scoped limit. + properties: + type: + description: Kind of client-scoped population. + enum: + - ORGANIZATION + - DEFAULT_USER + - USER + usage_selector: + description: Spend client and period for this limit. + required: + - client_id + - properties: + target: + description: Population governed by this aggregate agent limit. + properties: + type: + description: Kind of aggregate agent population. + enum: + - DEFAULT_AGENT + - AGENT + usage_selector: + description: Aggregate period without a client partition. + not: + required: + - client_id + PlatformResetUsageLimitsResponse: + type: object + description: Response body for resetting a usage limit. + additionalProperties: false + required: + - is_configuration_removed - request_id properties: - version: - $ref: "#/components/schemas/PlatformSkillVersion" + is_configuration_removed: + type: boolean + description: Whether the matching usage limit configuration was removed. request_id: type: string - description: Platform-generated request ID for support correlation. - PlatformSkillVersionGetResponse: + description: Request identifier for correlating this response. + PlatformBatchUsageLimitsResponse: type: object + additionalProperties: false + description: Response body for successfully applied usage limit policies. required: - - version + - results - request_id properties: - version: - $ref: "#/components/schemas/PlatformSkillVersion" + results: + type: array + items: + $ref: "#/components/schemas/PlatformUsageLimit" + description: Applied usage limit policies, in the same order as the request. request_id: type: string - description: Platform-generated request ID for support correlation. - PlatformFilterOperator: + description: Request identifier for correlating this response. + PlatformEvaluateUsageLimitRequest: + type: object + additionalProperties: false + description: | + Administrative evaluation request. The target is always explicit; usage_selector and the evaluation response are shared with non-admin evaluation. + required: + - target + - usage_selector + properties: + target: + $ref: "#/components/schemas/PlatformUsageTarget" + description: Concrete organization, user, or agent to evaluate. + usage_selector: + $ref: "#/components/schemas/PlatformUsageSelector" + description: Usage to evaluate for the target. + allOf: + - properties: + usage_selector: + description: Explicit spend-client context for evaluation. + required: + - client_id + target: + description: Concrete target being evaluated. + properties: + type: + description: Kind of target being evaluated. + enum: + - ORGANIZATION + - USER + - AGENT + PlatformUsageLimitDecision: type: string - description: Supported filter operator. + description: Configured-budget status for the target, independent of runtime admission switches. enum: - - EQUALS - - NOT_EQUALS - - GT - - GTE - - LT - - LTE - PlatformFilter: + - AVAILABLE + - WARNING + - BLOCKED + x-enumDescriptions: + AVAILABLE: Usage is within all applicable configured limits. + WARNING: Usage reached or exceeded a configured soft limit. + BLOCKED: Usage reached or exceeded a configured hard limit; this is not a runtime admission decision. + x-speakeasy-enum-descriptions: + AVAILABLE: Usage is within all applicable configured limits. + WARNING: Usage reached or exceeded a configured soft limit. + BLOCKED: Usage reached or exceeded a configured hard limit; this is not a runtime admission decision. + PlatformUsagePolicySourceTarget: type: object + description: | + Population that supplied an evaluated policy. IdP groups and departments are response-only sources, not limit-management or direct evaluation targets. additionalProperties: false required: - - field - - values - description: | - A single filter criterion. For `EQUALS`, multiple values within a filter are OR'd; for `NOT_EQUALS`, listed values are excluded. Separate filters are AND'd with each other and with inline operators in `query`. Repeated same-field `EQUALS` filters are rejected. + - type properties: - field: + type: + $ref: "#/components/schemas/PlatformUsageTargetType" + description: Kind of configured policy source. + user_id: + type: string + minLength: 1 + description: Canonical user ID for a user-specific policy. + email: type: string minLength: 1 + x-glean-experimental: + id: 618d5192-fb51-451f-ba79-51304a408b55 + introduced: "2026-09-29" description: | - Filter field name. Built-in names (case-sensitive, lowercase only): `type`, `owner`, `from`, `author`, `channel`, `status`, `assignee`, `reporter`, `component`, `mentions`, and `collection`. Built-ins accept only `EQUALS` and `NOT_EQUALS`. Any other nonblank name is accepted as a custom filter without spelling, existence, or type checks; behavior depends on your connected sources. - example: type - values: - type: array - minItems: 1 - items: - type: string - minLength: 1 + Directory email of the user for a user-specific policy; omitted when the directory has no email for the user. + agent_id: + type: string + minLength: 1 + description: Canonical agent ID for an agent-specific policy. + group_id: + type: string + minLength: 1 + description: Canonical IdP group ID; returned only to billing readers. + department_name: + type: string + minLength: 1 + description: Department whose per-user policy supplied the limit. + is_identity_restricted: + type: boolean + description: True when an IdP-group source identity is withheld from a non-billing reader. + allOf: + - oneOf: + - properties: + type: + description: Organization or inherited default policy. + enum: + - ORGANIZATION + - DEFAULT_USER + - DEFAULT_AGENT + not: + anyOf: + - required: + - user_id + - required: + - email + - required: + - agent_id + - required: + - group_id + - required: + - department_name + - required: + - is_identity_restricted + - required: + - user_id + properties: + type: + description: User-specific policy. + enum: + - USER + not: + anyOf: + - required: + - agent_id + - required: + - group_id + - required: + - department_name + - required: + - is_identity_restricted + - required: + - agent_id + properties: + type: + description: Agent-specific policy. + enum: + - AGENT + not: + anyOf: + - required: + - user_id + - required: + - email + - required: + - group_id + - required: + - department_name + - required: + - is_identity_restricted + - required: + - department_name + properties: + type: + description: Inherited department policy. + enum: + - DEPARTMENT + not: + anyOf: + - required: + - user_id + - required: + - email + - required: + - agent_id + - required: + - group_id + - required: + - is_identity_restricted + - properties: + type: + description: Inherited IdP-group policy. + enum: + - IDP_GROUP + not: + anyOf: + - required: + - user_id + - required: + - email + - required: + - agent_id + - required: + - department_name + oneOf: + - required: + - group_id + properties: + is_identity_restricted: + description: An identified group is not restricted. + const: false + - required: + - is_identity_restricted + properties: + is_identity_restricted: + description: An unidentified group has a restricted identity. + const: true + not: + required: + - group_id + PlatformEvaluatedLimit: + type: object + additionalProperties: false + description: Evaluation details for one independently applicable usage limit. + required: + - target + - usage_selector + - value + - used + - decision + properties: + target: + $ref: "#/components/schemas/PlatformUsagePolicySourceTarget" description: | - One or more values to match. Prefer values returned by filter discovery unchanged. For people (`USER`) fields, values may be email addresses or display names. - example: - - spreadsheet - - presentation - operator: - allOf: - - $ref: "#/components/schemas/PlatformFilterOperator" + Configured source of this limit. Default and group policies retain their source population; used is the concrete evaluated user's or agent's counter. IdP-group identities require billing-read permission, but all callers receive the complete limit value, counter, decision, and headroom. + usage_selector: + $ref: "#/components/schemas/PlatformUsageSelector" description: | - Comparison operator. Defaults to `EQUALS`. Built-in fields support only `EQUALS` and `NOT_EQUALS`. Range operators (`GT`, `GTE`, `LT`, `LTE`) require exactly one value; express ranges with multiple filters on the same field. Custom fields may support different operators depending on the data source. - PlatformTimeRange: + Actual scope of this rule's counter. Client rules identify their client; aggregate agent rules omit client_id even when evaluation selects a client. + value: + $ref: "#/components/schemas/PlatformUsageLimitValue" + description: The configured limit value. + used: + type: string + description: Decimal amount of accrued usage for this limit. + decision: + $ref: "#/components/schemas/PlatformUsageLimitDecision" + description: Decision for this limit. + PlatformEvaluateUsageLimitResponse: type: object additionalProperties: false - description: Filter results to those last updated within this range. + description: Result of evaluating usage limits for a selector. + required: + - decision + - effective_limits + - evaluated_limits + - evaluated_at + - request_id properties: - start: + decision: + $ref: "#/components/schemas/PlatformUsageLimitDecision" + description: Overall decision across all evaluated limits. + effective_limits: + type: array + minItems: 1 + maxItems: 2 + items: + $ref: "#/components/schemas/PlatformUsageLimitValue" + description: | + One finite headroom per applicable unit, ordered USD then CREDITS. Headroom is the tightest remaining amount within that unit; different units are never combined or converted. When no finite limit applies, contains a single UNLIMITED value without amount, unit, or enforcement. + evaluated_limits: + type: array + items: + $ref: "#/components/schemas/PlatformEvaluatedLimit" + description: Per-rule evaluation details. + evaluated_at: type: string format: date-time - description: Inclusive lower bound in ISO 8601 format. - end: + description: ISO 8601 timestamp of when usage counters were read. + request_id: type: string - format: date-time - description: Exclusive upper bound in ISO 8601 format. - PlatformSearchRequest: + description: Request identifier for correlating this response. + PlatformEvaluateCallerUsageLimitRequest: type: object additionalProperties: false + description: | + Non-admin evaluation request. Only omission of target selects the authenticated canonical user; null, empty, and incomplete targets are invalid. Explicit USER targets accept the caller's canonical ID, known alias IDs, email, or known alias emails; every supplied field must identify the caller. AGENT targets require current edit permission and evaluate aggregate agent usage, including organization limits. The authenticated identity is never replaced by the selected target. required: - - query - example: - query: quarterly planning 2026 + - usage_selector properties: - query: + target: + $ref: "#/components/schemas/PlatformUsageTarget" + description: Optional self or editable agent target. Omit to evaluate self. + usage_selector: + $ref: "#/components/schemas/PlatformUsageSelector" + description: Usage to evaluate for the target; always required. + allOf: + - properties: + usage_selector: + description: Explicit spend-client context; never inferred from the caller. + required: + - client_id + PlatformRequestStatus: + type: string + enum: + - PENDING + - APPROVED + - DENIED + description: Stored request state. + PlatformRequestFilter: + type: object + additionalProperties: false + required: + - field + - values + description: A status filter using the backend's status-IN matching. + properties: + field: type: string - minLength: 1 - description: | - The search query string. Supports inline operators such as `from:jane type:document app:confluence`. Inline operators are AND'd with structured `filters`. - page_size: - type: integer - minimum: 1 - maximum: 100 - default: 10 - description: Number of results to return per page. - cursor: - type: - - string - - "null" - description: | - Opaque pagination token from a previous response's `next_cursor` field. Omit on the first request. - datasources: - type: array - minItems: 1 - items: - type: string - minLength: 1 - description: | - Restrict results to specific datasource identifiers returned by `GET /api/search/filters`. Scopes by datasource type and may include results from multiple instances of that type. - filters: + pattern: ^status$ + description: Allowed field is status, spelled exactly in lowercase. + values: type: array minItems: 1 + description: Status values to match with OR. items: - $ref: "#/components/schemas/PlatformFilter" - description: | - Structured filters applied to search results. Multiple values within a filter with `EQUALS` are OR'd; separate filters are AND'd. Conflicting constraints on the same field (for example, `type:document` in `query` and `type:spreadsheet` in a filter) return an empty result set. See `Filter.field` for built-in field names and operators. Other nonblank field names are accepted as custom filters without validation; behavior depends on your connected sources. - time_range: - $ref: "#/components/schemas/PlatformTimeRange" - PlatformResult: + $ref: "#/components/schemas/PlatformRequestStatus" + description: One supported request status. + operator: + allOf: + - $ref: "#/components/schemas/PlatformFilterOperator" + description: Canonical Platform filter operator. + enum: + - EQUALS + default: EQUALS + description: Only EQUALS is supported; defaults to EQUALS when omitted. + PlatformRequestPeriod: + type: string + pattern: ^[0-9]{4}-(0[1-9]|1[0-2])$ + description: UTC calendar month in YYYY-MM format, assigned by the server at creation. + PlatformApprovedIncreaseAmount: + type: string + pattern: ^([1-9][0-9]*(\.[0-9]+)?|0\.[0-9]*[1-9][0-9]*)$ + description: | + Positive additive increase in the applicable rule's denomination, encoded as a plain decimal string. The backend stores float32 values, not arbitrary-precision decimals. + PlatformRequestScope: + type: string + enum: + - PERIOD + - ONGOING + description: Increase for the stored request month or an ongoing standing-rule increase. + PlatformRequestResolutionTarget: + type: string + enum: + - USER + - ALL + - DEPARTMENT + - GROUP + description: Breadth of the approved increase; GROUP identifies an IdP group. + PlatformLimitIncreaseRequest: type: object additionalProperties: false required: - - url - - title - - datasource + - request_id + - entity_type + - entity_id + - client_id + - requester_user_id + - period + - status + - created_at + description: Stored user or agent request, with optional resolution fields when available. properties: - url: + request_id: type: string - format: uri - minLength: 1 - description: Canonical URL of the result. - example: https://company.atlassian.net/wiki/spaces/ENG/pages/12345 - title: + description: Server-assigned resource identifier, distinct from the response's trace request_id. + entity_type: type: string - minLength: 1 - description: Result title. - example: Q2 2026 Platform Roadmap - snippets: - type: array - items: - type: string - minLength: 1 - description: Query-relevant plain-text excerpts from the result body. - example: - - The platform team will focus on API stability and... - datasource: + enum: + - USER + - AGENT + description: Whether the request concerns a user or an agent. + entity_id: + type: string + description: Canonical user ID or agent ID whose limit the request concerns. + client_id: + type: string + description: Spend client for this user or agent request. + requester_user_id: + type: string + description: Authenticated user who created the request. + business_justification: + type: string + description: Stored explanation of why the increase is needed, when supplied. + period: + $ref: "#/components/schemas/PlatformRequestPeriod" + description: Stored request month; resolution does not change this month. + status: + $ref: "#/components/schemas/PlatformRequestStatus" + description: Current stored request state. + resolved_by_user_id: + type: string + description: User who resolved the request, when available. + approved_increase_amount: + $ref: "#/components/schemas/PlatformApprovedIncreaseAmount" + description: Stored additive approval amount, when available. + scope: + $ref: "#/components/schemas/PlatformRequestScope" + description: Approval scope derived from the stored ongoing flag, when available. + resolution_target: + $ref: "#/components/schemas/PlatformRequestResolutionTarget" + description: Stored approval breadth, when available. + resolution_target_id: type: string - minLength: 1 - description: The datasource this result originates from. - example: confluence - document_type: - type: - - string - - "null" - minLength: 1 - description: The document type within the datasource. - example: page - creator: - $ref: "#/components/schemas/PlatformPersonReference" - owner: - $ref: "#/components/schemas/PlatformPersonReference" - updated_at: - type: - - string - - "null" - format: date-time - description: When the result was last modified. + description: Stored department or canonical IdP group ID, when available. + resolution_note: + type: string + description: Stored denial note, when supplied. created_at: - type: - - string - - "null" + type: string format: date-time - description: When the result was created. - PlatformSearchResponse: + description: Request creation time. + updated_at: + type: string + format: date-time + description: Last stored update time; this is the resolution time for resolved requests. + PlatformRequestListResponse: type: object additionalProperties: false + description: Bounded page of authorized requests with opaque continuation state. required: - results - has_more - - next_cursor - request_id - - warnings properties: results: type: array + description: Requests visible to the caller under the current filters and authorization. items: - $ref: "#/components/schemas/PlatformResult" - description: | - Ordered list of ranked document results. People cards, Q&A blocks, and other UI-only result types are not included. + $ref: "#/components/schemas/PlatformLimitIncreaseRequest" + description: One authorized request in the page. has_more: type: boolean - description: Indicates whether additional pages of results are available. + description: Whether a further page is available through next_cursor. next_cursor: type: - string - "null" - description: Opaque token to pass as `cursor` in the next request. + description: Opaque nonempty continuation when has_more is true; null or omitted otherwise. request_id: type: string - minLength: 1 - description: Platform-generated request ID for support correlation. - warnings: - type: array - description: | - Non-blocking warnings for this response. Required; use `[]` when there are none. Clients must tolerate unknown warning codes. `results_incomplete` means some results may be unavailable for the requested datasource scope while `results`, `has_more`, and `next_cursor` remain present. Warning messages are generic and do not include query text or internal identifiers. - items: - $ref: "#/components/schemas/PlatformWarning" - PlatformFilterFieldInfo: + description: Trace identifier for this list response, not a request resource ID. + allOf: + - description: Continuation availability must agree with the cursor. + oneOf: + - description: A further page requires a usable continuation cursor. + required: + - next_cursor + properties: + has_more: + type: boolean + description: Further-page discriminator. + enum: + - true + next_cursor: + type: string + description: Opaque nonempty cursor for the next authorized page. + minLength: 1 + - description: The last page has no continuation cursor. + properties: + has_more: + type: boolean + description: Last-page discriminator. + enum: + - false + next_cursor: + type: "null" + description: If present on the last page, the cursor must be null. + PlatformPersonalRequestCreate: type: object additionalProperties: false required: - - field - - type - - operators + - client_id + description: New request for the authenticated canonical user in the server's current UTC month. properties: - field: + client_id: type: string minLength: 1 - description: Field name usable in the `filters` array for `POST /api/search`. - example: status - type: + description: Explicit spend client whose limit the request concerns. + business_justification: type: string - minLength: 1 - description: | - Open field-type string. Current values are `STRING` for text and keyword fields and `USER` for people fields (`owner`, `from`, `author`, `assignee`, `reporter`, `mentions`). Clients must tolerate unknown values. - example: STRING - operators: - type: array - minItems: 1 - description: | - Comparison operators supported for this field. Built-in fields expose `EQUALS` and `NOT_EQUALS`. - items: - $ref: "#/components/schemas/PlatformFilterOperator" - values: - type: array - description: | - Suggested filter values observed for the supplied `query`. Omitted in catalog-only responses. Present as an array, including `[]`, when `query` is provided. Values are a bounded, non-exhaustive sample in search-provider order and may include duplicates; blank values are omitted. No additional endpoint-specific truncation is applied. Grouping in the search UI is not preserved; each value applies to the field broadly. An empty array does not mean no valid value exists. Availability varies by data source; federated and MCP integrations may return page-derived values or none at all. Reusing a suggested value in `POST /api/search` does not guarantee matching results or identical filter behavior. For `USER` fields, values may be email addresses or display names. - items: - type: string - minLength: 1 - PlatformDatasourceFilterInfo: + description: Optional explanation of why the increase is needed. + PlatformRequestResponse: type: object additionalProperties: false + description: Single authorized request with the enclosing response's trace identifier. required: - - datasource - - filters + - request + - request_id properties: - datasource: + request: + $ref: "#/components/schemas/PlatformLimitIncreaseRequest" + description: Authorized request at its current stored state. + request_id: + type: string + description: Trace identifier, distinct from the resource ID. + PlatformAgentRequestCreate: + type: object + additionalProperties: false + required: + - agent_id + - client_id + description: New client-scoped request for an editable agent in the server's current UTC month. + properties: + agent_id: type: string minLength: 1 - description: | - Datasource identifier usable in `POST /api/search` `datasources`. - example: jira - filters: - type: array - description: | - Common built-in filter fields for this datasource. May be empty. A built-in omitted here can still be valid in `POST /api/search`; see `Filter.field` for the full built-in name list. - items: - $ref: "#/components/schemas/PlatformFilterFieldInfo" - PlatformSearchFiltersResponse: + maxLength: 256 + description: Identifier of the agent whose limit the request concerns. + client_id: + type: string + minLength: 1 + description: Explicit spend client whose limit the request concerns. + business_justification: + type: string + description: Optional explanation of why the increase is needed. + PlatformAdministrativeRequestUpdate: type: object additionalProperties: false required: - - datasources - - request_id + - status + description: | + Resolve a pending request. Approval adds to the applicable limit; it does not replace the limit with an absolute value. Request identity and period cannot change. properties: - datasources: - type: array + status: + type: string + enum: + - APPROVED + - DENIED + description: Requested terminal state. + approved_increase_amount: + $ref: "#/components/schemas/PlatformApprovedIncreaseAmount" + description: Positive additive increase, required only for approval. + scope: + $ref: "#/components/schemas/PlatformRequestScope" + default: PERIOD + description: Approval scope; omission selects PERIOD. ONGOING is unsupported for agents. + resolution_target: + $ref: "#/components/schemas/PlatformRequestResolutionTarget" + description: Approval breadth; required for an ONGOING approval. + resolution_target_id: + type: string description: | - Datasources visible to the authenticated user. Each `datasource` is an identifier you can pass to `POST /api/search` `datasources`. An empty array means no visible datasources. - items: - $ref: "#/components/schemas/PlatformDatasourceFilterInfo" - request_id: + Optional resolution target identifier. An ONGOING GROUP approval needs the canonical IdP group ID. A supplied department must match the subject's department. + resolution_note: type: string - minLength: 1 - description: Platform-generated request ID for support correlation. + description: Optional note recorded when denying the request. + allOf: + - description: Approval carries an increase; denial can carry a note. + oneOf: + - description: Approve with a positive additive increase. + required: + - approved_increase_amount + properties: + status: + description: Approval discriminator. + enum: + - APPROVED + not: + description: Approval does not record a resolution note. + required: + - resolution_note + oneOf: + - description: A period approval does not change the standing rule. + properties: + scope: + description: Period approval, also selected when scope is omitted. + enum: + - PERIOD + - description: An ongoing user approval selects a standing-rule target. + required: + - scope + - resolution_target + properties: + scope: + description: Ongoing approval discriminator. + enum: + - ONGOING + oneOf: + - description: A user, organization, or department target needs no group identifier. + properties: + resolution_target: + description: Non-group standing-rule target. + enum: + - USER + - ALL + - DEPARTMENT + - description: A group target requires its canonical IdP group identifier. + required: + - resolution_target_id + properties: + resolution_target: + description: Group standing-rule target. + enum: + - GROUP + resolution_target_id: + description: Nonempty canonical IdP group identifier. + minLength: 1 + - description: Deny without approval fields. + properties: + status: + description: Denial discriminator. + enum: + - DENIED + not: + description: Approval fields are not denial inputs. + anyOf: + - required: + - approved_increase_amount + description: Detect an approval amount. + - required: + - scope + description: Detect an approval scope. + - required: + - resolution_target + description: Detect an approval target. + - required: + - resolution_target_id + description: Detect an approval target identifier. PlatformTriggerStatus: type: string description: Current trigger lifecycle state. @@ -9628,6 +11997,87 @@ components: RESPONSE_OUTPUT_TEXT_DONE: "#/components/schemas/PlatformChatStreamOutputTextDoneServerSentEvent" RESPONSE_COMPLETED: "#/components/schemas/PlatformChatStreamResponseCompletedServerSentEvent" RESPONSE_FAILED: "#/components/schemas/PlatformChatStreamResponseFailedServerSentEvent" + PlatformSkillSourcePreviewStreamScanServerSentEvent: + type: object + required: + - event + - data + properties: + id: + type: string + event: + type: string + const: SCAN + data: + $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamScan" + PlatformSkillSourcePreviewStreamProgressServerSentEvent: + type: object + required: + - event + - data + properties: + id: + type: string + event: + type: string + const: PROGRESS + data: + $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamProgress" + PlatformSkillSourcePreviewStreamSkillServerSentEvent: + type: object + required: + - event + - data + properties: + id: + type: string + event: + type: string + const: SKILL + data: + $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamSkill" + PlatformSkillSourcePreviewStreamResultServerSentEvent: + type: object + required: + - event + - data + properties: + id: + type: string + event: + type: string + const: RESULT + data: + $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamResult" + PlatformSkillSourcePreviewStreamErrorServerSentEvent: + type: object + required: + - event + - data + properties: + id: + type: string + event: + type: string + const: ERROR + data: + $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamError" + PlatformSkillSourcePreviewStreamEventServerSentEvent: + description: A typed server-sent event. + oneOf: + - $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamScanServerSentEvent" + - $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamProgressServerSentEvent" + - $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamSkillServerSentEvent" + - $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamResultServerSentEvent" + - $ref: "#/components/schemas/PlatformSkillSourcePreviewStreamErrorServerSentEvent" + discriminator: + propertyName: event + mapping: + SCAN: "#/components/schemas/PlatformSkillSourcePreviewStreamScanServerSentEvent" + PROGRESS: "#/components/schemas/PlatformSkillSourcePreviewStreamProgressServerSentEvent" + SKILL: "#/components/schemas/PlatformSkillSourcePreviewStreamSkillServerSentEvent" + RESULT: "#/components/schemas/PlatformSkillSourcePreviewStreamResultServerSentEvent" + ERROR: "#/components/schemas/PlatformSkillSourcePreviewStreamErrorServerSentEvent" ActivityEventParams: properties: bodyContent: @@ -10593,6 +13043,9 @@ components: obfuscatedId: type: string description: An opaque identifier that can be used to request metadata for a Person. + identityOnly: + type: boolean + description: True when this is an authenticated identity fallback rather than a people profile. Directory metadata is unavailable. relatedDocuments: type: array items: @@ -11407,6 +13860,7 @@ components: - SPREADSHEET_TYPE - INLINE_HTML_TYPE - PODCAST_TYPE + - VIDEO_TYPE - WORKFLOWS_TYPE FavoriteInfo: type: object @@ -14628,9 +17082,8 @@ components: type: string minLength: 1 page_number: - type: - - integer - - "null" + type: integer + nullable: true required: - text additionalProperties: false @@ -14647,21 +17100,18 @@ components: $ref: '#/components/schemas/ChatCitationSource' minItems: 1 start_index: - type: - - integer - - "null" + type: integer minimum: 0 + nullable: true end_index: - type: - - integer - - "null" + type: integer minimum: 0 + nullable: true snippets: - type: - - array - - "null" + type: array items: $ref: '#/components/schemas/ChatCitationSnippet' + nullable: true required: - type - sources @@ -15152,6 +17602,7 @@ components: - HOST_APPLICATIONS - TOOLS - SERVERS + - AUTH_METHODS description: Type of breakdown to return. hostApplications: type: array @@ -15168,6 +17619,11 @@ components: items: type: string description: MCP servers to filter by. Empty array means all servers. + authMethods: + type: array + items: + type: string + description: Authentication methods to filter by, for example OAUTH_XAA for Cross App Access traffic. Empty array means all authentication methods. InsightsRequest: properties: overviewRequest: @@ -15683,6 +18139,11 @@ components: items: type: string description: MCP servers used by this user in the specified time period. + authMethods: + type: array + items: + type: string + description: Authentication methods this user's MCP clients presented in the specified time period, for example OAUTH_XAA for Cross App Access. McpHostApplicationBreakdown: properties: hostApplication: @@ -15726,6 +18187,22 @@ components: items: type: string description: Host applications using this server in the specified time period. + McpAuthMethodBreakdown: + properties: + authMethod: + type: string + description: Authentication method the MCP client presented, for example OAUTH_GLEAN, OAUTH_XAA (Cross App Access), or API_TOKEN. + totalCalls: + type: integer + description: Total number of MCP calls for this authentication method in the specified time period. + activeUsers: + type: integer + description: Total number of active users for this authentication method in the specified time period. + hostApplications: + type: array + items: + type: string + description: Host applications using this authentication method in the specified time period. McpBreakdownInsightsResponse: properties: usersBreakdown: @@ -15744,6 +18221,10 @@ components: type: array items: $ref: '#/components/schemas/McpServerBreakdown' + authMethodsBreakdown: + type: array + items: + $ref: '#/components/schemas/McpAuthMethodBreakdown' InsightsResponse: properties: gleanAssist: @@ -16280,12 +18761,12 @@ components: - ADDITIONAL_DOCUMENT - APP - BROWSER_HISTORY + - CHAT_HISTORY - DATASOURCE - DOCUMENT - ENTITY - GOLINK - HISTORY - - CHAT_HISTORY - NEW_CHAT - OPERATOR - OPERATOR_VALUE @@ -16566,6 +19047,8 @@ components: - SHARE_ARTIFACT - CREATE_AGENT - MANAGER_INVITE + - ONBOARDING_AUTHORIZATION + - CHAT_REMINDER description: Categories of content requested. An allowlist gives flexibility to request content separately or together. requestOptions: $ref: '#/components/schemas/FeedRequestOptions' @@ -16847,6 +19330,17 @@ components: items: $ref: '#/components/schemas/DigestSection' description: Array of digest sections from which the podcast was created. + ArtifactType: + type: string + enum: + - PAPER + - AGENT + - MESSAGE + - EMAIL + - HTML_CODE + - SLIDE + description: Type of the Artifact + x-include-enum-class-prefix: true ChatSuggestion: properties: query: @@ -16858,6 +19352,9 @@ components: feature: type: string description: Targeted Glean Chat feature for the suggestion. + artifactType: + $ref: '#/components/schemas/ArtifactType' + description: The single artifact type to review for an unread artifact reminder. sourceDocumentIds: type: array items: @@ -17043,6 +19540,8 @@ components: - SHARE_ARTIFACT - CREATE_AGENT - MANAGER_INVITE + - ONBOARDING_AUTHORIZATION + - CHAT_REMINDER description: Type of the justification. justification: type: string @@ -17143,6 +19642,8 @@ components: - SHARE_ARTIFACT - CREATE_AGENT - MANAGER_INVITE + - ONBOARDING_AUTHORIZATION + - CHAT_REMINDER description: Category of the result, one of the requested categories in incoming request. primaryEntry: $ref: '#/components/schemas/FeedEntry' @@ -17355,6 +19856,10 @@ components: PeopleRequest: type: object properties: + fallbackToAuthenticatedIdentity: + type: boolean + description: If true and the current user's people profile is missing, reads the stored SSO profile and returns a minimal Person with its display name, the authenticated user's email, the same obfuscatedId used by a normal self-lookup, and identityOnly set to true. If the SSO profile or its name is unavailable, preserves the missing-profile error. Applies only when emailIds and obfuscatedIds are empty and the request doesn't use act-as, a virtual identity, anonymous authentication, or the INVALID_ENTITIES includeType. The fallback doesn't mask lookup or enrichment errors and doesn't create a directory profile. Normal people profiles don't require an SSO lookup. + default: false 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. @@ -20615,6 +23120,13 @@ components: application/problem+json: schema: $ref: "#/components/schemas/PlatformProblemDetail" + PlatformRequestResource: + description: The authorized request in its current stored state. + content: + application/json: + schema: + $ref: "#/components/schemas/PlatformRequestResponse" + description: Current authorized request with a response trace identifier. SuccessResponse: description: OK content: @@ -20652,6 +23164,47 @@ components: schema: $ref: '#/components/schemas/ErrorInfoResponse' parameters: + PageSize: + name: page_size + in: query + description: Maximum page size; defaults to 20 and cannot exceed 100. A page may contain fewer results. + schema: + type: integer + description: Requested upper bound on results in a page. + minimum: 1 + maximum: 100 + default: 20 + Cursor: + name: cursor + in: query + description: Opaque cursor bound to filter fields, values, operators, and current authorization context. + schema: + type: string + description: Opaque continuation returned by a previous list response. + Filters: + name: filters + in: query + description: | + JSON-encoded filters. Only the field status and operator EQUALS are supported. Multiple values OR within a filter. Multiple filters AND together. Cursors bind all filter fields, values, and operators. + content: + application/json: + schema: + type: array + minItems: 1 + description: Structured status filters, combined with AND. + items: + $ref: "#/components/schemas/PlatformRequestFilter" + description: One status filter criterion. + RequestId: + name: request_id + in: path + required: true + description: Opaque request identifier; never an authorization grant. + example: "{request_id}" + schema: + type: string + description: Nonempty identifier of the stored request resource. + minLength: 1 TriggerWebhookId: name: webhook-id in: header diff --git a/.speakeasy/tests.arazzo.yaml b/.speakeasy/tests.arazzo.yaml index f8400bc6..e0a14e04 100644 --- a/.speakeasy/tests.arazzo.yaml +++ b/.speakeasy/tests.arazzo.yaml @@ -158867,11 +158867,11 @@ workflows: payload: file: 'x-file: example.file' successCriteria: - - condition: $statusCode == 200 + - condition: $statusCode == 201 - condition: $response.header.Content-Type == application/json - context: $response.body condition: | - {"skill":{"id":"","display_name":"Merl18","description":"rural ugh unexpectedly excepting livid","latest_version":504149,"latest_minor_version":106110,"status":"DISABLED","origin":"CUSTOM","owner":{"name":""},"created_at":"2025-01-04T03:16:16.951Z","updated_at":"2025-09-10T16:05:46.046Z"},"request_id":""} + {"skill":{"skill_id":"","display_name":"Merl18","description":"rural ugh unexpectedly excepting livid","latest_version":504149,"latest_minor_version":106110,"status":"DISABLED","origin":"CUSTOM","owner":{"name":""},"created_at":"2025-09-10T16:05:46.046Z","updated_at":"2025-08-13T23:05:45.737Z"},"request_id":""} type: simple x-speakeasy-test-group: skills x-speakeasy-test-rebuild: true @@ -158884,8 +158884,12 @@ workflows: - condition: $response.header.Content-Type == application/json - context: $response.body condition: | - {"skills":[],"has_more":true,"next_cursor":"","request_id":""} + {"results":[],"has_more":true,"next_cursor":"","request_id":""} type: simple + parameters: + - name: page_size + in: query + value: 20 x-speakeasy-test-group: skills x-speakeasy-test-rebuild: true - workflowId: platform-skills-validate @@ -158918,7 +158922,7 @@ workflows: - condition: $response.header.Content-Type == application/json - context: $response.body condition: | - {"skill":{"id":"","display_name":"Chad_Herzog","description":"whenever up aha controvert","latest_version":151495,"latest_minor_version":170771,"status":"DISABLED","origin":"CUSTOM","owner":{"name":""},"created_at":"2024-12-25T16:41:00.099Z","updated_at":"2026-12-07T21:59:59.375Z"},"request_id":""} + {"skill":{"skill_id":"","display_name":"Chad_Herzog","description":"whenever up aha controvert","latest_version":151495,"latest_minor_version":170771,"status":"DISABLED","origin":"CUSTOM","owner":{"name":""},"created_at":"2024-12-25T16:41:00.099Z","updated_at":"2026-12-07T21:59:59.375Z"},"request_id":""} type: simple x-speakeasy-test-group: skills x-speakeasy-test-rebuild: true @@ -158952,7 +158956,7 @@ workflows: payload: file: 'x-file: example.file' successCriteria: - - condition: $statusCode == 200 + - condition: $statusCode == 201 - condition: $response.header.Content-Type == application/json - context: $response.body condition: | @@ -158968,12 +158972,15 @@ workflows: - name: skill_id in: path value: + - name: page_size + in: query + value: 20 successCriteria: - condition: $statusCode == 200 - condition: $response.header.Content-Type == application/json - context: $response.body condition: | - {"versions":[],"has_more":false,"next_cursor":"","request_id":""} + {"results":[],"has_more":false,"next_cursor":"","request_id":""} type: simple x-speakeasy-test-group: skills x-speakeasy-test-rebuild: true @@ -159087,7 +159094,7 @@ workflows: source_urls: - https://github.com/anthropics/skills/tree/main/skills/skill-creator successCriteria: - - condition: $statusCode == 200 + - condition: $statusCode == 201 - condition: $response.header.Content-Type == application/json - context: $response.body condition: | @@ -159130,7 +159137,7 @@ workflows: - condition: $response.header.Content-Type == application/json - context: $response.body condition: | - {"skill":{"id":"","display_name":"Afton14","description":"taut netsuke duh sonata boastfully elegantly management come","latest_version":425795,"latest_minor_version":741364,"status":"DISABLED","origin":"CUSTOM","owner":{"name":""},"created_at":"2024-12-20T01:31:39.364Z","updated_at":"2025-12-04T02:59:37.124Z"},"request_id":""} + {"skill":{"skill_id":"","display_name":"Afton14","description":"taut netsuke duh sonata boastfully elegantly management come","latest_version":425795,"latest_minor_version":741364,"status":"DISABLED","origin":"CUSTOM","owner":{"name":""},"created_at":"2024-12-20T01:31:39.364Z","updated_at":"2025-12-04T02:59:37.124Z"},"request_id":""} type: simple x-speakeasy-test-group: skills x-speakeasy-test-rebuild: true @@ -159147,7 +159154,7 @@ workflows: - condition: $response.header.Content-Type == application/json - context: $response.body condition: | - {"sync_status":"UP_TO_DATE","commit_sha":"","updated":false,"request_id":""} + {"commit_sha":"","is_updated":false,"request_id":""} type: simple x-speakeasy-test-group: skills x-speakeasy-test-rebuild: true @@ -159539,3 +159546,137 @@ workflows: type: simple x-speakeasy-test-group: agents x-speakeasy-test-rebuild: true + - workflowId: platform-admin-usage-settings-get + steps: + - stepId: test + operationId: platform-admin-usage-settings-get + successCriteria: + - condition: $statusCode == 200 + - condition: $response.header.Content-Type == application/json + - context: $response.body + condition: | + {"usage_settings":{},"request_id":""} + type: simple + x-speakeasy-test-group: admin_usage + x-speakeasy-test-rebuild: true + - workflowId: platform-admin-usage-settings-update + steps: + - stepId: test + operationId: platform-admin-usage-settings-update + requestBody: + contentType: application/json + payload: + limit_increase_requests: + business_justification: REQUIRED + successCriteria: + - condition: $statusCode == 200 + - condition: $response.header.Content-Type == application/json + - context: $response.body + condition: | + {"usage_settings":{},"request_id":""} + type: simple + x-speakeasy-test-group: admin_usage + x-speakeasy-test-rebuild: true + - workflowId: platform-admin-usage-requests-create + steps: + - stepId: test + operationId: platform-admin-usage-requests-create + requestBody: + contentType: application/json + payload: + agent_id: + client_id: + successCriteria: + - condition: $statusCode == 201 + - condition: $response.header.Content-Type == application/json + - context: $response.body + condition: | + {"request":{"request_id":"","entity_type":"USER","entity_id":"","client_id":"","requester_user_id":"","period":"","status":"DENIED","created_at":"2024-10-18T04:43:55.054Z"},"request_id":""} + type: simple + x-speakeasy-test-group: admin_usage + x-speakeasy-test-rebuild: true + - workflowId: platform-admin-usage-requests-list + steps: + - stepId: test + operationId: platform-admin-usage-requests-list + parameters: + - name: page_size + in: query + value: 20 + successCriteria: + - condition: $statusCode == 200 + - condition: $response.header.Content-Type == application/json + - context: $response.body + condition: | + {"has_more":false,"next_cursor":"","results":[{"request_id":"","entity_type":"USER","entity_id":"","client_id":"","requester_user_id":"","period":"","status":"PENDING","created_at":"2024-01-15T07:33:22.777Z"}],"request_id":""} + type: simple + x-speakeasy-test-group: admin_usage + x-speakeasy-test-rebuild: true + - workflowId: platform-admin-usage-requests-get + steps: + - stepId: test + operationId: platform-admin-usage-requests-get + parameters: + - name: request_id + in: path + value: '{request_id}' + successCriteria: + - condition: $statusCode == 200 + - condition: $response.header.Content-Type == application/json + - context: $response.body + condition: | + {"request":{"request_id":"","entity_type":"USER","entity_id":"","client_id":"","requester_user_id":"","period":"","status":"APPROVED","created_at":"2024-11-21T17:52:20.403Z"},"request_id":""} + type: simple + x-speakeasy-test-group: admin_usage + x-speakeasy-test-rebuild: true + - workflowId: platform-usage-requests-create + steps: + - stepId: test + operationId: platform-usage-requests-create + requestBody: + contentType: application/json + payload: + client_id: + successCriteria: + - condition: $statusCode == 201 + - condition: $response.header.Content-Type == application/json + - context: $response.body + condition: | + {"request":{"request_id":"","entity_type":"AGENT","entity_id":"","client_id":"","requester_user_id":"","period":"","status":"PENDING","created_at":"2024-07-26T20:31:19.316Z"},"request_id":""} + type: simple + x-speakeasy-test-group: usage + x-speakeasy-test-rebuild: true + - workflowId: platform-usage-requests-list + steps: + - stepId: test + operationId: platform-usage-requests-list + parameters: + - name: page_size + in: query + value: 20 + successCriteria: + - condition: $statusCode == 200 + - condition: $response.header.Content-Type == application/json + - context: $response.body + condition: | + {"has_more":false,"results":[],"request_id":""} + type: simple + x-speakeasy-test-group: usage + x-speakeasy-test-rebuild: true + - workflowId: platform-usage-requests-get + steps: + - stepId: test + operationId: platform-usage-requests-get + parameters: + - name: request_id + in: path + value: '{request_id}' + successCriteria: + - condition: $statusCode == 200 + - condition: $response.header.Content-Type == application/json + - context: $response.body + condition: | + {"request":{"request_id":"","entity_type":"AGENT","entity_id":"","client_id":"","requester_user_id":"","period":"","status":"DENIED","created_at":"2026-10-11T16:53:21.602Z"},"request_id":""} + type: simple + x-speakeasy-test-group: usage + x-speakeasy-test-rebuild: true diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index 3bd9a676..21e0b0d3 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -1,9 +1,9 @@ -speakeasyVersion: 1.798.0 +speakeasyVersion: 1.800.0 sources: Glean API: sourceNamespace: glean-api-specs - sourceRevisionDigest: sha256:09823f8003cfb3ebf08b6adfa434cefda4c97f7ee64ae18dc0066fe392647c97 - sourceBlobDigest: sha256:fc4fcf9c37dfd0e8387153211f760a21a602ede64951d4e4c824e8e1b168b7b8 + sourceRevisionDigest: sha256:350d5ba9ec23f6139da627affb01195a52cd293dd5a6791caec5afc2c3025c4e + sourceBlobDigest: sha256:66df9d6e7cbe52aafce776b53c53af1642e977f4f5b13ebe2852bdcee74b921c tags: - latest Glean Client API: @@ -16,10 +16,10 @@ targets: glean: source: Glean API sourceNamespace: glean-api-specs - sourceRevisionDigest: sha256:09823f8003cfb3ebf08b6adfa434cefda4c97f7ee64ae18dc0066fe392647c97 - sourceBlobDigest: sha256:fc4fcf9c37dfd0e8387153211f760a21a602ede64951d4e4c824e8e1b168b7b8 + sourceRevisionDigest: sha256:350d5ba9ec23f6139da627affb01195a52cd293dd5a6791caec5afc2c3025c4e + sourceBlobDigest: sha256:66df9d6e7cbe52aafce776b53c53af1642e977f4f5b13ebe2852bdcee74b921c codeSamplesNamespace: glean-api-specs-python-code-samples - codeSamplesRevisionDigest: sha256:5da391e8e0a7821657f62afcee0636ca4423213b036163bea43637e45c1f3c7c + codeSamplesRevisionDigest: sha256:d48a82deb8bceae51990b255dc83ad06aca83825a95dfdef6057a7f2d9c050ec workflow: workflowVersion: 1.0.0 speakeasyVersion: latest diff --git a/README.md b/README.md index b2d1dc57..0c414669 100644 --- a/README.md +++ b/README.md @@ -315,6 +315,14 @@ For more information on obtaining the appropriate token type, please contact you
Available methods +### [Admin.Usage](docs/sdks/adminusage/README.md) + +* [get_settings](docs/sdks/adminusage/README.md#get_settings) - Get usage settings +* [update_settings](docs/sdks/adminusage/README.md#update_settings) - Update usage settings +* [create_limit_increase_request](docs/sdks/adminusage/README.md#create_limit_increase_request) - Submit an editable-agent limit-increase request +* [list_limit_increase_requests](docs/sdks/adminusage/README.md#list_limit_increase_requests) - List the billing limit-increase request queue +* [get_limit_increase_request](docs/sdks/adminusage/README.md#get_limit_increase_request) - Get a billing limit-increase request + ### [Agents](docs/sdks/agents/README.md) * [search](docs/sdks/agents/README.md#search) - Search agents @@ -578,6 +586,7 @@ For more information on obtaining the appropriate token type, please contact you * [list_versions](docs/sdks/skills/README.md#list_versions) - List skill versions * [retrieve_version](docs/sdks/skills/README.md#retrieve_version) - Retrieve skill version * [retrieve_version_content](docs/sdks/skills/README.md#retrieve_version_content) - Download skill version content +* [preview_source_stream](docs/sdks/skills/README.md#preview_source_stream) - Preview a GitHub skill source as events ### [Triggers](docs/sdks/triggers/README.md) @@ -592,6 +601,12 @@ For more information on obtaining the appropriate token type, please contact you * [list_preset_input_values](docs/sdks/triggers/README.md#list_preset_input_values) - Search trigger preset input values * [search_preset_events](docs/sdks/triggers/README.md#search_preset_events) - Search events for a trigger preset +### [Usage](docs/sdks/usage/README.md) + +* [create_limit_increase_request](docs/sdks/usage/README.md#create_limit_increase_request) - Submit a personal limit-increase request +* [list_limit_increase_requests](docs/sdks/usage/README.md#list_limit_increase_requests) - List personal limit-increase requests +* [get_limit_increase_request](docs/sdks/usage/README.md#get_limit_increase_request) - Get a personal limit-increase request +
diff --git a/RELEASES.md b/RELEASES.md index b416354a..e2e80718 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -1008,4 +1008,14 @@ Based on: ### Generated - [python v0.17.15] . ### Releases -- [PyPI v0.17.15] https://pypi.org/project/glean-api-client/0.17.15 - . \ No newline at end of file +- [PyPI v0.17.15] https://pypi.org/project/glean-api-client/0.17.15 - . + +## 2026-10-02 04:27:04 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.800.0 (2.943.0) https://github.com/speakeasy-api/speakeasy +### Generated +- [python v0.17.16] . +### Releases +- [PyPI v0.17.16] https://pypi.org/project/glean-api-client/0.17.16 - . \ No newline at end of file diff --git a/docs/models/artifacttype.md b/docs/models/artifacttype.md new file mode 100644 index 00000000..acd892d2 --- /dev/null +++ b/docs/models/artifacttype.md @@ -0,0 +1,25 @@ +# ArtifactType + +Type of the Artifact + +## Example Usage + +```python +from glean.api_client.models import ArtifactType + +value = ArtifactType.PAPER + +# Open enum: unrecognized values are captured as UnrecognizedStr +``` + + +## Values + +| Name | Value | +| ----------- | ----------- | +| `PAPER` | PAPER | +| `AGENT` | AGENT | +| `MESSAGE` | MESSAGE | +| `EMAIL` | EMAIL | +| `HTML_CODE` | HTML_CODE | +| `SLIDE` | SLIDE | \ No newline at end of file diff --git a/docs/models/autocompleterequestresulttype.md b/docs/models/autocompleterequestresulttype.md index 1133a59c..d5efb95f 100644 --- a/docs/models/autocompleterequestresulttype.md +++ b/docs/models/autocompleterequestresulttype.md @@ -16,12 +16,12 @@ value = AutocompleteRequestResultType.ADDITIONAL_DOCUMENT | `ADDITIONAL_DOCUMENT` | ADDITIONAL_DOCUMENT | | `APP` | APP | | `BROWSER_HISTORY` | BROWSER_HISTORY | +| `CHAT_HISTORY` | CHAT_HISTORY | | `DATASOURCE` | DATASOURCE | | `DOCUMENT` | DOCUMENT | | `ENTITY` | ENTITY | | `GOLINK` | GOLINK | | `HISTORY` | HISTORY | -| `CHAT_HISTORY` | CHAT_HISTORY | | `NEW_CHAT` | NEW_CHAT | | `OPERATOR` | OPERATOR | | `OPERATOR_VALUE` | OPERATOR_VALUE | diff --git a/docs/models/breakdowntype.md b/docs/models/breakdowntype.md index dbe36727..6e84b1a5 100644 --- a/docs/models/breakdowntype.md +++ b/docs/models/breakdowntype.md @@ -18,4 +18,5 @@ value = BreakdownType.USERS | `USERS` | USERS | | `HOST_APPLICATIONS` | HOST_APPLICATIONS | | `TOOLS` | TOOLS | -| `SERVERS` | SERVERS | \ No newline at end of file +| `SERVERS` | SERVERS | +| `AUTH_METHODS` | AUTH_METHODS | \ No newline at end of file diff --git a/docs/models/businessjustification.md b/docs/models/businessjustification.md new file mode 100644 index 00000000..9777ff87 --- /dev/null +++ b/docs/models/businessjustification.md @@ -0,0 +1,22 @@ +# BusinessJustification + +Whether a business justification is required when requesting a usage limit increase. + + +## Example Usage + +```python +from glean.api_client.models import BusinessJustification + +value = BusinessJustification.OPTIONAL + +# Open enum: unrecognized values are captured as UnrecognizedStr +``` + + +## Values + +| Name | Value | +| ---------- | ---------- | +| `OPTIONAL` | OPTIONAL | +| `REQUIRED` | REQUIRED | \ No newline at end of file diff --git a/docs/models/chatsuggestion.md b/docs/models/chatsuggestion.md index e18aae7b..c84fee73 100644 --- a/docs/models/chatsuggestion.md +++ b/docs/models/chatsuggestion.md @@ -8,4 +8,5 @@ | `query` | *Optional[str]* | :heavy_minus_sign: | The actionable chat query to run when the user selects this suggestion. | | `cta` | *Optional[str]* | :heavy_minus_sign: | Button text to show for the suggestion action. | | `feature` | *Optional[str]* | :heavy_minus_sign: | Targeted Glean Chat feature for the suggestion. | +| `artifact_type` | [Optional[models.ArtifactType]](../models/artifacttype.md) | :heavy_minus_sign: | Type of the Artifact | | `source_document_ids` | List[*str*] | :heavy_minus_sign: | Document IDs that grounded the suggestion. | \ No newline at end of file diff --git a/docs/models/feedrequestcategory.md b/docs/models/feedrequestcategory.md index 662a836b..35f342f9 100644 --- a/docs/models/feedrequestcategory.md +++ b/docs/models/feedrequestcategory.md @@ -66,4 +66,6 @@ value = FeedRequestCategory.DOCUMENT_SUGGESTION | `CHAT_TO_ARTIFACT` | CHAT_TO_ARTIFACT | | `SHARE_ARTIFACT` | SHARE_ARTIFACT | | `CREATE_AGENT` | CREATE_AGENT | -| `MANAGER_INVITE` | MANAGER_INVITE | \ No newline at end of file +| `MANAGER_INVITE` | MANAGER_INVITE | +| `ONBOARDING_AUTHORIZATION` | ONBOARDING_AUTHORIZATION | +| `CHAT_REMINDER` | CHAT_REMINDER | \ No newline at end of file diff --git a/docs/models/feedresultcategory.md b/docs/models/feedresultcategory.md index b1ed34c8..591586c6 100644 --- a/docs/models/feedresultcategory.md +++ b/docs/models/feedresultcategory.md @@ -70,4 +70,6 @@ value = FeedResultCategory.DOCUMENT_SUGGESTION | `CHAT_TO_ARTIFACT` | CHAT_TO_ARTIFACT | | `SHARE_ARTIFACT` | SHARE_ARTIFACT | | `CREATE_AGENT` | CREATE_AGENT | -| `MANAGER_INVITE` | MANAGER_INVITE | \ No newline at end of file +| `MANAGER_INVITE` | MANAGER_INVITE | +| `ONBOARDING_AUTHORIZATION` | ONBOARDING_AUTHORIZATION | +| `CHAT_REMINDER` | CHAT_REMINDER | \ No newline at end of file diff --git a/docs/models/idpgroups.md b/docs/models/idpgroups.md new file mode 100644 index 00000000..879d13aa --- /dev/null +++ b/docs/models/idpgroups.md @@ -0,0 +1,22 @@ +# IdpGroups + +How to resolve effective usage limits when a user belongs to multiple IdP groups. + + +## Example Usage + +```python +from glean.api_client.models import IdpGroups + +value = IdpGroups.HIGHEST + +# Open enum: unrecognized values are captured as UnrecognizedStr +``` + + +## Values + +| Name | Value | +| --------- | --------- | +| `HIGHEST` | HIGHEST | +| `LOWEST` | LOWEST | \ No newline at end of file diff --git a/docs/models/justificationtype.md b/docs/models/justificationtype.md index 7764769f..0017912a 100644 --- a/docs/models/justificationtype.md +++ b/docs/models/justificationtype.md @@ -84,4 +84,6 @@ value = JustificationType.FREQUENTLY_ACCESSED | `CHAT_TO_ARTIFACT` | CHAT_TO_ARTIFACT | | `SHARE_ARTIFACT` | SHARE_ARTIFACT | | `CREATE_AGENT` | CREATE_AGENT | -| `MANAGER_INVITE` | MANAGER_INVITE | \ No newline at end of file +| `MANAGER_INVITE` | MANAGER_INVITE | +| `ONBOARDING_AUTHORIZATION` | ONBOARDING_AUTHORIZATION | +| `CHAT_REMINDER` | CHAT_REMINDER | \ No newline at end of file diff --git a/docs/models/mcpauthmethodbreakdown.md b/docs/models/mcpauthmethodbreakdown.md new file mode 100644 index 00000000..bcdeb6cc --- /dev/null +++ b/docs/models/mcpauthmethodbreakdown.md @@ -0,0 +1,11 @@ +# McpAuthMethodBreakdown + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | +| `auth_method` | *Optional[str]* | :heavy_minus_sign: | Authentication method the MCP client presented, for example OAUTH_GLEAN, OAUTH_XAA (Cross App Access), or API_TOKEN. | +| `total_calls` | *Optional[int]* | :heavy_minus_sign: | Total number of MCP calls for this authentication method in the specified time period. | +| `active_users` | *Optional[int]* | :heavy_minus_sign: | Total number of active users for this authentication method in the specified time period. | +| `host_applications` | List[*str*] | :heavy_minus_sign: | Host applications using this authentication method in the specified time period. | \ No newline at end of file diff --git a/docs/models/mcpbreakdowninsightsrequest.md b/docs/models/mcpbreakdowninsightsrequest.md index dfc79947..88e0fb39 100644 --- a/docs/models/mcpbreakdowninsightsrequest.md +++ b/docs/models/mcpbreakdowninsightsrequest.md @@ -3,13 +3,14 @@ ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | -| `departments` | List[*str*] | :heavy_minus_sign: | Departments for which Insights are requested. | -| `manager_ids` | List[*str*] | :heavy_minus_sign: | Manager user IDs whose teams should be filtered for. Empty array means no filtering. | -| `manager_emails` | List[*str*] | :heavy_minus_sign: | Manager emails whose teams should be filtered for. Empty array means no filtering. | -| `day_range` | [Optional[models.Period]](../models/period.md) | :heavy_minus_sign: | N/A | -| `breakdown_type` | [Optional[models.BreakdownType]](../models/breakdowntype.md) | :heavy_minus_sign: | Type of breakdown to return. | -| `host_applications` | List[*str*] | :heavy_minus_sign: | Host applications to filter by. Empty array means all host applications. | -| `tools` | List[*str*] | :heavy_minus_sign: | MCP tools to filter by. Empty array means all tools. | -| `servers` | List[*str*] | :heavy_minus_sign: | MCP servers to filter by. Empty array means all servers. | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------- | +| `departments` | List[*str*] | :heavy_minus_sign: | Departments for which Insights are requested. | +| `manager_ids` | List[*str*] | :heavy_minus_sign: | Manager user IDs whose teams should be filtered for. Empty array means no filtering. | +| `manager_emails` | List[*str*] | :heavy_minus_sign: | Manager emails whose teams should be filtered for. Empty array means no filtering. | +| `day_range` | [Optional[models.Period]](../models/period.md) | :heavy_minus_sign: | N/A | +| `breakdown_type` | [Optional[models.BreakdownType]](../models/breakdowntype.md) | :heavy_minus_sign: | Type of breakdown to return. | +| `host_applications` | List[*str*] | :heavy_minus_sign: | Host applications to filter by. Empty array means all host applications. | +| `tools` | List[*str*] | :heavy_minus_sign: | MCP tools to filter by. Empty array means all tools. | +| `servers` | List[*str*] | :heavy_minus_sign: | MCP servers to filter by. Empty array means all servers. | +| `auth_methods` | List[*str*] | :heavy_minus_sign: | Authentication methods to filter by, for example OAUTH_XAA for Cross App Access traffic. Empty array means all authentication methods. | \ No newline at end of file diff --git a/docs/models/mcpbreakdowninsightsresponse.md b/docs/models/mcpbreakdowninsightsresponse.md index 94328ff4..95f06445 100644 --- a/docs/models/mcpbreakdowninsightsresponse.md +++ b/docs/models/mcpbreakdowninsightsresponse.md @@ -8,4 +8,5 @@ | `users_breakdown` | List[[models.McpUserBreakdown](../models/mcpuserbreakdown.md)] | :heavy_minus_sign: | N/A | | `host_applications_breakdown` | List[[models.McpHostApplicationBreakdown](../models/mcphostapplicationbreakdown.md)] | :heavy_minus_sign: | N/A | | `tools_breakdown` | List[[models.McpToolBreakdown](../models/mcptoolbreakdown.md)] | :heavy_minus_sign: | N/A | -| `servers_breakdown` | List[[models.McpServerBreakdown](../models/mcpserverbreakdown.md)] | :heavy_minus_sign: | N/A | \ No newline at end of file +| `servers_breakdown` | List[[models.McpServerBreakdown](../models/mcpserverbreakdown.md)] | :heavy_minus_sign: | N/A | +| `auth_methods_breakdown` | List[[models.McpAuthMethodBreakdown](../models/mcpauthmethodbreakdown.md)] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/mcpuserbreakdown.md b/docs/models/mcpuserbreakdown.md index 1c4e22ef..09e90b95 100644 --- a/docs/models/mcpuserbreakdown.md +++ b/docs/models/mcpuserbreakdown.md @@ -3,10 +3,11 @@ ## Fields -| Field | Type | Required | Description | Example | -| ------------------------------------------------------------------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------- | -| `person` | [Optional[models.Person]](../models/person.md) | :heavy_minus_sign: | N/A | {
"name": "George Clooney",
"obfuscatedId": "abc123"
} | -| `total_calls` | *Optional[int]* | :heavy_minus_sign: | Total number of MCP calls made by this user in the specified time period. | | -| `host_applications` | List[*str*] | :heavy_minus_sign: | Host applications used by this user in the specified time period. | | -| `tools` | List[*str*] | :heavy_minus_sign: | MCP tools used by this user in the specified time period. | | -| `servers` | List[*str*] | :heavy_minus_sign: | MCP servers used by this user in the specified time period. | | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| `person` | [Optional[models.Person]](../models/person.md) | :heavy_minus_sign: | N/A | {
"name": "George Clooney",
"obfuscatedId": "abc123"
} | +| `total_calls` | *Optional[int]* | :heavy_minus_sign: | Total number of MCP calls made by this user in the specified time period. | | +| `host_applications` | List[*str*] | :heavy_minus_sign: | Host applications used by this user in the specified time period. | | +| `tools` | List[*str*] | :heavy_minus_sign: | MCP tools used by this user in the specified time period. | | +| `servers` | List[*str*] | :heavy_minus_sign: | MCP servers used by this user in the specified time period. | | +| `auth_methods` | List[*str*] | :heavy_minus_sign: | Authentication methods this user's MCP clients presented in the specified time period, for example OAUTH_XAA for Cross App Access. | | \ No newline at end of file diff --git a/docs/models/operator.md b/docs/models/operator.md new file mode 100644 index 00000000..0d084176 --- /dev/null +++ b/docs/models/operator.md @@ -0,0 +1,23 @@ +# Operator + +Only EQUALS is supported; defaults to EQUALS when omitted. + +## Example Usage + +```python +from glean.api_client.models import Operator + +value = Operator.EQUALS +``` + + +## Values + +| Name | Value | +| ------------ | ------------ | +| `EQUALS` | EQUALS | +| `NOT_EQUALS` | NOT_EQUALS | +| `GT` | GT | +| `GTE` | GTE | +| `LT` | LT | +| `LTE` | LTE | \ No newline at end of file diff --git a/docs/models/peoplerequest.md b/docs/models/peoplerequest.md index cabbe6e5..66af83b5 100644 --- a/docs/models/peoplerequest.md +++ b/docs/models/peoplerequest.md @@ -3,11 +3,12 @@ ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | -| `timezone_offset` | *Optional[int]* | :heavy_minus_sign: | The offset of the client's timezone in minutes from UTC. e.g. PDT is -420 because it's 7 hours behind UTC. | -| `obfuscated_ids` | List[*str*] | :heavy_minus_sign: | The Person IDs to retrieve. If no IDs are requested, the current user's details are returned. | -| `email_ids` | List[*str*] | :heavy_minus_sign: | The email IDs to retrieve. The result is the deduplicated union of emailIds and obfuscatedIds. | -| `include_fields` | List[[models.PeopleRequestIncludeField](../models/peoplerequestincludefield.md)] | :heavy_minus_sign: | List of PersonMetadata fields to return (that aren't returned by default) | -| `include_types` | List[[models.IncludeType](../models/includetype.md)] | :heavy_minus_sign: | The types of people entities to include in the response in addition to those returned by default. | -| `source` | *Optional[str]* | :heavy_minus_sign: | A string denoting the search surface from which the endpoint is called. | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `fallback_to_authenticated_identity` | *Optional[bool]* | :heavy_minus_sign: | If true and the current user's people profile is missing, reads the stored SSO profile and returns a minimal Person with its display name, the authenticated user's email, the same obfuscatedId used by a normal self-lookup, and identityOnly set to true. If the SSO profile or its name is unavailable, preserves the missing-profile error. Applies only when emailIds and obfuscatedIds are empty and the request doesn't use act-as, a virtual identity, anonymous authentication, or the INVALID_ENTITIES includeType. The fallback doesn't mask lookup or enrichment errors and doesn't create a directory profile. Normal people profiles don't require an SSO lookup. | +| `timezone_offset` | *Optional[int]* | :heavy_minus_sign: | The offset of the client's timezone in minutes from UTC. e.g. PDT is -420 because it's 7 hours behind UTC. | +| `obfuscated_ids` | List[*str*] | :heavy_minus_sign: | The Person IDs to retrieve. If no IDs are requested, the current user's details are returned. | +| `email_ids` | List[*str*] | :heavy_minus_sign: | The email IDs to retrieve. The result is the deduplicated union of emailIds and obfuscatedIds. | +| `include_fields` | List[[models.PeopleRequestIncludeField](../models/peoplerequestincludefield.md)] | :heavy_minus_sign: | List of PersonMetadata fields to return (that aren't returned by default) | +| `include_types` | List[[models.IncludeType](../models/includetype.md)] | :heavy_minus_sign: | The types of people entities to include in the response in addition to those returned by default. | +| `source` | *Optional[str]* | :heavy_minus_sign: | A string denoting the search surface from which the endpoint is called. | \ No newline at end of file diff --git a/docs/models/person.md b/docs/models/person.md index 233784bc..e9846658 100644 --- a/docs/models/person.md +++ b/docs/models/person.md @@ -7,5 +7,6 @@ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `name` | *str* | :heavy_check_mark: | The display name. | | | `obfuscated_id` | *str* | :heavy_check_mark: | An opaque identifier that can be used to request metadata for a Person. | | +| `identity_only` | *Optional[bool]* | :heavy_minus_sign: | True when this is an authenticated identity fallback rather than a people profile. Directory metadata is unavailable. | | | `related_documents` | List[[models.RelatedDocuments](../models/relateddocuments.md)] | :heavy_minus_sign: | A list of documents related to this person. | | | `metadata` | [Optional[models.PersonMetadata]](../models/personmetadata.md) | :heavy_minus_sign: | N/A | {
"department": "Movies",
"email": "george@example.com",
"location": "Hollywood, CA",
"phone": "6505551234",
"photoUrl": "https://example.com/george.jpg",
"startDate": "2000-01-23",
"title": "Actor"
} | \ No newline at end of file diff --git a/docs/models/platformadminusagerequestsgetrequest.md b/docs/models/platformadminusagerequestsgetrequest.md new file mode 100644 index 00000000..aad4e248 --- /dev/null +++ b/docs/models/platformadminusagerequestsgetrequest.md @@ -0,0 +1,8 @@ +# PlatformAdminUsageRequestsGetRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------------------------ | ------------------------------------------------------ | ------------------------------------------------------ | ------------------------------------------------------ | ------------------------------------------------------ | +| `request_id` | *str* | :heavy_check_mark: | Opaque request identifier; not an authorization grant. | {request_id} | \ No newline at end of file diff --git a/docs/models/platformadminusagerequestslistrequest.md b/docs/models/platformadminusagerequestslistrequest.md new file mode 100644 index 00000000..7fda9d91 --- /dev/null +++ b/docs/models/platformadminusagerequestslistrequest.md @@ -0,0 +1,10 @@ +# PlatformAdminUsageRequestsListRequest + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | +| `page_size` | *Optional[int]* | :heavy_minus_sign: | Maximum page size; defaults to 20 and cannot exceed 100. | +| `cursor` | *Optional[str]* | :heavy_minus_sign: | Opaque continuation bound to filters and current authorization. | +| `filters` | List[[models.PlatformRequestFilter](../models/platformrequestfilter.md)] | :heavy_minus_sign: | Optional structured filters on request status. | \ No newline at end of file diff --git a/docs/models/platformagentrequestcreate.md b/docs/models/platformagentrequestcreate.md new file mode 100644 index 00000000..e618290b --- /dev/null +++ b/docs/models/platformagentrequestcreate.md @@ -0,0 +1,12 @@ +# PlatformAgentRequestCreate + +New client-scoped request for an editable agent in the server's current UTC month. + + +## Fields + +| Field | Type | Required | Description | +| --------------------------------------------------------- | --------------------------------------------------------- | --------------------------------------------------------- | --------------------------------------------------------- | +| `agent_id` | *str* | :heavy_check_mark: | Identifier of the agent whose limit the request concerns. | +| `client_id` | *str* | :heavy_check_mark: | Explicit spend client whose limit the request concerns. | +| `business_justification` | *Optional[str]* | :heavy_minus_sign: | Optional explanation of why the increase is needed. | \ No newline at end of file diff --git a/docs/models/platformlimitincreaserequest.md b/docs/models/platformlimitincreaserequest.md new file mode 100644 index 00000000..a28d3bd8 --- /dev/null +++ b/docs/models/platformlimitincreaserequest.md @@ -0,0 +1,25 @@ +# PlatformLimitIncreaseRequest + +Stored user or agent request, with optional resolution fields when available. + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `request_id` | *str* | :heavy_check_mark: | Server-assigned resource identifier, distinct from the response's trace request_id. | +| `entity_type` | [models.PlatformLimitIncreaseRequestEntityType](../models/platformlimitincreaserequestentitytype.md) | :heavy_check_mark: | Whether the request concerns a user or an agent. | +| `entity_id` | *str* | :heavy_check_mark: | Canonical user ID or agent ID whose limit the request concerns. | +| `client_id` | *str* | :heavy_check_mark: | Spend client for this user or agent request. | +| `requester_user_id` | *str* | :heavy_check_mark: | Authenticated user who created the request. | +| `business_justification` | *Optional[str]* | :heavy_minus_sign: | Stored explanation of why the increase is needed, when supplied. | +| `period` | *str* | :heavy_check_mark: | UTC calendar month in YYYY-MM format, assigned by the server at creation. | +| `status` | [models.PlatformRequestStatus](../models/platformrequeststatus.md) | :heavy_check_mark: | Stored request state. | +| `resolved_by_user_id` | *Optional[str]* | :heavy_minus_sign: | User who resolved the request, when available. | +| `approved_increase_amount` | *Optional[str]* | :heavy_minus_sign: | Positive additive increase in the applicable rule's denomination, encoded as a plain decimal string. The backend stores float32 values, not arbitrary-precision decimals.
| +| `scope` | [Optional[models.PlatformRequestScope]](../models/platformrequestscope.md) | :heavy_minus_sign: | Increase for the stored request month or an ongoing standing-rule increase. | +| `resolution_target` | [Optional[models.PlatformRequestResolutionTarget]](../models/platformrequestresolutiontarget.md) | :heavy_minus_sign: | Breadth of the approved increase; GROUP identifies an IdP group. | +| `resolution_target_id` | *Optional[str]* | :heavy_minus_sign: | Stored department or canonical IdP group ID, when available. | +| `resolution_note` | *Optional[str]* | :heavy_minus_sign: | Stored denial note, when supplied. | +| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | Request creation time. | +| `updated_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | Last stored update time; this is the resolution time for resolved requests. | \ No newline at end of file diff --git a/docs/models/platformlimitincreaserequestentitytype.md b/docs/models/platformlimitincreaserequestentitytype.md new file mode 100644 index 00000000..055d1a51 --- /dev/null +++ b/docs/models/platformlimitincreaserequestentitytype.md @@ -0,0 +1,21 @@ +# PlatformLimitIncreaseRequestEntityType + +Whether the request concerns a user or an agent. + +## Example Usage + +```python +from glean.api_client.models import PlatformLimitIncreaseRequestEntityType + +value = PlatformLimitIncreaseRequestEntityType.USER + +# Open enum: unrecognized values are captured as UnrecognizedStr +``` + + +## Values + +| Name | Value | +| ------- | ------- | +| `USER` | USER | +| `AGENT` | AGENT | \ No newline at end of file diff --git a/docs/models/platformlimitincreaserequestsettings.md b/docs/models/platformlimitincreaserequestsettings.md new file mode 100644 index 00000000..123d3f92 --- /dev/null +++ b/docs/models/platformlimitincreaserequestsettings.md @@ -0,0 +1,11 @@ +# PlatformLimitIncreaseRequestSettings + +Settings that govern usage limit increase requests. + + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | +| `business_justification` | [models.BusinessJustification](../models/businessjustification.md) | :heavy_check_mark: | Whether a business justification is required when requesting a usage limit increase.
| \ No newline at end of file diff --git a/docs/models/platformmultiplemembershipresolutionsettings.md b/docs/models/platformmultiplemembershipresolutionsettings.md new file mode 100644 index 00000000..55ca071b --- /dev/null +++ b/docs/models/platformmultiplemembershipresolutionsettings.md @@ -0,0 +1,10 @@ +# PlatformMultipleMembershipResolutionSettings + +Settings for resolving limits across multiple memberships. + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | +| `per_member` | [models.PlatformPerMemberSettings](../models/platformpermembersettings.md) | :heavy_check_mark: | Resolution settings for the per-member limit family. | \ No newline at end of file diff --git a/docs/models/platformpermembersettings.md b/docs/models/platformpermembersettings.md new file mode 100644 index 00000000..595e8d33 --- /dev/null +++ b/docs/models/platformpermembersettings.md @@ -0,0 +1,10 @@ +# PlatformPerMemberSettings + +Resolution settings for the per-member limit family. + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | +| `idp_groups` | [models.IdpGroups](../models/idpgroups.md) | :heavy_check_mark: | How to resolve effective usage limits when a user belongs to multiple IdP groups.
| \ No newline at end of file diff --git a/docs/models/platformpersonalrequestcreate.md b/docs/models/platformpersonalrequestcreate.md new file mode 100644 index 00000000..6ebde802 --- /dev/null +++ b/docs/models/platformpersonalrequestcreate.md @@ -0,0 +1,11 @@ +# PlatformPersonalRequestCreate + +New request for the authenticated canonical user in the server's current UTC month. + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | +| `client_id` | *str* | :heavy_check_mark: | Explicit spend client whose limit the request concerns. | +| `business_justification` | *Optional[str]* | :heavy_minus_sign: | Optional explanation of why the increase is needed. | \ No newline at end of file diff --git a/docs/models/platformproblemdetail.md b/docs/models/platformproblemdetail.md new file mode 100644 index 00000000..95a5121d --- /dev/null +++ b/docs/models/platformproblemdetail.md @@ -0,0 +1,18 @@ +# PlatformProblemDetail + +Error response following RFC 9457, extended with `code` and `documentation_url` for machine-readable classification and self-service remediation. + + + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | +| `type` | *str* | :heavy_check_mark: | URI identifying the error type. | https://developers.glean.com/errors/invalid-cursor | +| `title` | *str* | :heavy_check_mark: | Short, human-readable summary of the error. | Invalid Pagination Cursor | +| `status` | *int* | :heavy_check_mark: | HTTP status code mirrored from the response. | 400 | +| `detail` | *str* | :heavy_check_mark: | Human-readable explanation specific to this occurrence. | The provided cursor has expired. Start a new search to get a fresh cursor.
| +| `code` | [models.PlatformProblemDetailCode](../models/platformproblemdetailcode.md) | :heavy_check_mark: | Stable machine-readable error code. | invalid_cursor | +| `documentation_url` | *Optional[str]* | :heavy_minus_sign: | Direct URL to documentation for this error code. | https://developers.glean.com/errors/invalid-cursor | +| `request_id` | *str* | :heavy_check_mark: | Platform-generated request ID for support correlation. | req_7f8a9b0c1d2e | +| `errors` | List[[models.PlatformProblemDetailError](../models/platformproblemdetailerror.md)] | :heavy_minus_sign: | Field-level validation problems, one entry per offending field. | | \ No newline at end of file diff --git a/docs/models/platformrequestfilter.md b/docs/models/platformrequestfilter.md new file mode 100644 index 00000000..419b88fe --- /dev/null +++ b/docs/models/platformrequestfilter.md @@ -0,0 +1,12 @@ +# PlatformRequestFilter + +A status filter using the backend's status-IN matching. + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | +| `field` | *str* | :heavy_check_mark: | Allowed field is status, spelled exactly in lowercase. | +| `values` | List[[models.PlatformRequestStatus](../models/platformrequeststatus.md)] | :heavy_check_mark: | Status values to match with OR. | +| `operator` | [Optional[models.Operator]](../models/operator.md) | :heavy_minus_sign: | Only EQUALS is supported; defaults to EQUALS when omitted. | \ No newline at end of file diff --git a/docs/models/platformrequestlistresponse1.md b/docs/models/platformrequestlistresponse1.md new file mode 100644 index 00000000..758fb09c --- /dev/null +++ b/docs/models/platformrequestlistresponse1.md @@ -0,0 +1,13 @@ +# PlatformRequestListResponse1 + +A further page requires a usable continuation cursor. + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | +| `has_more` | *bool* | :heavy_check_mark: | Whether a further page is available through next_cursor. | +| `next_cursor` | *Nullable[str]* | :heavy_check_mark: | Opaque nonempty continuation when has_more is true; null or omitted otherwise. | +| `results` | List[[models.PlatformLimitIncreaseRequest](../models/platformlimitincreaserequest.md)] | :heavy_check_mark: | Requests visible to the caller under the current filters and authorization. | +| `request_id` | *str* | :heavy_check_mark: | Trace identifier for this list response, not a request resource ID. | \ No newline at end of file diff --git a/docs/models/platformrequestlistresponse2.md b/docs/models/platformrequestlistresponse2.md new file mode 100644 index 00000000..637f2710 --- /dev/null +++ b/docs/models/platformrequestlistresponse2.md @@ -0,0 +1,13 @@ +# PlatformRequestListResponse2 + +The last page has no continuation cursor. + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | +| `has_more` | *bool* | :heavy_check_mark: | Whether a further page is available through next_cursor. | +| `next_cursor` | *OptionalNullable[str]* | :heavy_minus_sign: | Opaque nonempty continuation when has_more is true; null or omitted otherwise. | +| `results` | List[[models.PlatformLimitIncreaseRequest](../models/platformlimitincreaserequest.md)] | :heavy_check_mark: | Requests visible to the caller under the current filters and authorization. | +| `request_id` | *str* | :heavy_check_mark: | Trace identifier for this list response, not a request resource ID. | \ No newline at end of file diff --git a/docs/models/platformrequestlistresponseunion.md b/docs/models/platformrequestlistresponseunion.md new file mode 100644 index 00000000..8a2cb024 --- /dev/null +++ b/docs/models/platformrequestlistresponseunion.md @@ -0,0 +1,19 @@ +# PlatformRequestListResponseUnion + +Bounded page of authorized requests with opaque continuation state. + + +## Supported Types + +### `models.PlatformRequestListResponse1` + +```python +value: models.PlatformRequestListResponse1 = /* values here */ +``` + +### `models.PlatformRequestListResponse2` + +```python +value: models.PlatformRequestListResponse2 = /* values here */ +``` + diff --git a/docs/models/platformrequestresolutiontarget.md b/docs/models/platformrequestresolutiontarget.md new file mode 100644 index 00000000..89aef196 --- /dev/null +++ b/docs/models/platformrequestresolutiontarget.md @@ -0,0 +1,23 @@ +# PlatformRequestResolutionTarget + +Breadth of the approved increase; GROUP identifies an IdP group. + +## Example Usage + +```python +from glean.api_client.models import PlatformRequestResolutionTarget + +value = PlatformRequestResolutionTarget.USER + +# Open enum: unrecognized values are captured as UnrecognizedStr +``` + + +## Values + +| Name | Value | +| ------------ | ------------ | +| `USER` | USER | +| `ALL` | ALL | +| `DEPARTMENT` | DEPARTMENT | +| `GROUP` | GROUP | \ No newline at end of file diff --git a/docs/models/platformrequestresponse.md b/docs/models/platformrequestresponse.md new file mode 100644 index 00000000..899f22e8 --- /dev/null +++ b/docs/models/platformrequestresponse.md @@ -0,0 +1,11 @@ +# PlatformRequestResponse + +Single authorized request with the enclosing response's trace identifier. + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | +| `request` | [models.PlatformLimitIncreaseRequest](../models/platformlimitincreaserequest.md) | :heavy_check_mark: | Stored user or agent request, with optional resolution fields when available. | +| `request_id` | *str* | :heavy_check_mark: | Trace identifier, distinct from the resource ID. | \ No newline at end of file diff --git a/docs/models/platformrequestscope.md b/docs/models/platformrequestscope.md new file mode 100644 index 00000000..b6315e1a --- /dev/null +++ b/docs/models/platformrequestscope.md @@ -0,0 +1,21 @@ +# PlatformRequestScope + +Increase for the stored request month or an ongoing standing-rule increase. + +## Example Usage + +```python +from glean.api_client.models import PlatformRequestScope + +value = PlatformRequestScope.PERIOD + +# Open enum: unrecognized values are captured as UnrecognizedStr +``` + + +## Values + +| Name | Value | +| --------- | --------- | +| `PERIOD` | PERIOD | +| `ONGOING` | ONGOING | \ No newline at end of file diff --git a/docs/models/platformrequeststatus.md b/docs/models/platformrequeststatus.md new file mode 100644 index 00000000..654cf904 --- /dev/null +++ b/docs/models/platformrequeststatus.md @@ -0,0 +1,22 @@ +# PlatformRequestStatus + +Stored request state. + +## Example Usage + +```python +from glean.api_client.models import PlatformRequestStatus + +value = PlatformRequestStatus.PENDING + +# Open enum: unrecognized values are captured as UnrecognizedStr +``` + + +## Values + +| Name | Value | +| ---------- | ---------- | +| `PENDING` | PENDING | +| `APPROVED` | APPROVED | +| `DENIED` | DENIED | \ No newline at end of file diff --git a/docs/models/platformskill.md b/docs/models/platformskill.md index f803434a..3a68c65b 100644 --- a/docs/models/platformskill.md +++ b/docs/models/platformskill.md @@ -3,16 +3,16 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -| `id` | *str* | :heavy_check_mark: | Glean skill ID. | -| `display_name` | *str* | :heavy_check_mark: | Human-readable skill name. | -| `description` | *str* | :heavy_check_mark: | Human-readable skill description. | -| `latest_version` | *int* | :heavy_check_mark: | Latest major version number for the skill. | -| `latest_minor_version` | *int* | :heavy_check_mark: | Latest minor version number for the skill. | -| `status` | [models.PlatformSkillStatus](../models/platformskillstatus.md) | :heavy_check_mark: | Current skill status. | -| `origin` | [models.PlatformSkillOrigin](../models/platformskillorigin.md) | :heavy_check_mark: | Source category for the skill. | -| `source_provenance` | [Optional[models.PlatformSkillSourceProvenance]](../models/platformskillsourceprovenance.md) | :heavy_minus_sign: | N/A | -| `owner` | [models.PlatformPersonReference](../models/platformpersonreference.md) | :heavy_check_mark: | A lightweight reference to a person, used where a payload merely points at someone. | -| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | Time the skill was created. | -| `updated_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | Time the skill was last updated. | \ No newline at end of file +| Field | Type | Required | Description | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `skill_id` | *str* | :heavy_check_mark: | Glean skill ID. | +| `display_name` | *str* | :heavy_check_mark: | Human-readable skill name. | +| `description` | *str* | :heavy_check_mark: | Human-readable skill description. | +| `latest_version` | *int* | :heavy_check_mark: | Latest major version number for the skill. | +| `latest_minor_version` | *int* | :heavy_check_mark: | Latest minor version number for the skill. | +| `status` | [models.PlatformSkillStatus](../models/platformskillstatus.md) | :heavy_check_mark: | The caller's effective activation. The owner sees the skill's stored status. Another caller sees their personal setting, or DISABLED when they have none. DRAFT is the stored draft state and is not set by update. Effective activation may also reflect workspace governance policy.
| +| `origin` | [models.PlatformSkillOrigin](../models/platformskillorigin.md) | :heavy_check_mark: | Source category for the skill. | +| `source_provenance` | [Optional[models.PlatformSkillSourceProvenance]](../models/platformskillsourceprovenance.md) | :heavy_minus_sign: | N/A | +| `owner` | [models.PlatformPersonReference](../models/platformpersonreference.md) | :heavy_check_mark: | A lightweight reference to a person, used where a payload merely points at someone. | +| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | Time the skill was created. | +| `updated_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | Time the skill was last updated. | \ No newline at end of file diff --git a/docs/models/platformskillimportresponse.md b/docs/models/platformskillimportresponse.md index 9a383f20..079c091e 100644 --- a/docs/models/platformskillimportresponse.md +++ b/docs/models/platformskillimportresponse.md @@ -3,7 +3,7 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------- | -------------------------------------------------------- | -------------------------------------------------------- | -------------------------------------------------------- | -| `skills` | List[[models.PlatformSkill](../models/platformskill.md)] | :heavy_check_mark: | Independently persisted skills in request order. | -| `request_id` | *str* | :heavy_check_mark: | Platform-generated request ID for support correlation. | \ No newline at end of file +| Field | Type | Required | Description | +| --------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- | +| `skills` | List[[models.PlatformSkill](../models/platformskill.md)] | :heavy_check_mark: | Imported skills in request order. The import is atomic: either every source persists or none does.
| +| `request_id` | *str* | :heavy_check_mark: | Platform-generated request ID for support correlation. | \ No newline at end of file diff --git a/docs/models/platformskillorigin.md b/docs/models/platformskillorigin.md index ca7bf36f..c43dbe56 100644 --- a/docs/models/platformskillorigin.md +++ b/docs/models/platformskillorigin.md @@ -8,6 +8,8 @@ Source category for the skill. from glean.api_client.models import PlatformSkillOrigin value = PlatformSkillOrigin.CUSTOM + +# Open enum: unrecognized values are captured as UnrecognizedStr ``` @@ -15,4 +17,5 @@ value = PlatformSkillOrigin.CUSTOM | Name | Value | | -------- | -------- | -| `CUSTOM` | CUSTOM | \ No newline at end of file +| `CUSTOM` | CUSTOM | +| `GITHUB` | GITHUB | \ No newline at end of file diff --git a/docs/models/platformskillslistrequest.md b/docs/models/platformskillslistrequest.md index ebf0ada9..321617bd 100644 --- a/docs/models/platformskillslistrequest.md +++ b/docs/models/platformskillslistrequest.md @@ -3,7 +3,7 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -| `page_size` | *Optional[int]* | :heavy_minus_sign: | Maximum number of skills to return. | -| `cursor` | *Optional[str]* | :heavy_minus_sign: | Opaque pagination cursor from a previous response. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `page_size` | *Optional[int]* | :heavy_minus_sign: | Maximum number of skills to return. Defaults to 20. Maximum is 100. | +| `cursor` | *Optional[str]* | :heavy_minus_sign: | Opaque pagination cursor from a previous response. | \ No newline at end of file diff --git a/docs/models/platformskillslistresponse.md b/docs/models/platformskillslistresponse.md index 1adcf3fe..c880bd46 100644 --- a/docs/models/platformskillslistresponse.md +++ b/docs/models/platformskillslistresponse.md @@ -5,7 +5,7 @@ | Field | Type | Required | Description | | --------------------------------------------------------------------- | --------------------------------------------------------------------- | --------------------------------------------------------------------- | --------------------------------------------------------------------- | -| `skills` | List[[models.PlatformSkill](../models/platformskill.md)] | :heavy_check_mark: | Skills available to the user. | +| `results` | List[[models.PlatformSkill](../models/platformskill.md)] | :heavy_check_mark: | Skills available to the user. | | `has_more` | *bool* | :heavy_check_mark: | Whether additional results are available. | | `next_cursor` | *Nullable[str]* | :heavy_check_mark: | Cursor for the next page, or null when no more results are available. | | `request_id` | *str* | :heavy_check_mark: | Platform-generated request ID for support correlation. | \ No newline at end of file diff --git a/docs/models/platformskillslistversionsrequest.md b/docs/models/platformskillslistversionsrequest.md index a3fa36c9..75cd1177 100644 --- a/docs/models/platformskillslistversionsrequest.md +++ b/docs/models/platformskillslistversionsrequest.md @@ -3,8 +3,8 @@ ## Fields -| Field | Type | Required | Description | Example | -| -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -| `skill_id` | *str* | :heavy_check_mark: | Glean skill ID. | {skill_id} | -| `page_size` | *Optional[int]* | :heavy_minus_sign: | Maximum number of versions to return. | | -| `cursor` | *Optional[str]* | :heavy_minus_sign: | Opaque pagination cursor from a previous response. | | \ No newline at end of file +| Field | Type | Required | Description | Example | +| --------------------------------------------------------------------- | --------------------------------------------------------------------- | --------------------------------------------------------------------- | --------------------------------------------------------------------- | --------------------------------------------------------------------- | +| `skill_id` | *str* | :heavy_check_mark: | Glean skill ID. | {skill_id} | +| `page_size` | *Optional[int]* | :heavy_minus_sign: | Maximum number of versions to return. Defaults to 20. Maximum is 100. | | +| `cursor` | *Optional[str]* | :heavy_minus_sign: | Opaque pagination cursor from a previous response. | | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamerror.md b/docs/models/platformskillsourcepreviewstreamerror.md new file mode 100644 index 00000000..0de09b26 --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamerror.md @@ -0,0 +1,12 @@ +# PlatformSkillSourcePreviewStreamError + +Terminal failure event carrying the failure as a problem detail. Most GitHub authorization failures return HTTP 422 before the stream opens. If authorization fails after the stream opens, `error.code` is `tools_unauthorized` and `authentication_suggestions` is present. + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------- | +| `type` | [models.PlatformSkillSourcePreviewStreamErrorType](../models/platformskillsourcepreviewstreamerrortype.md) | :heavy_check_mark: | Event type, also sent as the SSE `event` name. | +| `error` | [models.PlatformProblemDetail](../models/platformproblemdetail.md) | :heavy_check_mark: | Error response following RFC 9457, extended with `code` and `documentation_url` for machine-readable classification and self-service remediation.
| +| `authentication_suggestions` | List[[models.PlatformAuthenticationSuggestion](../models/platformauthenticationsuggestion.md)] | :heavy_minus_sign: | Present only when `error.code` is `tools_unauthorized`. Names the GitHub action pack to authorize, with the same retry flow as the 422 response. | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamerrorserversentevent.md b/docs/models/platformskillsourcepreviewstreamerrorserversentevent.md new file mode 100644 index 00000000..0f2bab47 --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamerrorserversentevent.md @@ -0,0 +1,10 @@ +# PlatformSkillSourcePreviewStreamErrorServerSentEvent + + +## Fields + +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *Optional[str]* | :heavy_minus_sign: | N/A | +| `event` | *Literal["ERROR"]* | :heavy_check_mark: | N/A | +| `data` | [models.PlatformSkillSourcePreviewStreamError](../models/platformskillsourcepreviewstreamerror.md) | :heavy_check_mark: | Terminal failure event carrying the failure as a problem detail. Most GitHub authorization failures return HTTP 422 before the stream opens. If authorization fails after the stream opens, `error.code` is `tools_unauthorized` and `authentication_suggestions` is present. | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamerrortype.md b/docs/models/platformskillsourcepreviewstreamerrortype.md new file mode 100644 index 00000000..eaea8d89 --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamerrortype.md @@ -0,0 +1,18 @@ +# PlatformSkillSourcePreviewStreamErrorType + +Event type, also sent as the SSE `event` name. + +## Example Usage + +```python +from glean.api_client.models import PlatformSkillSourcePreviewStreamErrorType + +value = PlatformSkillSourcePreviewStreamErrorType.ERROR +``` + + +## Values + +| Name | Value | +| ------- | ------- | +| `ERROR` | ERROR | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreameventserversentevent.md b/docs/models/platformskillsourcepreviewstreameventserversentevent.md new file mode 100644 index 00000000..1a3ff6a8 --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreameventserversentevent.md @@ -0,0 +1,37 @@ +# PlatformSkillSourcePreviewStreamEventServerSentEvent + +A typed server-sent event. + + +## Supported Types + +### `models.PlatformSkillSourcePreviewStreamScanServerSentEvent` + +```python +value: models.PlatformSkillSourcePreviewStreamScanServerSentEvent = /* values here */ +``` + +### `models.PlatformSkillSourcePreviewStreamProgressServerSentEvent` + +```python +value: models.PlatformSkillSourcePreviewStreamProgressServerSentEvent = /* values here */ +``` + +### `models.PlatformSkillSourcePreviewStreamSkillServerSentEvent` + +```python +value: models.PlatformSkillSourcePreviewStreamSkillServerSentEvent = /* values here */ +``` + +### `models.PlatformSkillSourcePreviewStreamResultServerSentEvent` + +```python +value: models.PlatformSkillSourcePreviewStreamResultServerSentEvent = /* values here */ +``` + +### `models.PlatformSkillSourcePreviewStreamErrorServerSentEvent` + +```python +value: models.PlatformSkillSourcePreviewStreamErrorServerSentEvent = /* values here */ +``` + diff --git a/docs/models/platformskillsourcepreviewstreamprogress.md b/docs/models/platformskillsourcepreviewstreamprogress.md new file mode 100644 index 00000000..320e3d52 --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamprogress.md @@ -0,0 +1,13 @@ +# PlatformSkillSourcePreviewStreamProgress + +One skill finished inspecting; names the skill in progress. + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | +| `type` | [models.PlatformSkillSourcePreviewStreamProgressType](../models/platformskillsourcepreviewstreamprogresstype.md) | :heavy_check_mark: | Event type, also sent as the SSE `event` name. | +| `completed` | *int* | :heavy_check_mark: | Number of skills inspected so far. | +| `total` | *int* | :heavy_check_mark: | Number of skills to inspect. | +| `current_skill` | *str* | :heavy_check_mark: | Path of the skill being inspected. | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamprogressserversentevent.md b/docs/models/platformskillsourcepreviewstreamprogressserversentevent.md new file mode 100644 index 00000000..7f606311 --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamprogressserversentevent.md @@ -0,0 +1,10 @@ +# PlatformSkillSourcePreviewStreamProgressServerSentEvent + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | +| `id` | *Optional[str]* | :heavy_minus_sign: | N/A | +| `event` | *Literal["PROGRESS"]* | :heavy_check_mark: | N/A | +| `data` | [models.PlatformSkillSourcePreviewStreamProgress](../models/platformskillsourcepreviewstreamprogress.md) | :heavy_check_mark: | One skill finished inspecting; names the skill in progress. | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamprogresstype.md b/docs/models/platformskillsourcepreviewstreamprogresstype.md new file mode 100644 index 00000000..7a25cd48 --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamprogresstype.md @@ -0,0 +1,18 @@ +# PlatformSkillSourcePreviewStreamProgressType + +Event type, also sent as the SSE `event` name. + +## Example Usage + +```python +from glean.api_client.models import PlatformSkillSourcePreviewStreamProgressType + +value = PlatformSkillSourcePreviewStreamProgressType.PROGRESS +``` + + +## Values + +| Name | Value | +| ---------- | ---------- | +| `PROGRESS` | PROGRESS | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamresult.md b/docs/models/platformskillsourcepreviewstreamresult.md new file mode 100644 index 00000000..c778b257 --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamresult.md @@ -0,0 +1,11 @@ +# PlatformSkillSourcePreviewStreamResult + +Terminal success event carrying the fully assembled preview. + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------ | +| `type` | [models.PlatformSkillSourcePreviewStreamResultType](../models/platformskillsourcepreviewstreamresulttype.md) | :heavy_check_mark: | Event type, also sent as the SSE `event` name. | +| `response` | [models.PlatformSkillSourcePreviewResponse](../models/platformskillsourcepreviewresponse.md) | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamresultserversentevent.md b/docs/models/platformskillsourcepreviewstreamresultserversentevent.md new file mode 100644 index 00000000..fae2c0e8 --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamresultserversentevent.md @@ -0,0 +1,10 @@ +# PlatformSkillSourcePreviewStreamResultServerSentEvent + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | +| `id` | *Optional[str]* | :heavy_minus_sign: | N/A | +| `event` | *Literal["RESULT"]* | :heavy_check_mark: | N/A | +| `data` | [models.PlatformSkillSourcePreviewStreamResult](../models/platformskillsourcepreviewstreamresult.md) | :heavy_check_mark: | Terminal success event carrying the fully assembled preview. | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamresulttype.md b/docs/models/platformskillsourcepreviewstreamresulttype.md new file mode 100644 index 00000000..aae68d66 --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamresulttype.md @@ -0,0 +1,18 @@ +# PlatformSkillSourcePreviewStreamResultType + +Event type, also sent as the SSE `event` name. + +## Example Usage + +```python +from glean.api_client.models import PlatformSkillSourcePreviewStreamResultType + +value = PlatformSkillSourcePreviewStreamResultType.RESULT +``` + + +## Values + +| Name | Value | +| -------- | -------- | +| `RESULT` | RESULT | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamscan.md b/docs/models/platformskillsourcepreviewstreamscan.md new file mode 100644 index 00000000..c9705a55 --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamscan.md @@ -0,0 +1,12 @@ +# PlatformSkillSourcePreviewStreamScan + +Repository scan started; names every skill path found. + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- | +| `type` | [models.PlatformSkillSourcePreviewStreamScanType](../models/platformskillsourcepreviewstreamscantype.md) | :heavy_check_mark: | Event type, also sent as the SSE `event` name. | +| `total` | *int* | :heavy_check_mark: | Number of skill paths found in the scan. | +| `skill_paths` | List[*str*] | :heavy_check_mark: | Skill paths found in the scan. | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamscanserversentevent.md b/docs/models/platformskillsourcepreviewstreamscanserversentevent.md new file mode 100644 index 00000000..6b69806d --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamscanserversentevent.md @@ -0,0 +1,10 @@ +# PlatformSkillSourcePreviewStreamScanServerSentEvent + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | +| `id` | *Optional[str]* | :heavy_minus_sign: | N/A | +| `event` | *Literal["SCAN"]* | :heavy_check_mark: | N/A | +| `data` | [models.PlatformSkillSourcePreviewStreamScan](../models/platformskillsourcepreviewstreamscan.md) | :heavy_check_mark: | Repository scan started; names every skill path found. | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamscantype.md b/docs/models/platformskillsourcepreviewstreamscantype.md new file mode 100644 index 00000000..ba71c62a --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamscantype.md @@ -0,0 +1,18 @@ +# PlatformSkillSourcePreviewStreamScanType + +Event type, also sent as the SSE `event` name. + +## Example Usage + +```python +from glean.api_client.models import PlatformSkillSourcePreviewStreamScanType + +value = PlatformSkillSourcePreviewStreamScanType.SCAN +``` + + +## Values + +| Name | Value | +| ------ | ------ | +| `SCAN` | SCAN | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamskill.md b/docs/models/platformskillsourcepreviewstreamskill.md new file mode 100644 index 00000000..30f6225d --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamskill.md @@ -0,0 +1,11 @@ +# PlatformSkillSourcePreviewStreamSkill + +One skill previewed; carries the previewed skill. + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | +| `type` | [models.PlatformSkillSourcePreviewStreamSkillType](../models/platformskillsourcepreviewstreamskilltype.md) | :heavy_check_mark: | Event type, also sent as the SSE `event` name. | +| `skill` | [models.PlatformSkillSourcePreview](../models/platformskillsourcepreview.md) | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamskillserversentevent.md b/docs/models/platformskillsourcepreviewstreamskillserversentevent.md new file mode 100644 index 00000000..740b8380 --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamskillserversentevent.md @@ -0,0 +1,10 @@ +# PlatformSkillSourcePreviewStreamSkillServerSentEvent + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | +| `id` | *Optional[str]* | :heavy_minus_sign: | N/A | +| `event` | *Literal["SKILL"]* | :heavy_check_mark: | N/A | +| `data` | [models.PlatformSkillSourcePreviewStreamSkill](../models/platformskillsourcepreviewstreamskill.md) | :heavy_check_mark: | One skill previewed; carries the previewed skill. | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewstreamskilltype.md b/docs/models/platformskillsourcepreviewstreamskilltype.md new file mode 100644 index 00000000..512ad4ad --- /dev/null +++ b/docs/models/platformskillsourcepreviewstreamskilltype.md @@ -0,0 +1,18 @@ +# PlatformSkillSourcePreviewStreamSkillType + +Event type, also sent as the SSE `event` name. + +## Example Usage + +```python +from glean.api_client.models import PlatformSkillSourcePreviewStreamSkillType + +value = PlatformSkillSourcePreviewStreamSkillType.SKILL +``` + + +## Values + +| Name | Value | +| ------- | ------- | +| `SKILL` | SKILL | \ No newline at end of file diff --git a/docs/models/platformskillsourcepreviewrequest.md b/docs/models/platformskillspreviewsourcerequest.md similarity index 83% rename from docs/models/platformskillsourcepreviewrequest.md rename to docs/models/platformskillspreviewsourcerequest.md index 8d0b03a4..cabcbff8 100644 --- a/docs/models/platformskillsourcepreviewrequest.md +++ b/docs/models/platformskillspreviewsourcerequest.md @@ -1,4 +1,4 @@ -# PlatformSkillSourcePreviewRequest +# PlatformSkillsPreviewSourceRequest ## Fields @@ -6,4 +6,4 @@ | Field | Type | Required | Description | | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | | `source_url` | *str* | :heavy_check_mark: | GitHub URL for a skill directory, SKILL.md file, or repository to inspect. | -| `stream` | *Optional[bool]* | :heavy_minus_sign: | Whether to stream repository scan progress using server-sent events. | \ No newline at end of file +| `stream` | *Optional[Literal[False]]* | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/platformskillspreviewsourceresponse.md b/docs/models/platformskillspreviewsourceresponse.md deleted file mode 100644 index 2eabd1c4..00000000 --- a/docs/models/platformskillspreviewsourceresponse.md +++ /dev/null @@ -1,17 +0,0 @@ -# PlatformSkillsPreviewSourceResponse - - -## Supported Types - -### `models.PlatformSkillSourcePreviewResponse` - -```python -value: models.PlatformSkillSourcePreviewResponse = /* values here */ -``` - -### `str` - -```python -value: str = /* values here */ -``` - diff --git a/docs/models/platformskillspreviewsourcestreamrequest.md b/docs/models/platformskillspreviewsourcestreamrequest.md new file mode 100644 index 00000000..6d30247d --- /dev/null +++ b/docs/models/platformskillspreviewsourcestreamrequest.md @@ -0,0 +1,9 @@ +# PlatformSkillsPreviewSourceStreamRequest + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | +| `source_url` | *str* | :heavy_check_mark: | GitHub URL for a skill directory, SKILL.md file, or repository to inspect. | +| `stream` | *Optional[Literal[True]]* | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/platformskillstatus.md b/docs/models/platformskillstatus.md index 566f1092..b863a5eb 100644 --- a/docs/models/platformskillstatus.md +++ b/docs/models/platformskillstatus.md @@ -1,6 +1,7 @@ # PlatformSkillStatus -Current skill status. +The caller's effective activation. The owner sees the skill's stored status. Another caller sees their personal setting, or DISABLED when they have none. DRAFT is the stored draft state and is not set by update. Effective activation may also reflect workspace governance policy. + ## Example Usage diff --git a/docs/models/platformskillsyncresponse.md b/docs/models/platformskillsyncresponse.md index 03dbf807..a3e14115 100644 --- a/docs/models/platformskillsyncresponse.md +++ b/docs/models/platformskillsyncresponse.md @@ -3,9 +3,8 @@ ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | -| `sync_status` | [models.PlatformSkillSyncResultStatus](../models/platformskillsyncresultstatus.md) | :heavy_check_mark: | Synchronization status after a successful refresh. | -| `commit_sha` | *str* | :heavy_check_mark: | Git commit SHA now associated with the skill. | -| `updated` | *bool* | :heavy_check_mark: | Whether this request created a new skill version. | -| `request_id` | *str* | :heavy_check_mark: | Platform-generated request ID for support correlation. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------ | ------------------------------------------------------ | ------------------------------------------------------ | ------------------------------------------------------ | +| `commit_sha` | *str* | :heavy_check_mark: | Git commit SHA now associated with the skill. | +| `is_updated` | *bool* | :heavy_check_mark: | Whether this request created a new skill version. | +| `request_id` | *str* | :heavy_check_mark: | Platform-generated request ID for support correlation. | \ No newline at end of file diff --git a/docs/models/platformskillsyncresultstatus.md b/docs/models/platformskillsyncresultstatus.md deleted file mode 100644 index 764a5847..00000000 --- a/docs/models/platformskillsyncresultstatus.md +++ /dev/null @@ -1,18 +0,0 @@ -# PlatformSkillSyncResultStatus - -Synchronization status after a successful refresh. - -## Example Usage - -```python -from glean.api_client.models import PlatformSkillSyncResultStatus - -value = PlatformSkillSyncResultStatus.UP_TO_DATE -``` - - -## Values - -| Name | Value | -| ------------ | ------------ | -| `UP_TO_DATE` | UP_TO_DATE | \ No newline at end of file diff --git a/docs/models/platformskillupdaterequest.md b/docs/models/platformskillupdaterequest.md index 1d94bb0a..3f454aaa 100644 --- a/docs/models/platformskillupdaterequest.md +++ b/docs/models/platformskillupdaterequest.md @@ -3,6 +3,6 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -| `status` | [models.PlatformSkillUpdateStatus](../models/platformskillupdatestatus.md) | :heavy_check_mark: | New status for the skill. | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `status` | [models.PlatformSkillUpdateStatus](../models/platformskillupdatestatus.md) | :heavy_check_mark: | Activation to apply for the authenticated caller. For the owner, this updates the skill's stored status. For any other caller, it updates only that caller's setting.
| \ No newline at end of file diff --git a/docs/models/platformskillupdatestatus.md b/docs/models/platformskillupdatestatus.md index 898c434f..87187173 100644 --- a/docs/models/platformskillupdatestatus.md +++ b/docs/models/platformskillupdatestatus.md @@ -1,6 +1,7 @@ # PlatformSkillUpdateStatus -New status for the skill. +Activation to apply for the authenticated caller. For the owner, this updates the skill's stored status. For any other caller, it updates only that caller's setting. + ## Example Usage diff --git a/docs/models/platformskillversionslistresponse.md b/docs/models/platformskillversionslistresponse.md index edd94537..082388b1 100644 --- a/docs/models/platformskillversionslistresponse.md +++ b/docs/models/platformskillversionslistresponse.md @@ -5,7 +5,7 @@ | Field | Type | Required | Description | | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | -| `versions` | List[[models.PlatformSkillVersion](../models/platformskillversion.md)] | :heavy_check_mark: | Versions available for the skill. | +| `results` | List[[models.PlatformSkillVersion](../models/platformskillversion.md)] | :heavy_check_mark: | Versions available for the skill. | | `has_more` | *bool* | :heavy_check_mark: | Whether additional results are available. | | `next_cursor` | *Nullable[str]* | :heavy_check_mark: | Cursor for the next page, or null when no more results are available. | | `request_id` | *str* | :heavy_check_mark: | Platform-generated request ID for support correlation. | \ No newline at end of file diff --git a/docs/models/platformusagerequestsgetrequest.md b/docs/models/platformusagerequestsgetrequest.md new file mode 100644 index 00000000..47efb27a --- /dev/null +++ b/docs/models/platformusagerequestsgetrequest.md @@ -0,0 +1,8 @@ +# PlatformUsageRequestsGetRequest + + +## Fields + +| Field | Type | Required | Description | Example | +| --------------------------------------------------------------- | --------------------------------------------------------------- | --------------------------------------------------------------- | --------------------------------------------------------------- | --------------------------------------------------------------- | +| `request_id` | *str* | :heavy_check_mark: | Opaque personal request identifier; not an authorization grant. | {request_id} | \ No newline at end of file diff --git a/docs/models/platformusagerequestslistrequest.md b/docs/models/platformusagerequestslistrequest.md new file mode 100644 index 00000000..37da7f2c --- /dev/null +++ b/docs/models/platformusagerequestslistrequest.md @@ -0,0 +1,10 @@ +# PlatformUsageRequestsListRequest + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | +| `page_size` | *Optional[int]* | :heavy_minus_sign: | Maximum page size; defaults to 20 and cannot exceed 100. | +| `cursor` | *Optional[str]* | :heavy_minus_sign: | Opaque continuation bound to filters and current authorization. | +| `filters` | List[[models.PlatformRequestFilter](../models/platformrequestfilter.md)] | :heavy_minus_sign: | Optional structured filters on request status. | \ No newline at end of file diff --git a/docs/models/platformusagesettingsresource.md b/docs/models/platformusagesettingsresource.md new file mode 100644 index 00000000..6b0aec03 --- /dev/null +++ b/docs/models/platformusagesettingsresource.md @@ -0,0 +1,13 @@ +# PlatformUsageSettingsResource + +Workspace-wide usage settings. + + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | +| `multiple_membership_resolution` | [Optional[models.PlatformMultipleMembershipResolutionSettings]](../models/platformmultiplemembershipresolutionsettings.md) | :heavy_minus_sign: | Settings for resolving limits across multiple memberships. | +| `limit_increase_requests` | [Optional[models.PlatformLimitIncreaseRequestSettings]](../models/platformlimitincreaserequestsettings.md) | :heavy_minus_sign: | Settings that govern usage limit increase requests.
| +| `updated_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | ISO 8601 timestamp of the last settings update.
| \ No newline at end of file diff --git a/docs/models/platformusagesettingsresponse.md b/docs/models/platformusagesettingsresponse.md new file mode 100644 index 00000000..e05699c1 --- /dev/null +++ b/docs/models/platformusagesettingsresponse.md @@ -0,0 +1,12 @@ +# PlatformUsageSettingsResponse + +Response envelope for usage settings operations. + + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | +| `usage_settings` | [models.PlatformUsageSettingsResource](../models/platformusagesettingsresource.md) | :heavy_check_mark: | Workspace-wide usage settings.
| +| `request_id` | *str* | :heavy_check_mark: | Opaque request identifier.
| \ No newline at end of file diff --git a/docs/models/platformusagesettingsupdaterequest1.md b/docs/models/platformusagesettingsupdaterequest1.md new file mode 100644 index 00000000..56421737 --- /dev/null +++ b/docs/models/platformusagesettingsupdaterequest1.md @@ -0,0 +1,9 @@ +# PlatformUsageSettingsUpdateRequest1 + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | +| `multiple_membership_resolution` | [models.PlatformMultipleMembershipResolutionSettings](../models/platformmultiplemembershipresolutionsettings.md) | :heavy_check_mark: | Settings for resolving limits across multiple memberships. | +| `limit_increase_requests` | [Optional[models.PlatformLimitIncreaseRequestSettings]](../models/platformlimitincreaserequestsettings.md) | :heavy_minus_sign: | Settings that govern usage limit increase requests.
| \ No newline at end of file diff --git a/docs/models/platformusagesettingsupdaterequest2.md b/docs/models/platformusagesettingsupdaterequest2.md new file mode 100644 index 00000000..863e66c8 --- /dev/null +++ b/docs/models/platformusagesettingsupdaterequest2.md @@ -0,0 +1,9 @@ +# PlatformUsageSettingsUpdateRequest2 + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | +| `multiple_membership_resolution` | [Optional[models.PlatformMultipleMembershipResolutionSettings]](../models/platformmultiplemembershipresolutionsettings.md) | :heavy_minus_sign: | Settings for resolving limits across multiple memberships. | +| `limit_increase_requests` | [models.PlatformLimitIncreaseRequestSettings](../models/platformlimitincreaserequestsettings.md) | :heavy_check_mark: | Settings that govern usage limit increase requests.
| \ No newline at end of file diff --git a/docs/models/platformusagesettingsupdaterequestunion.md b/docs/models/platformusagesettingsupdaterequestunion.md new file mode 100644 index 00000000..7709ab53 --- /dev/null +++ b/docs/models/platformusagesettingsupdaterequestunion.md @@ -0,0 +1,20 @@ +# PlatformUsageSettingsUpdateRequestUnion + +Request body for updating workspace-wide usage settings. + + + +## Supported Types + +### `models.PlatformUsageSettingsUpdateRequest1` + +```python +value: models.PlatformUsageSettingsUpdateRequest1 = /* values here */ +``` + +### `models.PlatformUsageSettingsUpdateRequest2` + +```python +value: models.PlatformUsageSettingsUpdateRequest2 = /* values here */ +``` + diff --git a/docs/models/ugctype.md b/docs/models/ugctype.md index edccbd16..eeb95b91 100644 --- a/docs/models/ugctype.md +++ b/docs/models/ugctype.md @@ -35,4 +35,5 @@ value = UgcType.AGENT_TYPE | `SPREADSHEET_TYPE` | SPREADSHEET_TYPE | | `INLINE_HTML_TYPE` | INLINE_HTML_TYPE | | `PODCAST_TYPE` | PODCAST_TYPE | +| `VIDEO_TYPE` | VIDEO_TYPE | | `WORKFLOWS_TYPE` | WORKFLOWS_TYPE | \ No newline at end of file diff --git a/docs/sdks/adminusage/README.md b/docs/sdks/adminusage/README.md new file mode 100644 index 00000000..c00bad58 --- /dev/null +++ b/docs/sdks/adminusage/README.md @@ -0,0 +1,238 @@ +# Admin.Usage + +## Overview + +### Available Operations + +* [get_settings](#get_settings) - Get usage settings +* [update_settings](#update_settings) - Update usage settings +* [create_limit_increase_request](#create_limit_increase_request) - Submit an editable-agent limit-increase request +* [list_limit_increase_requests](#list_limit_increase_requests) - List the billing limit-increase request queue +* [get_limit_increase_request](#get_limit_increase_request) - Get a billing limit-increase request + +## get_settings + +Retrieve workspace-wide usage settings. Requires admin.usage.settings:read and permission to read workspace billing; a global administrator role is not required. + + +### Example Usage + + +```python +from glean.api_client import Glean +import os + + +with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), +) as glean: + + res = glean.admin.usage.get_settings() + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.PlatformUsageSettingsResponse](../../models/platformusagesettingsresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | + +## update_settings + +Partially update workspace-wide usage settings. Requires admin.usage.settings:write and permission to edit workspace billing; a global administrator role is not required. + + +### Example Usage + + +```python +from glean.api_client import Glean, models +import os + + +with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), +) as glean: + + res = glean.admin.usage.update_settings(request={ + "multiple_membership_resolution": { + "per_member": { + "idp_groups": models.IdpGroups.HIGHEST, + }, + }, + "limit_increase_requests": { + "business_justification": models.BusinessJustification.REQUIRED, + }, + }) + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| --------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------- | +| `request` | [models.PlatformUsageSettingsUpdateRequestUnion](../../models/platformusagesettingsupdaterequestunion.md) | :heavy_check_mark: | The request object to use for the request. | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.PlatformUsageSettingsResponse](../../models/platformusagesettingsresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 413, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | + +## create_limit_increase_request + +Requires usage.limit_increase_requests:write, the same scope as personal creation, and current edit permission on the agent, not billing permissions. The caller supplies the agent, client, and optional business justification. Requester identity comes from authentication; the server assigns the request identifier and current UTC month. This internal scaffold returns 503 without creating a request. + + +### Example Usage + + +```python +from glean.api_client import Glean +import os + + +with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), +) as glean: + + res = glean.admin.usage.create_limit_increase_request(agent_id="{agent_id}", client_id="glean") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `agent_id` | *str* | :heavy_check_mark: | Identifier of the agent whose limit the request concerns. | +| `client_id` | *str* | :heavy_check_mark: | Explicit spend client whose limit the request concerns. | +| `business_justification` | *Optional[str]* | :heavy_minus_sign: | Optional explanation of why the increase is needed. | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.PlatformRequestResponse](../../models/platformrequestresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 409, 413, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | + +## list_limit_increase_requests + +Requires admin.usage.limit_increase_requests:read and current workspace billing read permission. Agent ownership is not queue access. Cursors bind filters and current authorization context. This internal scaffold returns 503, not a successful empty page. + + +### Example Usage + + +```python +from glean.api_client import Glean +import os + + +with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), +) as glean: + + res = glean.admin.usage.list_limit_increase_requests(page_size=20) + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | +| `page_size` | *Optional[int]* | :heavy_minus_sign: | Maximum page size; defaults to 20 and cannot exceed 100. | +| `cursor` | *Optional[str]* | :heavy_minus_sign: | Opaque continuation bound to filters and current authorization. | +| `filters` | List[[models.PlatformRequestFilter](../../models/platformrequestfilter.md)] | :heavy_minus_sign: | Optional structured filters on request status. | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.PlatformRequestListResponseUnion](../../models/platformrequestlistresponseunion.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | + +## get_limit_increase_request + +Requires admin.usage.limit_increase_requests:read. Authorization precedes resource disclosure. This internal scaffold returns 503 without reading the request. + + +### Example Usage + + +```python +from glean.api_client import Glean +import os + + +with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), +) as glean: + + res = glean.admin.usage.get_limit_increase_request(request_id="{request_id}") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `request_id` | *str* | :heavy_check_mark: | Opaque request identifier; not an authorization grant. | {request_id} | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | + +### Response + +**[models.PlatformRequestResponse](../../models/platformrequestresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/docs/sdks/entities/README.md b/docs/sdks/entities/README.md index 55516c7d..a5c95e0e 100644 --- a/docs/sdks/entities/README.md +++ b/docs/sdks/entities/README.md @@ -88,7 +88,7 @@ with Glean( api_token=os.getenv("GLEAN_API_TOKEN", ""), ) as glean: - res = glean.client.entities.read_people(obfuscated_ids=[ + res = glean.client.entities.read_people(fallback_to_authenticated_identity=False, obfuscated_ids=[ "abc123", "abc456", ]) @@ -100,16 +100,17 @@ with Glean( ### Parameters -| Parameter | Type | Required | Description | -| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `locale` | *Optional[str]* | :heavy_minus_sign: | The client's preferred locale in rfc5646 format (e.g. `en`, `ja`, `pt-BR`). If omitted, the `Accept-Language` will be used. If not present or not supported, defaults to the closest match or `en`. | -| `timezone_offset` | *Optional[int]* | :heavy_minus_sign: | The offset of the client's timezone in minutes from UTC. e.g. PDT is -420 because it's 7 hours behind UTC. | -| `obfuscated_ids` | List[*str*] | :heavy_minus_sign: | The Person IDs to retrieve. If no IDs are requested, the current user's details are returned. | -| `email_ids` | List[*str*] | :heavy_minus_sign: | The email IDs to retrieve. The result is the deduplicated union of emailIds and obfuscatedIds. | -| `include_fields` | List[[models.PeopleRequestIncludeField](../../models/peoplerequestincludefield.md)] | :heavy_minus_sign: | List of PersonMetadata fields to return (that aren't returned by default) | -| `include_types` | List[[models.IncludeType](../../models/includetype.md)] | :heavy_minus_sign: | The types of people entities to include in the response in addition to those returned by default. | -| `source` | *Optional[str]* | :heavy_minus_sign: | A string denoting the search surface from which the endpoint is called. | -| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | +| Parameter | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `locale` | *Optional[str]* | :heavy_minus_sign: | The client's preferred locale in rfc5646 format (e.g. `en`, `ja`, `pt-BR`). If omitted, the `Accept-Language` will be used. If not present or not supported, defaults to the closest match or `en`. | +| `fallback_to_authenticated_identity` | *Optional[bool]* | :heavy_minus_sign: | If true and the current user's people profile is missing, reads the stored SSO profile and returns a minimal Person with its display name, the authenticated user's email, the same obfuscatedId used by a normal self-lookup, and identityOnly set to true. If the SSO profile or its name is unavailable, preserves the missing-profile error. Applies only when emailIds and obfuscatedIds are empty and the request doesn't use act-as, a virtual identity, anonymous authentication, or the INVALID_ENTITIES includeType. The fallback doesn't mask lookup or enrichment errors and doesn't create a directory profile. Normal people profiles don't require an SSO lookup. | +| `timezone_offset` | *Optional[int]* | :heavy_minus_sign: | The offset of the client's timezone in minutes from UTC. e.g. PDT is -420 because it's 7 hours behind UTC. | +| `obfuscated_ids` | List[*str*] | :heavy_minus_sign: | The Person IDs to retrieve. If no IDs are requested, the current user's details are returned. | +| `email_ids` | List[*str*] | :heavy_minus_sign: | The email IDs to retrieve. The result is the deduplicated union of emailIds and obfuscatedIds. | +| `include_fields` | List[[models.PeopleRequestIncludeField](../../models/peoplerequestincludefield.md)] | :heavy_minus_sign: | List of PersonMetadata fields to return (that aren't returned by default) | +| `include_types` | List[[models.IncludeType](../../models/includetype.md)] | :heavy_minus_sign: | The types of people entities to include in the response in addition to those returned by default. | +| `source` | *Optional[str]* | :heavy_minus_sign: | A string denoting the search surface from which the endpoint is called. | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | ### Response diff --git a/docs/sdks/skills/README.md b/docs/sdks/skills/README.md index 7a11b9bc..6c9d5b42 100644 --- a/docs/sdks/skills/README.md +++ b/docs/sdks/skills/README.md @@ -18,10 +18,11 @@ * [list_versions](#list_versions) - List skill versions * [retrieve_version](#retrieve_version) - Retrieve skill version * [retrieve_version_content](#retrieve_version_content) - Download skill version content +* [preview_source_stream](#preview_source_stream) - Preview a GitHub skill source as events ## create -Create a skill from an uploaded SKILL.md, .zip, or .skill bundle. If the authenticated user already has a skill with the same name, the existing skill is superseded with a new version. +Create a skill from an uploaded SKILL.md, .zip, or .skill bundle. If the authenticated user already has a skill with the same name, the existing skill is superseded with a new version, unless it is source-managed: a same-name create over a GitHub-imported skill returns 409, and the caller syncs the existing skill instead. Two concurrent same-name creates can still produce two skills. ### Example Usage @@ -59,15 +60,15 @@ with Glean( ### Errors -| Error Type | Status Code | Content Type | -| --------------------------------- | --------------------------------- | --------------------------------- | -| errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 413, 429 | application/problem+json | -| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | -| errors.GleanError | 4XX, 5XX | \*/\* | +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 409, 413, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | ## list -List skills available to the authenticated user. +List every custom skill the authenticated caller can access. Built-in skills are excluded: they have no versions, content download, update, or delete, so their identifiers would fail most skill operations. Chat-authored skills shared with the caller without a listed grant are omitted: they stay retrievable by identifier when it is known, but this list does not discover them. ### Example Usage @@ -82,7 +83,7 @@ with Glean( api_token=os.getenv("GLEAN_API_TOKEN", ""), ) as glean: - res = glean.skills.list() + res = glean.skills.list(page_size=20) # Handle response print(res) @@ -93,7 +94,7 @@ with Glean( | Parameter | Type | Required | Description | | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | -| `page_size` | *Optional[int]* | :heavy_minus_sign: | Maximum number of skills to return. | +| `page_size` | *Optional[int]* | :heavy_minus_sign: | Maximum number of skills to return. Defaults to 20. Maximum is 100. | | `cursor` | *Optional[str]* | :heavy_minus_sign: | Opaque pagination cursor from a previous response. | | `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | @@ -148,11 +149,12 @@ with Glean( ### Errors -| Error Type | Status Code | Content Type | -| --------------------------------- | --------------------------------- | --------------------------------- | -| errors.PlatformProblemDetailError | 400, 401, 403, 408, 409, 413, 429 | application/problem+json | -| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | -| errors.GleanError | 4XX, 5XX | \*/\* | +| Error Type | Status Code | Content Type | +| ------------------------------------------------- | ------------------------------------------------- | ------------------------------------------------- | +| errors.PlatformUnauthorizedAgentToolsProblemError | 422 | application/problem+json | +| errors.PlatformProblemDetailError | 400, 401, 403, 408, 409, 413, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | ## validate @@ -217,7 +219,7 @@ with Glean( api_token=os.getenv("GLEAN_API_TOKEN", ""), ) as glean: - res = glean.skills.preview_source(source_url="https://github.com/anthropics/skills", stream=False) + res = glean.skills.preview_source(source_url="https://github.com/anthropics/skills") # Handle response print(res) @@ -229,24 +231,24 @@ with Glean( | Parameter | Type | Required | Description | | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | | `source_url` | *str* | :heavy_check_mark: | GitHub URL for a skill directory, SKILL.md file, or repository to inspect. | -| `stream` | *Optional[bool]* | :heavy_minus_sign: | Whether to stream repository scan progress using server-sent events. | | `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | ### Response -**[models.PlatformSkillsPreviewSourceResponse](../../models/platformskillspreviewsourceresponse.md)** +**[models.PlatformSkillSourcePreviewResponse](../../models/platformskillsourcepreviewresponse.md)** ### Errors -| Error Type | Status Code | Content Type | -| --------------------------------- | --------------------------------- | --------------------------------- | -| errors.PlatformProblemDetailError | 400, 401, 403, 408, 413, 429 | application/problem+json | -| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | -| errors.GleanError | 4XX, 5XX | \*/\* | +| Error Type | Status Code | Content Type | +| ------------------------------------------------- | ------------------------------------------------- | ------------------------------------------------- | +| errors.PlatformUnauthorizedAgentToolsProblemError | 422 | application/problem+json | +| errors.PlatformProblemDetailError | 400, 401, 403, 408, 413, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | ## update -Update mutable metadata for a skill. V1 supports enabling or disabling a skill without changing its content. +Enable or disable the skill for the authenticated caller without changing its content. The owner's update sets the skill's stored status. Any other caller's update applies only to that caller. ### Example Usage @@ -270,11 +272,11 @@ with Glean( ### Parameters -| Parameter | Type | Required | Description | Example | -| ----------------------------------------------------------------------------- | ----------------------------------------------------------------------------- | ----------------------------------------------------------------------------- | ----------------------------------------------------------------------------- | ----------------------------------------------------------------------------- | -| `skill_id` | *str* | :heavy_check_mark: | Glean skill ID. | {skill_id} | -| `status` | [models.PlatformSkillUpdateStatus](../../models/platformskillupdatestatus.md) | :heavy_check_mark: | New status for the skill. | | -| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | +| Parameter | Type | Required | Description | Example | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `skill_id` | *str* | :heavy_check_mark: | Glean skill ID. | {skill_id} | +| `status` | [models.PlatformSkillUpdateStatus](../../models/platformskillupdatestatus.md) | :heavy_check_mark: | Activation to apply for the authenticated caller. For the owner, this updates the skill's stored status. For any other caller, it updates only that caller's setting.
| | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | ### Response @@ -449,15 +451,16 @@ with Glean( ### Errors -| Error Type | Status Code | Content Type | -| -------------------------------------- | -------------------------------------- | -------------------------------------- | -| errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 409, 413, 429 | application/problem+json | -| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | -| errors.GleanError | 4XX, 5XX | \*/\* | +| Error Type | Status Code | Content Type | +| ------------------------------------------------- | ------------------------------------------------- | ------------------------------------------------- | +| errors.PlatformUnauthorizedAgentToolsProblemError | 422 | application/problem+json | +| errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 409, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | ## create_version -Create a new immutable version for an existing caller-managed skill from an uploaded SKILL.md, .zip, or .skill bundle. +Create a new immutable version for an existing caller-managed skill from an uploaded SKILL.md, .zip, or .skill bundle. A create-version over a GitHub-imported skill returns 409, and the caller syncs the existing skill instead. ### Example Usage @@ -519,7 +522,7 @@ with Glean( api_token=os.getenv("GLEAN_API_TOKEN", ""), ) as glean: - res = glean.skills.list_versions(skill_id="{skill_id}") + res = glean.skills.list_versions(skill_id="{skill_id}", page_size=20) # Handle response print(res) @@ -528,12 +531,12 @@ with Glean( ### Parameters -| Parameter | Type | Required | Description | Example | -| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | -| `skill_id` | *str* | :heavy_check_mark: | Glean skill ID. | {skill_id} | -| `page_size` | *Optional[int]* | :heavy_minus_sign: | Maximum number of versions to return. | | -| `cursor` | *Optional[str]* | :heavy_minus_sign: | Opaque pagination cursor from a previous response. | | -| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | +| Parameter | Type | Required | Description | Example | +| --------------------------------------------------------------------- | --------------------------------------------------------------------- | --------------------------------------------------------------------- | --------------------------------------------------------------------- | --------------------------------------------------------------------- | +| `skill_id` | *str* | :heavy_check_mark: | Glean skill ID. | {skill_id} | +| `page_size` | *Optional[int]* | :heavy_minus_sign: | Maximum number of versions to return. Defaults to 20. Maximum is 100. | | +| `cursor` | *Optional[str]* | :heavy_minus_sign: | Opaque pagination cursor from a previous response. | | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | ### Response @@ -633,4 +636,50 @@ with Glean( | --------------------------------- | --------------------------------- | --------------------------------- | | errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 429 | application/problem+json | | errors.PlatformProblemDetailError | 500, 503 | application/problem+json | -| errors.GleanError | 4XX, 5XX | \*/\* | \ No newline at end of file +| errors.GleanError | 4XX, 5XX | \*/\* | + +## preview_source_stream + +SDK-only logical operation. HTTP clients must call the base path; the URL fragment is not sent. Inspect a GitHub URL as server-sent events. HTTP clients request this mode by setting `stream` to true in the JSON body. + + +### Example Usage + + +```python +from glean.api_client import Glean +import os + + +with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), +) as glean: + + res = glean.skills.preview_source_stream(source_url="https://github.com/anthropics/skills") + + with res as event_stream: + for event in event_stream: + # handle event + print(event, flush=True) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | +| `source_url` | *str* | :heavy_check_mark: | GitHub URL for a skill directory, SKILL.md file, or repository to inspect. | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[Union[eventstreaming.EventStream[models.PlatformSkillSourcePreviewStreamEventServerSentEvent], eventstreaming.EventStreamAsync[models.PlatformSkillSourcePreviewStreamEventServerSentEvent]]](../../models/.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------------------------- | ------------------------------------------------- | ------------------------------------------------- | +| errors.PlatformUnauthorizedAgentToolsProblemError | 422 | application/problem+json | +| errors.PlatformProblemDetailError | 400, 401, 403, 408, 413, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/docs/sdks/usage/README.md b/docs/sdks/usage/README.md new file mode 100644 index 00000000..2e8f5c3b --- /dev/null +++ b/docs/sdks/usage/README.md @@ -0,0 +1,141 @@ +# Usage + +## Overview + +### Available Operations + +* [create_limit_increase_request](#create_limit_increase_request) - Submit a personal limit-increase request +* [list_limit_increase_requests](#list_limit_increase_requests) - List personal limit-increase requests +* [get_limit_increase_request](#get_limit_increase_request) - Get a personal limit-increase request + +## create_limit_increase_request + +Requires usage.limit_increase_requests:write. The target is the authenticated canonical user, and requester identity comes from authentication. The caller supplies the client and optional business justification. The server assigns the request identifier and current UTC month. Billing grants do not widen this route. This internal scaffold returns 503 without creating a request. + + +### Example Usage + + +```python +from glean.api_client import Glean +import os + + +with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), +) as glean: + + res = glean.usage.create_limit_increase_request(client_id="glean") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `client_id` | *str* | :heavy_check_mark: | Explicit spend client whose limit the request concerns. | +| `business_justification` | *Optional[str]* | :heavy_minus_sign: | Optional explanation of why the increase is needed. | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.PlatformRequestResponse](../../models/platformrequestresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------------------- | -------------------------------------- | -------------------------------------- | +| errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 409, 413, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | + +## list_limit_increase_requests + +Requires usage.limit_increase_requests:read. The collection is limited to the authenticated canonical user's requests, including resolved requests. Cursors bind the filters and current authorization context; a billing grant cannot widen results. This internal scaffold returns 503 without reading requests. + + +### Example Usage + + +```python +from glean.api_client import Glean +import os + + +with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), +) as glean: + + res = glean.usage.list_limit_increase_requests(page_size=20) + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | +| `page_size` | *Optional[int]* | :heavy_minus_sign: | Maximum page size; defaults to 20 and cannot exceed 100. | +| `cursor` | *Optional[str]* | :heavy_minus_sign: | Opaque continuation bound to filters and current authorization. | +| `filters` | List[[models.PlatformRequestFilter](../../models/platformrequestfilter.md)] | :heavy_minus_sign: | Optional structured filters on request status. | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.PlatformRequestListResponseUnion](../../models/platformrequestlistresponseunion.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | + +## get_limit_increase_request + +Requires usage.limit_increase_requests:read and the current user's request. Authorization precedes resource disclosure. This internal scaffold returns 503 without reading the request. + + +### Example Usage + + +```python +from glean.api_client import Glean +import os + + +with Glean( + api_token=os.getenv("GLEAN_API_TOKEN", ""), +) as glean: + + res = glean.usage.get_limit_increase_request(request_id="{request_id}") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | Example | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `request_id` | *str* | :heavy_check_mark: | Opaque personal request identifier; not an authorization grant. | {request_id} | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | | + +### Response + +**[models.PlatformRequestResponse](../../models/platformrequestresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| --------------------------------- | --------------------------------- | --------------------------------- | +| errors.PlatformProblemDetailError | 400, 401, 403, 404, 408, 429 | application/problem+json | +| errors.PlatformProblemDetailError | 500, 503 | application/problem+json | +| errors.GleanError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index b7cb0276..c6ffa3b5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ [project] name = "glean-api-client" -version = "0.17.15" +version = "0.17.16" 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 4af11e8e..ce7e0a16 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.17.15" +__version__: str = "0.17.16" __openapi_doc_version__: str = "0.9.0" -__gen_version__: str = "2.938.0" -__user_agent__: str = "speakeasy-sdk/python 0.17.15 2.938.0 0.9.0 glean-api-client" +__gen_version__: str = "2.943.0" +__user_agent__: str = "speakeasy-sdk/python 0.17.16 2.943.0 0.9.0 glean-api-client" try: if __package__ is not None: diff --git a/src/glean/api_client/admin.py b/src/glean/api_client/admin.py new file mode 100644 index 00000000..c4b19123 --- /dev/null +++ b/src/glean/api_client/admin.py @@ -0,0 +1,20 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from .basesdk import BaseSDK +from .sdkconfiguration import SDKConfiguration +from glean.api_client.admin_usage import AdminUsage +from typing import Optional + + +class Admin(BaseSDK): + usage: AdminUsage + + def __init__( + self, sdk_config: SDKConfiguration, parent_ref: Optional[object] = None + ) -> None: + BaseSDK.__init__(self, sdk_config, parent_ref=parent_ref) + self.sdk_configuration = sdk_config + self._init_sdks() + + def _init_sdks(self): + self.usage = AdminUsage(self.sdk_configuration, parent_ref=self.parent_ref) diff --git a/src/glean/api_client/admin_usage.py b/src/glean/api_client/admin_usage.py new file mode 100644 index 00000000..9abd018f --- /dev/null +++ b/src/glean/api_client/admin_usage.py @@ -0,0 +1,1197 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from .basesdk import BaseSDK +from glean.api_client import errors, models, utils +from glean.api_client._hooks import HookContext +from glean.api_client.types import BaseModel, OptionalNullable, UNSET +from glean.api_client.utils import get_security_from_env +from glean.api_client.utils.unmarshal_json_response import unmarshal_json_response +from typing import Any, Iterable, List, Mapping, Optional, Union, cast + + +class AdminUsage(BaseSDK): + def get_settings( + self, + *, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformUsageSettingsResponse: + r"""Get usage settings + + Retrieve workspace-wide usage settings. Requires admin.usage.settings:read and permission to read workspace billing; a global administrator role is not required. + + + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + req = self._build_request( + method="GET", + path="/api/admin/usage/settings", + base_url=base_url, + url_variables=url_variables, + request=None, + request_body_required=False, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-admin-usage-settings-get", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "8f4c2d6e-3b7a-4e1f-9c8d-5a2b6e4f7c9a", + "introduced": "2026-09-14", + }, + "x-glean-scopes": { + "legacy": ["ADMIN_USAGE"], + "platform": ["admin.usage.settings:read"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response( + models.PlatformUsageSettingsResponse, http_res + ) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + async def get_settings_async( + self, + *, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformUsageSettingsResponse: + r"""Get usage settings + + Retrieve workspace-wide usage settings. Requires admin.usage.settings:read and permission to read workspace billing; a global administrator role is not required. + + + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + req = self._build_request_async( + method="GET", + path="/api/admin/usage/settings", + base_url=base_url, + url_variables=url_variables, + request=None, + request_body_required=False, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-admin-usage-settings-get", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "8f4c2d6e-3b7a-4e1f-9c8d-5a2b6e4f7c9a", + "introduced": "2026-09-14", + }, + "x-glean-scopes": { + "legacy": ["ADMIN_USAGE"], + "platform": ["admin.usage.settings:read"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response( + models.PlatformUsageSettingsResponse, http_res + ) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + def update_settings( + self, + *, + request: Union[ + models.PlatformUsageSettingsUpdateRequestUnion, + models.PlatformUsageSettingsUpdateRequestUnionTypedDict, + ], + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformUsageSettingsResponse: + r"""Update usage settings + + Partially update workspace-wide usage settings. Requires admin.usage.settings:write and permission to edit workspace billing; a global administrator role is not required. + + + :param request: The request object to send. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + if not isinstance(request, BaseModel): + request = utils.unmarshal( + request, models.PlatformUsageSettingsUpdateRequestUnion + ) + request = cast(models.PlatformUsageSettingsUpdateRequestUnion, request) + + req = self._build_request( + method="PATCH", + path="/api/admin/usage/settings", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request, + False, + False, + "json", + models.PlatformUsageSettingsUpdateRequestUnion, + ), + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-admin-usage-settings-update", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "443aeb3c-fdee-4da8-a756-37fa13922830", + "introduced": "2026-09-14", + }, + "x-glean-scopes": { + "legacy": ["ADMIN_USAGE"], + "platform": ["admin.usage.settings:write"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response( + models.PlatformUsageSettingsResponse, http_res + ) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "413", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + async def update_settings_async( + self, + *, + request: Union[ + models.PlatformUsageSettingsUpdateRequestUnion, + models.PlatformUsageSettingsUpdateRequestUnionTypedDict, + ], + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformUsageSettingsResponse: + r"""Update usage settings + + Partially update workspace-wide usage settings. Requires admin.usage.settings:write and permission to edit workspace billing; a global administrator role is not required. + + + :param request: The request object to send. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + if not isinstance(request, BaseModel): + request = utils.unmarshal( + request, models.PlatformUsageSettingsUpdateRequestUnion + ) + request = cast(models.PlatformUsageSettingsUpdateRequestUnion, request) + + req = self._build_request_async( + method="PATCH", + path="/api/admin/usage/settings", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request, + False, + False, + "json", + models.PlatformUsageSettingsUpdateRequestUnion, + ), + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-admin-usage-settings-update", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "443aeb3c-fdee-4da8-a756-37fa13922830", + "introduced": "2026-09-14", + }, + "x-glean-scopes": { + "legacy": ["ADMIN_USAGE"], + "platform": ["admin.usage.settings:write"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response( + models.PlatformUsageSettingsResponse, http_res + ) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "413", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + def create_limit_increase_request( + self, + *, + agent_id: str, + client_id: str, + business_justification: Optional[str] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformRequestResponse: + r"""Submit an editable-agent limit-increase request + + Requires usage.limit_increase_requests:write, the same scope as personal creation, and current edit permission on the agent, not billing permissions. The caller supplies the agent, client, and optional business justification. Requester identity comes from authentication; the server assigns the request identifier and current UTC month. This internal scaffold returns 503 without creating a request. + + + :param agent_id: Identifier of the agent whose limit the request concerns. + :param client_id: Explicit spend client whose limit the request concerns. + :param business_justification: Optional explanation of why the increase is needed. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformAgentRequestCreate( + agent_id=agent_id, + client_id=client_id, + business_justification=business_justification, + ) + + req = self._build_request( + method="POST", + path="/api/admin/usage/limit-increase-requests", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request, False, False, "json", models.PlatformAgentRequestCreate + ), + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-admin-usage-requests-create", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "e28f40de-1f6c-4dc6-ab12-4054b89628c1", + "introduced": "2026-09-25", + }, + "x-glean-scopes": { + "legacy": ["USAGE_LIMIT_INCREASE_REQUESTS"], + "platform": ["usage.limit_increase_requests:write"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "201", "application/json"): + return unmarshal_json_response(models.PlatformRequestResponse, http_res) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "409", "413", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + async def create_limit_increase_request_async( + self, + *, + agent_id: str, + client_id: str, + business_justification: Optional[str] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformRequestResponse: + r"""Submit an editable-agent limit-increase request + + Requires usage.limit_increase_requests:write, the same scope as personal creation, and current edit permission on the agent, not billing permissions. The caller supplies the agent, client, and optional business justification. Requester identity comes from authentication; the server assigns the request identifier and current UTC month. This internal scaffold returns 503 without creating a request. + + + :param agent_id: Identifier of the agent whose limit the request concerns. + :param client_id: Explicit spend client whose limit the request concerns. + :param business_justification: Optional explanation of why the increase is needed. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformAgentRequestCreate( + agent_id=agent_id, + client_id=client_id, + business_justification=business_justification, + ) + + req = self._build_request_async( + method="POST", + path="/api/admin/usage/limit-increase-requests", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request, False, False, "json", models.PlatformAgentRequestCreate + ), + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-admin-usage-requests-create", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "e28f40de-1f6c-4dc6-ab12-4054b89628c1", + "introduced": "2026-09-25", + }, + "x-glean-scopes": { + "legacy": ["USAGE_LIMIT_INCREASE_REQUESTS"], + "platform": ["usage.limit_increase_requests:write"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "201", "application/json"): + return unmarshal_json_response(models.PlatformRequestResponse, http_res) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "409", "413", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + def list_limit_increase_requests( + self, + *, + page_size: Optional[int] = 20, + cursor: Optional[str] = None, + filters: Optional[ + Union[ + Iterable[models.PlatformRequestFilter], + Iterable[models.PlatformRequestFilterTypedDict], + ] + ] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformRequestListResponseUnion: + r"""List the billing limit-increase request queue + + Requires admin.usage.limit_increase_requests:read and current workspace billing read permission. Agent ownership is not queue access. Cursors bind filters and current authorization context. This internal scaffold returns 503, not a successful empty page. + + + :param page_size: Maximum page size; defaults to 20 and cannot exceed 100. + :param cursor: Opaque continuation bound to filters and current authorization. + :param filters: Optional structured filters on request status. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformAdminUsageRequestsListRequest( + page_size=page_size, + cursor=cursor, + filters=utils.get_pydantic_model( + filters, Optional[List[models.PlatformRequestFilter]] + ), + ) + + req = self._build_request( + method="GET", + path="/api/admin/usage/limit-increase-requests", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-admin-usage-requests-list", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "b02bb653-00f9-4739-b387-90f68c7385ee", + "introduced": "2026-09-25", + }, + "x-glean-scopes": { + "legacy": ["ADMIN_USAGE_LIMIT_INCREASE_REQUESTS"], + "platform": ["admin.usage.limit_increase_requests:read"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response( + models.PlatformRequestListResponseUnion, http_res + ) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + async def list_limit_increase_requests_async( + self, + *, + page_size: Optional[int] = 20, + cursor: Optional[str] = None, + filters: Optional[ + Union[ + Iterable[models.PlatformRequestFilter], + Iterable[models.PlatformRequestFilterTypedDict], + ] + ] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformRequestListResponseUnion: + r"""List the billing limit-increase request queue + + Requires admin.usage.limit_increase_requests:read and current workspace billing read permission. Agent ownership is not queue access. Cursors bind filters and current authorization context. This internal scaffold returns 503, not a successful empty page. + + + :param page_size: Maximum page size; defaults to 20 and cannot exceed 100. + :param cursor: Opaque continuation bound to filters and current authorization. + :param filters: Optional structured filters on request status. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformAdminUsageRequestsListRequest( + page_size=page_size, + cursor=cursor, + filters=utils.get_pydantic_model( + filters, Optional[List[models.PlatformRequestFilter]] + ), + ) + + req = self._build_request_async( + method="GET", + path="/api/admin/usage/limit-increase-requests", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-admin-usage-requests-list", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "b02bb653-00f9-4739-b387-90f68c7385ee", + "introduced": "2026-09-25", + }, + "x-glean-scopes": { + "legacy": ["ADMIN_USAGE_LIMIT_INCREASE_REQUESTS"], + "platform": ["admin.usage.limit_increase_requests:read"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response( + models.PlatformRequestListResponseUnion, http_res + ) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + def get_limit_increase_request( + self, + *, + request_id: str, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformRequestResponse: + r"""Get a billing limit-increase request + + Requires admin.usage.limit_increase_requests:read. Authorization precedes resource disclosure. This internal scaffold returns 503 without reading the request. + + + :param request_id: Opaque request identifier; not an authorization grant. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformAdminUsageRequestsGetRequest( + request_id=request_id, + ) + + req = self._build_request( + method="GET", + path="/api/admin/usage/limit-increase-requests/{request_id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-admin-usage-requests-get", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "88f1a13a-3e09-4c78-a2dc-87cc223dc003", + "introduced": "2026-09-25", + }, + "x-glean-scopes": { + "legacy": ["ADMIN_USAGE_LIMIT_INCREASE_REQUESTS"], + "platform": ["admin.usage.limit_increase_requests:read"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response(models.PlatformRequestResponse, http_res) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + async def get_limit_increase_request_async( + self, + *, + request_id: str, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformRequestResponse: + r"""Get a billing limit-increase request + + Requires admin.usage.limit_increase_requests:read. Authorization precedes resource disclosure. This internal scaffold returns 503 without reading the request. + + + :param request_id: Opaque request identifier; not an authorization grant. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformAdminUsageRequestsGetRequest( + request_id=request_id, + ) + + req = self._build_request_async( + method="GET", + path="/api/admin/usage/limit-increase-requests/{request_id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-admin-usage-requests-get", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "88f1a13a-3e09-4c78-a2dc-87cc223dc003", + "introduced": "2026-09-25", + }, + "x-glean-scopes": { + "legacy": ["ADMIN_USAGE_LIMIT_INCREASE_REQUESTS"], + "platform": ["admin.usage.limit_increase_requests:read"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response(models.PlatformRequestResponse, http_res) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) diff --git a/src/glean/api_client/agents.py b/src/glean/api_client/agents.py index 23c75362..67c2c86a 100644 --- a/src/glean/api_client/agents.py +++ b/src/glean/api_client/agents.py @@ -90,6 +90,10 @@ def search( tags=["Agents"], extensions={ "x-codegen-request-body-name": "payload", + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:read"], + }, "x-visibility": "Public", }, ), @@ -200,6 +204,10 @@ async def search_async( tags=["Agents"], extensions={ "x-codegen-request-body-name": "payload", + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:read"], + }, "x-visibility": "Public", }, ), @@ -305,7 +313,13 @@ def get( self.sdk_configuration.security, models.Security ), tags=["Agents"], - extensions={"x-visibility": "Public"}, + extensions={ + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:read"], + }, + "x-visibility": "Public", + }, ), request=req, is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), @@ -407,7 +421,13 @@ async def get_async( self.sdk_configuration.security, models.Security ), tags=["Agents"], - extensions={"x-visibility": "Public"}, + extensions={ + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:read"], + }, + "x-visibility": "Public", + }, ), request=req, is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), @@ -512,7 +532,13 @@ def get_schemas( self.sdk_configuration.security, models.Security ), tags=["Agents"], - extensions={"x-visibility": "Public"}, + extensions={ + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:read"], + }, + "x-visibility": "Public", + }, ), request=req, is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), @@ -619,7 +645,13 @@ async def get_schemas_async( self.sdk_configuration.security, models.Security ), tags=["Agents"], - extensions={"x-visibility": "Public"}, + extensions={ + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:read"], + }, + "x-visibility": "Public", + }, ), request=req, is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), @@ -764,6 +796,10 @@ def create_run( tags=["Agents"], extensions={ "x-codegen-request-body-name": "payload", + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:run"], + }, "x-visibility": "Public", }, ), @@ -921,6 +957,10 @@ async def create_run_async( tags=["Agents"], extensions={ "x-codegen-request-body-name": "payload", + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:run"], + }, "x-visibility": "Public", }, ), @@ -1040,7 +1080,13 @@ def get_run( self.sdk_configuration.security, models.Security ), tags=["Agents"], - extensions={"x-visibility": "Public"}, + extensions={ + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:run"], + }, + "x-visibility": "Public", + }, ), request=req, is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), @@ -1145,7 +1191,13 @@ async def get_run_async( self.sdk_configuration.security, models.Security ), tags=["Agents"], - extensions={"x-visibility": "Public"}, + extensions={ + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:run"], + }, + "x-visibility": "Public", + }, ), request=req, is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), @@ -1261,6 +1313,10 @@ def cancel_run( tags=["Agents"], extensions={ "x-codegen-request-body-name": "payload", + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:run"], + }, "x-visibility": "Public", }, ), @@ -1378,6 +1434,10 @@ async def cancel_run_async( tags=["Agents"], extensions={ "x-codegen-request-body-name": "payload", + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:run"], + }, "x-visibility": "Public", }, ), @@ -1501,7 +1561,13 @@ def respond_to_run( self.sdk_configuration.security, models.Security ), tags=["Agents"], - extensions={"x-visibility": "Public"}, + extensions={ + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:run"], + }, + "x-visibility": "Public", + }, ), request=req, is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), @@ -1623,7 +1689,13 @@ async def respond_to_run_async( self.sdk_configuration.security, models.Security ), tags=["Agents"], - extensions={"x-visibility": "Public"}, + extensions={ + "x-glean-scopes": { + "legacy": ["AGENTS"], + "platform": ["agents:run"], + }, + "x-visibility": "Public", + }, ), request=req, is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), diff --git a/src/glean/api_client/chat_sdk.py b/src/glean/api_client/chat_sdk.py index b37457a8..2b43c607 100644 --- a/src/glean/api_client/chat_sdk.py +++ b/src/glean/api_client/chat_sdk.py @@ -103,6 +103,7 @@ def create( tags=["Chat"], extensions={ "x-codegen-request-body-name": "payload", + "x-glean-scopes": {"legacy": ["CHAT"], "platform": ["chat:write"]}, "x-visibility": "Public", }, ), @@ -232,6 +233,7 @@ async def create_async( tags=["Chat"], extensions={ "x-codegen-request-body-name": "payload", + "x-glean-scopes": {"legacy": ["CHAT"], "platform": ["chat:write"]}, "x-visibility": "Public", }, ), @@ -365,6 +367,7 @@ def create_stream( tags=["Chat"], extensions={ "x-codegen-request-body-name": "payload", + "x-glean-scopes": {"legacy": ["CHAT"], "platform": ["chat:write"]}, "x-visibility": "Public", }, ), @@ -510,6 +513,7 @@ async def create_stream_async( tags=["Chat"], extensions={ "x-codegen-request-body-name": "payload", + "x-glean-scopes": {"legacy": ["CHAT"], "platform": ["chat:write"]}, "x-visibility": "Public", }, ), diff --git a/src/glean/api_client/entities.py b/src/glean/api_client/entities.py index adc08d27..44a41c98 100644 --- a/src/glean/api_client/entities.py +++ b/src/glean/api_client/entities.py @@ -306,6 +306,7 @@ def read_people( self, *, locale: Optional[str] = None, + fallback_to_authenticated_identity: Optional[bool] = False, timezone_offset: Optional[int] = None, obfuscated_ids: Optional[Iterable[str]] = None, email_ids: Optional[Iterable[str]] = None, @@ -322,6 +323,7 @@ def read_people( Read people details for the given IDs. :param locale: The client's preferred locale in rfc5646 format (e.g. `en`, `ja`, `pt-BR`). If omitted, the `Accept-Language` will be used. If not present or not supported, defaults to the closest match or `en`. + :param fallback_to_authenticated_identity: If true and the current user's people profile is missing, reads the stored SSO profile and returns a minimal Person with its display name, the authenticated user's email, the same obfuscatedId used by a normal self-lookup, and identityOnly set to true. If the SSO profile or its name is unavailable, preserves the missing-profile error. Applies only when emailIds and obfuscatedIds are empty and the request doesn't use act-as, a virtual identity, anonymous authentication, or the INVALID_ENTITIES includeType. The fallback doesn't mask lookup or enrichment errors and doesn't create a directory profile. Normal people profiles don't require an SSO lookup. :param timezone_offset: The offset of the client's timezone in minutes from UTC. e.g. PDT is -420 because it's 7 hours behind UTC. :param obfuscated_ids: The Person IDs to retrieve. If no IDs are requested, the current user's details are returned. :param email_ids: The email IDs to retrieve. The result is the deduplicated union of emailIds and obfuscatedIds. @@ -346,6 +348,7 @@ def read_people( request = models.PeopleRequestRequest( locale=locale, people_request=models.PeopleRequest( + fallback_to_authenticated_identity=fallback_to_authenticated_identity, timezone_offset=timezone_offset, obfuscated_ids=utils.unmarshal(obfuscated_ids, Optional[List[str]]), email_ids=utils.unmarshal(email_ids, Optional[List[str]]), @@ -422,6 +425,7 @@ async def read_people_async( self, *, locale: Optional[str] = None, + fallback_to_authenticated_identity: Optional[bool] = False, timezone_offset: Optional[int] = None, obfuscated_ids: Optional[Iterable[str]] = None, email_ids: Optional[Iterable[str]] = None, @@ -438,6 +442,7 @@ async def read_people_async( Read people details for the given IDs. :param locale: The client's preferred locale in rfc5646 format (e.g. `en`, `ja`, `pt-BR`). If omitted, the `Accept-Language` will be used. If not present or not supported, defaults to the closest match or `en`. + :param fallback_to_authenticated_identity: If true and the current user's people profile is missing, reads the stored SSO profile and returns a minimal Person with its display name, the authenticated user's email, the same obfuscatedId used by a normal self-lookup, and identityOnly set to true. If the SSO profile or its name is unavailable, preserves the missing-profile error. Applies only when emailIds and obfuscatedIds are empty and the request doesn't use act-as, a virtual identity, anonymous authentication, or the INVALID_ENTITIES includeType. The fallback doesn't mask lookup or enrichment errors and doesn't create a directory profile. Normal people profiles don't require an SSO lookup. :param timezone_offset: The offset of the client's timezone in minutes from UTC. e.g. PDT is -420 because it's 7 hours behind UTC. :param obfuscated_ids: The Person IDs to retrieve. If no IDs are requested, the current user's details are returned. :param email_ids: The email IDs to retrieve. The result is the deduplicated union of emailIds and obfuscatedIds. @@ -462,6 +467,7 @@ async def read_people_async( request = models.PeopleRequestRequest( locale=locale, people_request=models.PeopleRequest( + fallback_to_authenticated_identity=fallback_to_authenticated_identity, timezone_offset=timezone_offset, obfuscated_ids=utils.unmarshal(obfuscated_ids, Optional[List[str]]), email_ids=utils.unmarshal(email_ids, Optional[List[str]]), diff --git a/src/glean/api_client/models/__init__.py b/src/glean/api_client/models/__init__.py index 6eac20c2..80619420 100644 --- a/src/glean/api_client/models/__init__.py +++ b/src/glean/api_client/models/__init__.py @@ -183,6 +183,7 @@ ) from .answerresult import AnswerResult, AnswerResultTypedDict from .appresult import AppResult, AppResultTypedDict + from .artifacttype import ArtifactType from .assistantinsightsresponse import ( AssistantInsightsResponse, AssistantInsightsResponseTypedDict, @@ -1203,6 +1204,10 @@ ManualFeedbackSideBySideInfoTypedDict, ManualFeedbackSideBySideInfoVote, ) + from .mcpauthmethodbreakdown import ( + McpAuthMethodBreakdown, + McpAuthMethodBreakdownTypedDict, + ) from .mcpbreakdowninsightsrequest import ( BreakdownType, McpBreakdownInsightsRequest, @@ -1279,6 +1284,14 @@ from .peruserinsight import PerUserInsight, PerUserInsightTypedDict from .pinop import PinRequestRequest, PinRequestRequestTypedDict from .pinrequest import PinRequest, PinRequestTypedDict + from .platform_admin_usage_requests_getop import ( + PlatformAdminUsageRequestsGetRequest, + PlatformAdminUsageRequestsGetRequestTypedDict, + ) + from .platform_admin_usage_requests_listop import ( + PlatformAdminUsageRequestsListRequest, + PlatformAdminUsageRequestsListRequestTypedDict, + ) from .platform_agents_cancel_runop import ( PlatformAgentsCancelRunRequest, PlatformAgentsCancelRunRequestTypedDict, @@ -1367,9 +1380,13 @@ PlatformSkillsListRequest, PlatformSkillsListRequestTypedDict, ) + from .platform_skills_preview_source_streamop import ( + PlatformSkillsPreviewSourceStreamRequest, + PlatformSkillsPreviewSourceStreamRequestTypedDict, + ) from .platform_skills_preview_sourceop import ( - PlatformSkillsPreviewSourceResponse, - PlatformSkillsPreviewSourceResponseTypedDict, + PlatformSkillsPreviewSourceRequest, + PlatformSkillsPreviewSourceRequestTypedDict, ) from .platform_skills_syncop import ( PlatformSkillsSyncRequest, @@ -1419,6 +1436,14 @@ PlatformTriggersUpdateRequest, PlatformTriggersUpdateRequestTypedDict, ) + from .platform_usage_requests_getop import ( + PlatformUsageRequestsGetRequest, + PlatformUsageRequestsGetRequestTypedDict, + ) + from .platform_usage_requests_listop import ( + PlatformUsageRequestsListRequest, + PlatformUsageRequestsListRequestTypedDict, + ) from .platformactionsummary import ( PlatformActionSummary, PlatformActionSummaryTypedDict, @@ -1433,6 +1458,10 @@ PlatformAgentGetResponse, PlatformAgentGetResponseTypedDict, ) + from .platformagentrequestcreate import ( + PlatformAgentRequestCreate, + PlatformAgentRequestCreateTypedDict, + ) from .platformagentrun import PlatformAgentRun, PlatformAgentRunTypedDict from .platformagentrunapprovaldecision import ( Decision, @@ -1649,6 +1678,16 @@ PlatformFilterFieldInfoTypedDict, ) from .platformfilteroperator import PlatformFilterOperator + from .platformlimitincreaserequest import ( + PlatformLimitIncreaseRequest, + PlatformLimitIncreaseRequestEntityType, + PlatformLimitIncreaseRequestTypedDict, + ) + from .platformlimitincreaserequestsettings import ( + BusinessJustification, + PlatformLimitIncreaseRequestSettings, + PlatformLimitIncreaseRequestSettingsTypedDict, + ) from .platformmessage import PlatformMessage, PlatformMessageTypedDict from .platformmessage_input import ( PlatformMessageInput, @@ -1663,15 +1702,52 @@ PlatformMessageTextBlockInput, PlatformMessageTextBlockInputTypedDict, ) + from .platformmultiplemembershipresolutionsettings import ( + PlatformMultipleMembershipResolutionSettings, + PlatformMultipleMembershipResolutionSettingsTypedDict, + ) + from .platformpermembersettings import ( + IdpGroups, + PlatformPerMemberSettings, + PlatformPerMemberSettingsTypedDict, + ) + from .platformpersonalrequestcreate import ( + PlatformPersonalRequestCreate, + PlatformPersonalRequestCreateTypedDict, + ) from .platformpersonreference import ( PlatformPersonReference, PlatformPersonReferenceTypedDict, ) + from .platformproblemdetail import ( + PlatformProblemDetail, + PlatformProblemDetailTypedDict, + ) from .platformproblemdetailcode import PlatformProblemDetailCode from .platformproblemdetailerror import ( PlatformProblemDetailError, PlatformProblemDetailErrorTypedDict, ) + from .platformrequestfilter import ( + Operator, + PlatformRequestFilter, + PlatformRequestFilterTypedDict, + ) + from .platformrequestlistresponse_union import ( + PlatformRequestListResponse1, + PlatformRequestListResponse1TypedDict, + PlatformRequestListResponse2, + PlatformRequestListResponse2TypedDict, + PlatformRequestListResponseUnion, + PlatformRequestListResponseUnionTypedDict, + ) + from .platformrequestresolutiontarget import PlatformRequestResolutionTarget + from .platformrequestresponse import ( + PlatformRequestResponse, + PlatformRequestResponseTypedDict, + ) + from .platformrequestscope import PlatformRequestScope + from .platformrequeststatus import PlatformRequestStatus from .platformresult import PlatformResult, PlatformResultTypedDict from .platformsearchfiltersresponse import ( PlatformSearchFiltersResponse, @@ -1728,14 +1804,59 @@ PlatformSkillSourcePreviewFile, PlatformSkillSourcePreviewFileTypedDict, ) - from .platformskillsourcepreviewrequest import ( - PlatformSkillSourcePreviewRequest, - PlatformSkillSourcePreviewRequestTypedDict, - ) from .platformskillsourcepreviewresponse import ( PlatformSkillSourcePreviewResponse, PlatformSkillSourcePreviewResponseTypedDict, ) + from .platformskillsourcepreviewstreamerror import ( + PlatformSkillSourcePreviewStreamError, + PlatformSkillSourcePreviewStreamErrorType, + PlatformSkillSourcePreviewStreamErrorTypedDict, + ) + from .platformskillsourcepreviewstreamerrorserversentevent import ( + PlatformSkillSourcePreviewStreamErrorServerSentEvent, + PlatformSkillSourcePreviewStreamErrorServerSentEventTypedDict, + ) + from .platformskillsourcepreviewstreameventserversentevent import ( + PlatformSkillSourcePreviewStreamEventServerSentEvent, + PlatformSkillSourcePreviewStreamEventServerSentEventTypedDict, + ) + from .platformskillsourcepreviewstreamprogress import ( + PlatformSkillSourcePreviewStreamProgress, + PlatformSkillSourcePreviewStreamProgressType, + PlatformSkillSourcePreviewStreamProgressTypedDict, + ) + from .platformskillsourcepreviewstreamprogressserversentevent import ( + PlatformSkillSourcePreviewStreamProgressServerSentEvent, + PlatformSkillSourcePreviewStreamProgressServerSentEventTypedDict, + ) + from .platformskillsourcepreviewstreamresult import ( + PlatformSkillSourcePreviewStreamResult, + PlatformSkillSourcePreviewStreamResultType, + PlatformSkillSourcePreviewStreamResultTypedDict, + ) + from .platformskillsourcepreviewstreamresultserversentevent import ( + PlatformSkillSourcePreviewStreamResultServerSentEvent, + PlatformSkillSourcePreviewStreamResultServerSentEventTypedDict, + ) + from .platformskillsourcepreviewstreamscan import ( + PlatformSkillSourcePreviewStreamScan, + PlatformSkillSourcePreviewStreamScanType, + PlatformSkillSourcePreviewStreamScanTypedDict, + ) + from .platformskillsourcepreviewstreamscanserversentevent import ( + PlatformSkillSourcePreviewStreamScanServerSentEvent, + PlatformSkillSourcePreviewStreamScanServerSentEventTypedDict, + ) + from .platformskillsourcepreviewstreamskill import ( + PlatformSkillSourcePreviewStreamSkill, + PlatformSkillSourcePreviewStreamSkillType, + PlatformSkillSourcePreviewStreamSkillTypedDict, + ) + from .platformskillsourcepreviewstreamskillserversentevent import ( + PlatformSkillSourcePreviewStreamSkillServerSentEvent, + PlatformSkillSourcePreviewStreamSkillServerSentEventTypedDict, + ) from .platformskillsourceprovenance import ( PlatformSkillSourceProvenance, PlatformSkillSourceProvenanceTypedDict, @@ -1745,7 +1866,6 @@ PlatformSkillSyncResponse, PlatformSkillSyncResponseTypedDict, ) - from .platformskillsyncresultstatus import PlatformSkillSyncResultStatus from .platformskillsyncstatus import PlatformSkillSyncStatus from .platformskillupdaterequest import ( PlatformSkillUpdateRequest, @@ -1889,6 +2009,22 @@ PlatformTriggerWithSecret, PlatformTriggerWithSecretTypedDict, ) + from .platformusagesettingsresource import ( + PlatformUsageSettingsResource, + PlatformUsageSettingsResourceTypedDict, + ) + from .platformusagesettingsresponse import ( + PlatformUsageSettingsResponse, + PlatformUsageSettingsResponseTypedDict, + ) + from .platformusagesettingsupdaterequest_union import ( + PlatformUsageSettingsUpdateRequest1, + PlatformUsageSettingsUpdateRequest1TypedDict, + PlatformUsageSettingsUpdateRequest2, + PlatformUsageSettingsUpdateRequest2TypedDict, + PlatformUsageSettingsUpdateRequestUnion, + PlatformUsageSettingsUpdateRequestUnionTypedDict, + ) from .platformwarning import PlatformWarning, PlatformWarningTypedDict from .possiblevalue import PossibleValue, PossibleValueTypedDict from .post_api_index_v1_debug_datasource_document_eventsop import ( @@ -2390,6 +2526,7 @@ "AnswerTypedDict", "AppResult", "AppResultTypedDict", + "ArtifactType", "AssistantInsightsResponse", "AssistantInsightsResponseTypedDict", "AuthConfig", @@ -2450,6 +2587,7 @@ "BulkUploadHistoryEventTypedDict", "Bundle", "BundleTypedDict", + "BusinessJustification", "CalendarAttendee", "CalendarAttendeeTypedDict", "CalendarAttendees", @@ -3071,6 +3209,7 @@ "IconType", "Identity", "IdentityTypedDict", + "IdpGroups", "ImportAgentRequest", "ImportAgentRequestRequest", "ImportAgentRequestRequestTypedDict", @@ -3186,6 +3325,8 @@ "ManualFeedbackSideBySideInfoSource", "ManualFeedbackSideBySideInfoTypedDict", "ManualFeedbackSideBySideInfoVote", + "McpAuthMethodBreakdown", + "McpAuthMethodBreakdownTypedDict", "McpBreakdownInsightsRequest", "McpBreakdownInsightsRequestTypedDict", "McpBreakdownInsightsResponse", @@ -3224,6 +3365,7 @@ "ObjectDefinitionTypedDict", "ObjectPermissions", "ObjectPermissionsTypedDict", + "Operator", "OperatorMetadata", "OperatorMetadataTypedDict", "OperatorScope", @@ -3278,12 +3420,18 @@ "PlacementReason", "PlatformActionSummary", "PlatformActionSummaryTypedDict", + "PlatformAdminUsageRequestsGetRequest", + "PlatformAdminUsageRequestsGetRequestTypedDict", + "PlatformAdminUsageRequestsListRequest", + "PlatformAdminUsageRequestsListRequestTypedDict", "PlatformAgent", "PlatformAgentCapabilities", "PlatformAgentCapabilitiesTypedDict", "PlatformAgentExecutionStatus", "PlatformAgentGetResponse", "PlatformAgentGetResponseTypedDict", + "PlatformAgentRequestCreate", + "PlatformAgentRequestCreateTypedDict", "PlatformAgentRun", "PlatformAgentRunApprovalDecision", "PlatformAgentRunApprovalDecisionTypedDict", @@ -3439,6 +3587,11 @@ "PlatformFilterFieldInfoTypedDict", "PlatformFilterOperator", "PlatformFilterTypedDict", + "PlatformLimitIncreaseRequest", + "PlatformLimitIncreaseRequestEntityType", + "PlatformLimitIncreaseRequestSettings", + "PlatformLimitIncreaseRequestSettingsTypedDict", + "PlatformLimitIncreaseRequestTypedDict", "PlatformMessage", "PlatformMessageInput", "PlatformMessageInputTypedDict", @@ -3448,11 +3601,32 @@ "PlatformMessageTextBlockInputTypedDict", "PlatformMessageTextBlockTypedDict", "PlatformMessageTypedDict", + "PlatformMultipleMembershipResolutionSettings", + "PlatformMultipleMembershipResolutionSettingsTypedDict", + "PlatformPerMemberSettings", + "PlatformPerMemberSettingsTypedDict", "PlatformPersonReference", "PlatformPersonReferenceTypedDict", + "PlatformPersonalRequestCreate", + "PlatformPersonalRequestCreateTypedDict", + "PlatformProblemDetail", "PlatformProblemDetailCode", "PlatformProblemDetailError", "PlatformProblemDetailErrorTypedDict", + "PlatformProblemDetailTypedDict", + "PlatformRequestFilter", + "PlatformRequestFilterTypedDict", + "PlatformRequestListResponse1", + "PlatformRequestListResponse1TypedDict", + "PlatformRequestListResponse2", + "PlatformRequestListResponse2TypedDict", + "PlatformRequestListResponseUnion", + "PlatformRequestListResponseUnionTypedDict", + "PlatformRequestResolutionTarget", + "PlatformRequestResponse", + "PlatformRequestResponseTypedDict", + "PlatformRequestScope", + "PlatformRequestStatus", "PlatformResult", "PlatformResultTypedDict", "PlatformSearchFiltersRequest", @@ -3485,17 +3659,41 @@ "PlatformSkillSourcePreviewFailureTypedDict", "PlatformSkillSourcePreviewFile", "PlatformSkillSourcePreviewFileTypedDict", - "PlatformSkillSourcePreviewRequest", - "PlatformSkillSourcePreviewRequestTypedDict", "PlatformSkillSourcePreviewResponse", "PlatformSkillSourcePreviewResponseTypedDict", + "PlatformSkillSourcePreviewStreamError", + "PlatformSkillSourcePreviewStreamErrorServerSentEvent", + "PlatformSkillSourcePreviewStreamErrorServerSentEventTypedDict", + "PlatformSkillSourcePreviewStreamErrorType", + "PlatformSkillSourcePreviewStreamErrorTypedDict", + "PlatformSkillSourcePreviewStreamEventServerSentEvent", + "PlatformSkillSourcePreviewStreamEventServerSentEventTypedDict", + "PlatformSkillSourcePreviewStreamProgress", + "PlatformSkillSourcePreviewStreamProgressServerSentEvent", + "PlatformSkillSourcePreviewStreamProgressServerSentEventTypedDict", + "PlatformSkillSourcePreviewStreamProgressType", + "PlatformSkillSourcePreviewStreamProgressTypedDict", + "PlatformSkillSourcePreviewStreamResult", + "PlatformSkillSourcePreviewStreamResultServerSentEvent", + "PlatformSkillSourcePreviewStreamResultServerSentEventTypedDict", + "PlatformSkillSourcePreviewStreamResultType", + "PlatformSkillSourcePreviewStreamResultTypedDict", + "PlatformSkillSourcePreviewStreamScan", + "PlatformSkillSourcePreviewStreamScanServerSentEvent", + "PlatformSkillSourcePreviewStreamScanServerSentEventTypedDict", + "PlatformSkillSourcePreviewStreamScanType", + "PlatformSkillSourcePreviewStreamScanTypedDict", + "PlatformSkillSourcePreviewStreamSkill", + "PlatformSkillSourcePreviewStreamSkillServerSentEvent", + "PlatformSkillSourcePreviewStreamSkillServerSentEventTypedDict", + "PlatformSkillSourcePreviewStreamSkillType", + "PlatformSkillSourcePreviewStreamSkillTypedDict", "PlatformSkillSourcePreviewTypedDict", "PlatformSkillSourceProvenance", "PlatformSkillSourceProvenanceTypedDict", "PlatformSkillStatus", "PlatformSkillSyncResponse", "PlatformSkillSyncResponseTypedDict", - "PlatformSkillSyncResultStatus", "PlatformSkillSyncStatus", "PlatformSkillTypedDict", "PlatformSkillUpdateRequest", @@ -3547,8 +3745,10 @@ "PlatformSkillsListResponseTypedDict", "PlatformSkillsListVersionsRequest", "PlatformSkillsListVersionsRequestTypedDict", - "PlatformSkillsPreviewSourceResponse", - "PlatformSkillsPreviewSourceResponseTypedDict", + "PlatformSkillsPreviewSourceRequest", + "PlatformSkillsPreviewSourceRequestTypedDict", + "PlatformSkillsPreviewSourceStreamRequest", + "PlatformSkillsPreviewSourceStreamRequestTypedDict", "PlatformSkillsSyncRequest", "PlatformSkillsSyncRequestTypedDict", "PlatformSkillsUpdateRequest", @@ -3626,6 +3826,20 @@ "PlatformTriggersListRequestTypedDict", "PlatformTriggersUpdateRequest", "PlatformTriggersUpdateRequestTypedDict", + "PlatformUsageRequestsGetRequest", + "PlatformUsageRequestsGetRequestTypedDict", + "PlatformUsageRequestsListRequest", + "PlatformUsageRequestsListRequestTypedDict", + "PlatformUsageSettingsResource", + "PlatformUsageSettingsResourceTypedDict", + "PlatformUsageSettingsResponse", + "PlatformUsageSettingsResponseTypedDict", + "PlatformUsageSettingsUpdateRequest1", + "PlatformUsageSettingsUpdateRequest1TypedDict", + "PlatformUsageSettingsUpdateRequest2", + "PlatformUsageSettingsUpdateRequest2TypedDict", + "PlatformUsageSettingsUpdateRequestUnion", + "PlatformUsageSettingsUpdateRequestUnionTypedDict", "PlatformWarning", "PlatformWarningTypedDict", "PossibleValue", @@ -4068,6 +4282,7 @@ "AnswerResultTypedDict": ".answerresult", "AppResult": ".appresult", "AppResultTypedDict": ".appresult", + "ArtifactType": ".artifacttype", "AssistantInsightsResponse": ".assistantinsightsresponse", "AssistantInsightsResponseTypedDict": ".assistantinsightsresponse", "AuthConfig": ".authconfig", @@ -4822,6 +5037,8 @@ "ManualFeedbackSideBySideInfoSource": ".manualfeedbacksidebysideinfo", "ManualFeedbackSideBySideInfoTypedDict": ".manualfeedbacksidebysideinfo", "ManualFeedbackSideBySideInfoVote": ".manualfeedbacksidebysideinfo", + "McpAuthMethodBreakdown": ".mcpauthmethodbreakdown", + "McpAuthMethodBreakdownTypedDict": ".mcpauthmethodbreakdown", "BreakdownType": ".mcpbreakdowninsightsrequest", "McpBreakdownInsightsRequest": ".mcpbreakdowninsightsrequest", "McpBreakdownInsightsRequestTypedDict": ".mcpbreakdowninsightsrequest", @@ -4897,6 +5114,10 @@ "PinRequestRequestTypedDict": ".pinop", "PinRequest": ".pinrequest", "PinRequestTypedDict": ".pinrequest", + "PlatformAdminUsageRequestsGetRequest": ".platform_admin_usage_requests_getop", + "PlatformAdminUsageRequestsGetRequestTypedDict": ".platform_admin_usage_requests_getop", + "PlatformAdminUsageRequestsListRequest": ".platform_admin_usage_requests_listop", + "PlatformAdminUsageRequestsListRequestTypedDict": ".platform_admin_usage_requests_listop", "PlatformAgentsCancelRunRequest": ".platform_agents_cancel_runop", "PlatformAgentsCancelRunRequestTypedDict": ".platform_agents_cancel_runop", "PlatformAgentsCreateRunResponsesRequest": ".platform_agents_create_run_responsesop", @@ -4951,8 +5172,10 @@ "PlatformSkillsListVersionsRequestTypedDict": ".platform_skills_list_versionsop", "PlatformSkillsListRequest": ".platform_skills_listop", "PlatformSkillsListRequestTypedDict": ".platform_skills_listop", - "PlatformSkillsPreviewSourceResponse": ".platform_skills_preview_sourceop", - "PlatformSkillsPreviewSourceResponseTypedDict": ".platform_skills_preview_sourceop", + "PlatformSkillsPreviewSourceStreamRequest": ".platform_skills_preview_source_streamop", + "PlatformSkillsPreviewSourceStreamRequestTypedDict": ".platform_skills_preview_source_streamop", + "PlatformSkillsPreviewSourceRequest": ".platform_skills_preview_sourceop", + "PlatformSkillsPreviewSourceRequestTypedDict": ".platform_skills_preview_sourceop", "PlatformSkillsSyncRequest": ".platform_skills_syncop", "PlatformSkillsSyncRequestTypedDict": ".platform_skills_syncop", "PlatformSkillsUpdateRequest": ".platform_skills_updateop", @@ -4977,6 +5200,10 @@ "PlatformTriggersListRequestTypedDict": ".platform_triggers_listop", "PlatformTriggersUpdateRequest": ".platform_triggers_updateop", "PlatformTriggersUpdateRequestTypedDict": ".platform_triggers_updateop", + "PlatformUsageRequestsGetRequest": ".platform_usage_requests_getop", + "PlatformUsageRequestsGetRequestTypedDict": ".platform_usage_requests_getop", + "PlatformUsageRequestsListRequest": ".platform_usage_requests_listop", + "PlatformUsageRequestsListRequestTypedDict": ".platform_usage_requests_listop", "PlatformActionSummary": ".platformactionsummary", "PlatformActionSummaryTypedDict": ".platformactionsummary", "PlatformAgent": ".platformagent", @@ -4986,6 +5213,8 @@ "PlatformAgentExecutionStatus": ".platformagentexecutionstatus", "PlatformAgentGetResponse": ".platformagentgetresponse", "PlatformAgentGetResponseTypedDict": ".platformagentgetresponse", + "PlatformAgentRequestCreate": ".platformagentrequestcreate", + "PlatformAgentRequestCreateTypedDict": ".platformagentrequestcreate", "PlatformAgentRun": ".platformagentrun", "PlatformAgentRunTypedDict": ".platformagentrun", "Decision": ".platformagentrunapprovaldecision", @@ -5114,6 +5343,12 @@ "PlatformFilterFieldInfo": ".platformfilterfieldinfo", "PlatformFilterFieldInfoTypedDict": ".platformfilterfieldinfo", "PlatformFilterOperator": ".platformfilteroperator", + "PlatformLimitIncreaseRequest": ".platformlimitincreaserequest", + "PlatformLimitIncreaseRequestEntityType": ".platformlimitincreaserequest", + "PlatformLimitIncreaseRequestTypedDict": ".platformlimitincreaserequest", + "BusinessJustification": ".platformlimitincreaserequestsettings", + "PlatformLimitIncreaseRequestSettings": ".platformlimitincreaserequestsettings", + "PlatformLimitIncreaseRequestSettingsTypedDict": ".platformlimitincreaserequestsettings", "PlatformMessage": ".platformmessage", "PlatformMessageTypedDict": ".platformmessage", "PlatformMessageInput": ".platformmessage_input", @@ -5123,11 +5358,34 @@ "PlatformMessageTextBlockTypedDict": ".platformmessagetextblock", "PlatformMessageTextBlockInput": ".platformmessagetextblock_input", "PlatformMessageTextBlockInputTypedDict": ".platformmessagetextblock_input", + "PlatformMultipleMembershipResolutionSettings": ".platformmultiplemembershipresolutionsettings", + "PlatformMultipleMembershipResolutionSettingsTypedDict": ".platformmultiplemembershipresolutionsettings", + "IdpGroups": ".platformpermembersettings", + "PlatformPerMemberSettings": ".platformpermembersettings", + "PlatformPerMemberSettingsTypedDict": ".platformpermembersettings", + "PlatformPersonalRequestCreate": ".platformpersonalrequestcreate", + "PlatformPersonalRequestCreateTypedDict": ".platformpersonalrequestcreate", "PlatformPersonReference": ".platformpersonreference", "PlatformPersonReferenceTypedDict": ".platformpersonreference", + "PlatformProblemDetail": ".platformproblemdetail", + "PlatformProblemDetailTypedDict": ".platformproblemdetail", "PlatformProblemDetailCode": ".platformproblemdetailcode", "PlatformProblemDetailError": ".platformproblemdetailerror", "PlatformProblemDetailErrorTypedDict": ".platformproblemdetailerror", + "Operator": ".platformrequestfilter", + "PlatformRequestFilter": ".platformrequestfilter", + "PlatformRequestFilterTypedDict": ".platformrequestfilter", + "PlatformRequestListResponse1": ".platformrequestlistresponse_union", + "PlatformRequestListResponse1TypedDict": ".platformrequestlistresponse_union", + "PlatformRequestListResponse2": ".platformrequestlistresponse_union", + "PlatformRequestListResponse2TypedDict": ".platformrequestlistresponse_union", + "PlatformRequestListResponseUnion": ".platformrequestlistresponse_union", + "PlatformRequestListResponseUnionTypedDict": ".platformrequestlistresponse_union", + "PlatformRequestResolutionTarget": ".platformrequestresolutiontarget", + "PlatformRequestResponse": ".platformrequestresponse", + "PlatformRequestResponseTypedDict": ".platformrequestresponse", + "PlatformRequestScope": ".platformrequestscope", + "PlatformRequestStatus": ".platformrequeststatus", "PlatformResult": ".platformresult", "PlatformResultTypedDict": ".platformresult", "PlatformSearchFiltersResponse": ".platformsearchfiltersresponse", @@ -5160,16 +5418,40 @@ "PlatformSkillSourcePreviewFailureCode": ".platformskillsourcepreviewfailurecode", "PlatformSkillSourcePreviewFile": ".platformskillsourcepreviewfile", "PlatformSkillSourcePreviewFileTypedDict": ".platformskillsourcepreviewfile", - "PlatformSkillSourcePreviewRequest": ".platformskillsourcepreviewrequest", - "PlatformSkillSourcePreviewRequestTypedDict": ".platformskillsourcepreviewrequest", "PlatformSkillSourcePreviewResponse": ".platformskillsourcepreviewresponse", "PlatformSkillSourcePreviewResponseTypedDict": ".platformskillsourcepreviewresponse", + "PlatformSkillSourcePreviewStreamError": ".platformskillsourcepreviewstreamerror", + "PlatformSkillSourcePreviewStreamErrorType": ".platformskillsourcepreviewstreamerror", + "PlatformSkillSourcePreviewStreamErrorTypedDict": ".platformskillsourcepreviewstreamerror", + "PlatformSkillSourcePreviewStreamErrorServerSentEvent": ".platformskillsourcepreviewstreamerrorserversentevent", + "PlatformSkillSourcePreviewStreamErrorServerSentEventTypedDict": ".platformskillsourcepreviewstreamerrorserversentevent", + "PlatformSkillSourcePreviewStreamEventServerSentEvent": ".platformskillsourcepreviewstreameventserversentevent", + "PlatformSkillSourcePreviewStreamEventServerSentEventTypedDict": ".platformskillsourcepreviewstreameventserversentevent", + "PlatformSkillSourcePreviewStreamProgress": ".platformskillsourcepreviewstreamprogress", + "PlatformSkillSourcePreviewStreamProgressType": ".platformskillsourcepreviewstreamprogress", + "PlatformSkillSourcePreviewStreamProgressTypedDict": ".platformskillsourcepreviewstreamprogress", + "PlatformSkillSourcePreviewStreamProgressServerSentEvent": ".platformskillsourcepreviewstreamprogressserversentevent", + "PlatformSkillSourcePreviewStreamProgressServerSentEventTypedDict": ".platformskillsourcepreviewstreamprogressserversentevent", + "PlatformSkillSourcePreviewStreamResult": ".platformskillsourcepreviewstreamresult", + "PlatformSkillSourcePreviewStreamResultType": ".platformskillsourcepreviewstreamresult", + "PlatformSkillSourcePreviewStreamResultTypedDict": ".platformskillsourcepreviewstreamresult", + "PlatformSkillSourcePreviewStreamResultServerSentEvent": ".platformskillsourcepreviewstreamresultserversentevent", + "PlatformSkillSourcePreviewStreamResultServerSentEventTypedDict": ".platformskillsourcepreviewstreamresultserversentevent", + "PlatformSkillSourcePreviewStreamScan": ".platformskillsourcepreviewstreamscan", + "PlatformSkillSourcePreviewStreamScanType": ".platformskillsourcepreviewstreamscan", + "PlatformSkillSourcePreviewStreamScanTypedDict": ".platformskillsourcepreviewstreamscan", + "PlatformSkillSourcePreviewStreamScanServerSentEvent": ".platformskillsourcepreviewstreamscanserversentevent", + "PlatformSkillSourcePreviewStreamScanServerSentEventTypedDict": ".platformskillsourcepreviewstreamscanserversentevent", + "PlatformSkillSourcePreviewStreamSkill": ".platformskillsourcepreviewstreamskill", + "PlatformSkillSourcePreviewStreamSkillType": ".platformskillsourcepreviewstreamskill", + "PlatformSkillSourcePreviewStreamSkillTypedDict": ".platformskillsourcepreviewstreamskill", + "PlatformSkillSourcePreviewStreamSkillServerSentEvent": ".platformskillsourcepreviewstreamskillserversentevent", + "PlatformSkillSourcePreviewStreamSkillServerSentEventTypedDict": ".platformskillsourcepreviewstreamskillserversentevent", "PlatformSkillSourceProvenance": ".platformskillsourceprovenance", "PlatformSkillSourceProvenanceTypedDict": ".platformskillsourceprovenance", "PlatformSkillStatus": ".platformskillstatus", "PlatformSkillSyncResponse": ".platformskillsyncresponse", "PlatformSkillSyncResponseTypedDict": ".platformskillsyncresponse", - "PlatformSkillSyncResultStatus": ".platformskillsyncresultstatus", "PlatformSkillSyncStatus": ".platformskillsyncstatus", "PlatformSkillUpdateRequest": ".platformskillupdaterequest", "PlatformSkillUpdateRequestTypedDict": ".platformskillupdaterequest", @@ -5251,6 +5533,16 @@ "PlatformTriggerWebhookEventTypedDict": ".platformtriggerwebhookevent", "PlatformTriggerWithSecret": ".platformtriggerwithsecret", "PlatformTriggerWithSecretTypedDict": ".platformtriggerwithsecret", + "PlatformUsageSettingsResource": ".platformusagesettingsresource", + "PlatformUsageSettingsResourceTypedDict": ".platformusagesettingsresource", + "PlatformUsageSettingsResponse": ".platformusagesettingsresponse", + "PlatformUsageSettingsResponseTypedDict": ".platformusagesettingsresponse", + "PlatformUsageSettingsUpdateRequest1": ".platformusagesettingsupdaterequest_union", + "PlatformUsageSettingsUpdateRequest1TypedDict": ".platformusagesettingsupdaterequest_union", + "PlatformUsageSettingsUpdateRequest2": ".platformusagesettingsupdaterequest_union", + "PlatformUsageSettingsUpdateRequest2TypedDict": ".platformusagesettingsupdaterequest_union", + "PlatformUsageSettingsUpdateRequestUnion": ".platformusagesettingsupdaterequest_union", + "PlatformUsageSettingsUpdateRequestUnionTypedDict": ".platformusagesettingsupdaterequest_union", "PlatformWarning": ".platformwarning", "PlatformWarningTypedDict": ".platformwarning", "PossibleValue": ".possiblevalue", diff --git a/src/glean/api_client/models/artifacttype.py b/src/glean/api_client/models/artifacttype.py new file mode 100644 index 00000000..1d5c4d3d --- /dev/null +++ b/src/glean/api_client/models/artifacttype.py @@ -0,0 +1,16 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from enum import Enum +from glean.api_client import utils + + +class ArtifactType(str, Enum, metaclass=utils.OpenEnumMeta): + r"""Type of the Artifact""" + + PAPER = "PAPER" + AGENT = "AGENT" + MESSAGE = "MESSAGE" + EMAIL = "EMAIL" + HTML_CODE = "HTML_CODE" + SLIDE = "SLIDE" diff --git a/src/glean/api_client/models/autocompleterequest.py b/src/glean/api_client/models/autocompleterequest.py index 77f48a08..adfebaa0 100644 --- a/src/glean/api_client/models/autocompleterequest.py +++ b/src/glean/api_client/models/autocompleterequest.py @@ -15,12 +15,12 @@ class AutocompleteRequestResultType(str, Enum): ADDITIONAL_DOCUMENT = "ADDITIONAL_DOCUMENT" APP = "APP" BROWSER_HISTORY = "BROWSER_HISTORY" + CHAT_HISTORY = "CHAT_HISTORY" DATASOURCE = "DATASOURCE" DOCUMENT = "DOCUMENT" ENTITY = "ENTITY" GOLINK = "GOLINK" HISTORY = "HISTORY" - CHAT_HISTORY = "CHAT_HISTORY" NEW_CHAT = "NEW_CHAT" OPERATOR = "OPERATOR" OPERATOR_VALUE = "OPERATOR_VALUE" diff --git a/src/glean/api_client/models/chatsuggestion.py b/src/glean/api_client/models/chatsuggestion.py index 8d24fdad..95b2928c 100644 --- a/src/glean/api_client/models/chatsuggestion.py +++ b/src/glean/api_client/models/chatsuggestion.py @@ -1,9 +1,11 @@ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" from __future__ import annotations +from .artifacttype import ArtifactType +from glean.api_client import models from glean.api_client.types import BaseModel, UNSET_SENTINEL import pydantic -from pydantic import model_serializer +from pydantic import field_serializer, model_serializer from typing import List, Optional from typing_extensions import Annotated, NotRequired, TypedDict @@ -15,6 +17,8 @@ class ChatSuggestionTypedDict(TypedDict): r"""Button text to show for the suggestion action.""" feature: NotRequired[str] r"""Targeted Glean Chat feature for the suggestion.""" + artifact_type: NotRequired[ArtifactType] + r"""Type of the Artifact""" source_document_ids: NotRequired[List[str]] r"""Document IDs that grounded the suggestion.""" @@ -29,14 +33,30 @@ class ChatSuggestion(BaseModel): feature: Optional[str] = None r"""Targeted Glean Chat feature for the suggestion.""" + artifact_type: Annotated[ + Optional[ArtifactType], pydantic.Field(alias="artifactType") + ] = None + r"""Type of the Artifact""" + source_document_ids: Annotated[ Optional[List[str]], pydantic.Field(alias="sourceDocumentIds") ] = None r"""Document IDs that grounded the suggestion.""" + @field_serializer("artifact_type") + def serialize_artifact_type(self, value): + if isinstance(value, str): + try: + return models.ArtifactType(value) + except ValueError: + return value + return value + @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = set(["query", "cta", "feature", "sourceDocumentIds"]) + optional_fields = set( + ["query", "cta", "feature", "artifactType", "sourceDocumentIds"] + ) serialized = handler(self) m = {} diff --git a/src/glean/api_client/models/feedentry.py b/src/glean/api_client/models/feedentry.py index 83e2c6f0..cee66e4f 100644 --- a/src/glean/api_client/models/feedentry.py +++ b/src/glean/api_client/models/feedentry.py @@ -138,6 +138,8 @@ class JustificationType(str, Enum, metaclass=utils.OpenEnumMeta): SHARE_ARTIFACT = "SHARE_ARTIFACT" CREATE_AGENT = "CREATE_AGENT" MANAGER_INVITE = "MANAGER_INVITE" + ONBOARDING_AUTHORIZATION = "ONBOARDING_AUTHORIZATION" + CHAT_REMINDER = "CHAT_REMINDER" class FeedEntryTypedDict(TypedDict): diff --git a/src/glean/api_client/models/feedrequest.py b/src/glean/api_client/models/feedrequest.py index 75cd4b1b..90fefe14 100644 --- a/src/glean/api_client/models/feedrequest.py +++ b/src/glean/api_client/models/feedrequest.py @@ -66,6 +66,8 @@ class FeedRequestCategory(str, Enum): SHARE_ARTIFACT = "SHARE_ARTIFACT" CREATE_AGENT = "CREATE_AGENT" MANAGER_INVITE = "MANAGER_INVITE" + ONBOARDING_AUTHORIZATION = "ONBOARDING_AUTHORIZATION" + CHAT_REMINDER = "CHAT_REMINDER" class FeedRequestTypedDict(TypedDict): diff --git a/src/glean/api_client/models/feedresult.py b/src/glean/api_client/models/feedresult.py index f450760d..dccf45ad 100644 --- a/src/glean/api_client/models/feedresult.py +++ b/src/glean/api_client/models/feedresult.py @@ -68,6 +68,8 @@ class FeedResultCategory(str, Enum, metaclass=utils.OpenEnumMeta): SHARE_ARTIFACT = "SHARE_ARTIFACT" CREATE_AGENT = "CREATE_AGENT" MANAGER_INVITE = "MANAGER_INVITE" + ONBOARDING_AUTHORIZATION = "ONBOARDING_AUTHORIZATION" + CHAT_REMINDER = "CHAT_REMINDER" class PlacementReason(str, Enum, metaclass=utils.OpenEnumMeta): diff --git a/src/glean/api_client/models/mcpauthmethodbreakdown.py b/src/glean/api_client/models/mcpauthmethodbreakdown.py new file mode 100644 index 00000000..fb87c13e --- /dev/null +++ b/src/glean/api_client/models/mcpauthmethodbreakdown.py @@ -0,0 +1,59 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from glean.api_client.types import BaseModel, UNSET_SENTINEL +import pydantic +from pydantic import model_serializer +from typing import List, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class McpAuthMethodBreakdownTypedDict(TypedDict): + auth_method: NotRequired[str] + r"""Authentication method the MCP client presented, for example OAUTH_GLEAN, OAUTH_XAA (Cross App Access), or API_TOKEN.""" + total_calls: NotRequired[int] + r"""Total number of MCP calls for this authentication method in the specified time period.""" + active_users: NotRequired[int] + r"""Total number of active users for this authentication method in the specified time period.""" + host_applications: NotRequired[List[str]] + r"""Host applications using this authentication method in the specified time period.""" + + +class McpAuthMethodBreakdown(BaseModel): + auth_method: Annotated[Optional[str], pydantic.Field(alias="authMethod")] = None + r"""Authentication method the MCP client presented, for example OAUTH_GLEAN, OAUTH_XAA (Cross App Access), or API_TOKEN.""" + + total_calls: Annotated[Optional[int], pydantic.Field(alias="totalCalls")] = None + r"""Total number of MCP calls for this authentication method in the specified time period.""" + + active_users: Annotated[Optional[int], pydantic.Field(alias="activeUsers")] = None + r"""Total number of active users for this authentication method in the specified time period.""" + + host_applications: Annotated[ + Optional[List[str]], pydantic.Field(alias="hostApplications") + ] = None + r"""Host applications using this authentication method in the specified time period.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set( + ["authMethod", "totalCalls", "activeUsers", "hostApplications"] + ) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m + + +try: + McpAuthMethodBreakdown.model_rebuild() +except NameError: + pass diff --git a/src/glean/api_client/models/mcpbreakdowninsightsrequest.py b/src/glean/api_client/models/mcpbreakdowninsightsrequest.py index 2893dadf..4d3a744d 100644 --- a/src/glean/api_client/models/mcpbreakdowninsightsrequest.py +++ b/src/glean/api_client/models/mcpbreakdowninsightsrequest.py @@ -17,6 +17,7 @@ class BreakdownType(str, Enum): HOST_APPLICATIONS = "HOST_APPLICATIONS" TOOLS = "TOOLS" SERVERS = "SERVERS" + AUTH_METHODS = "AUTH_METHODS" class McpBreakdownInsightsRequestTypedDict(TypedDict): @@ -35,6 +36,8 @@ class McpBreakdownInsightsRequestTypedDict(TypedDict): r"""MCP tools to filter by. Empty array means all tools.""" servers: NotRequired[List[str]] r"""MCP servers to filter by. Empty array means all servers.""" + auth_methods: NotRequired[List[str]] + r"""Authentication methods to filter by, for example OAUTH_XAA for Cross App Access traffic. Empty array means all authentication methods.""" class McpBreakdownInsightsRequest(BaseModel): @@ -69,6 +72,11 @@ class McpBreakdownInsightsRequest(BaseModel): servers: Optional[List[str]] = None r"""MCP servers to filter by. Empty array means all servers.""" + auth_methods: Annotated[ + Optional[List[str]], pydantic.Field(alias="authMethods") + ] = None + r"""Authentication methods to filter by, for example OAUTH_XAA for Cross App Access traffic. Empty array means all authentication methods.""" + @model_serializer(mode="wrap") def serialize_model(self, handler): optional_fields = set( @@ -81,6 +89,7 @@ def serialize_model(self, handler): "hostApplications", "tools", "servers", + "authMethods", ] ) serialized = handler(self) diff --git a/src/glean/api_client/models/mcpbreakdowninsightsresponse.py b/src/glean/api_client/models/mcpbreakdowninsightsresponse.py index 5afd6a5c..e3f49671 100644 --- a/src/glean/api_client/models/mcpbreakdowninsightsresponse.py +++ b/src/glean/api_client/models/mcpbreakdowninsightsresponse.py @@ -1,6 +1,10 @@ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" from __future__ import annotations +from .mcpauthmethodbreakdown import ( + McpAuthMethodBreakdown, + McpAuthMethodBreakdownTypedDict, +) from .mcphostapplicationbreakdown import ( McpHostApplicationBreakdown, McpHostApplicationBreakdownTypedDict, @@ -20,6 +24,7 @@ class McpBreakdownInsightsResponseTypedDict(TypedDict): host_applications_breakdown: NotRequired[List[McpHostApplicationBreakdownTypedDict]] tools_breakdown: NotRequired[List[McpToolBreakdownTypedDict]] servers_breakdown: NotRequired[List[McpServerBreakdownTypedDict]] + auth_methods_breakdown: NotRequired[List[McpAuthMethodBreakdownTypedDict]] class McpBreakdownInsightsResponse(BaseModel): @@ -40,6 +45,11 @@ class McpBreakdownInsightsResponse(BaseModel): Optional[List[McpServerBreakdown]], pydantic.Field(alias="serversBreakdown") ] = None + auth_methods_breakdown: Annotated[ + Optional[List[McpAuthMethodBreakdown]], + pydantic.Field(alias="authMethodsBreakdown"), + ] = None + @model_serializer(mode="wrap") def serialize_model(self, handler): optional_fields = set( @@ -48,6 +58,7 @@ def serialize_model(self, handler): "hostApplicationsBreakdown", "toolsBreakdown", "serversBreakdown", + "authMethodsBreakdown", ] ) serialized = handler(self) diff --git a/src/glean/api_client/models/mcpuserbreakdown.py b/src/glean/api_client/models/mcpuserbreakdown.py index ec4587ff..42a1ac29 100644 --- a/src/glean/api_client/models/mcpuserbreakdown.py +++ b/src/glean/api_client/models/mcpuserbreakdown.py @@ -19,6 +19,8 @@ class McpUserBreakdownTypedDict(TypedDict): r"""MCP tools used by this user in the specified time period.""" servers: NotRequired[List[str]] r"""MCP servers used by this user in the specified time period.""" + auth_methods: NotRequired[List[str]] + r"""Authentication methods this user's MCP clients presented in the specified time period, for example OAUTH_XAA for Cross App Access.""" class McpUserBreakdown(BaseModel): @@ -38,10 +40,22 @@ class McpUserBreakdown(BaseModel): servers: Optional[List[str]] = None r"""MCP servers used by this user in the specified time period.""" + auth_methods: Annotated[ + Optional[List[str]], pydantic.Field(alias="authMethods") + ] = None + r"""Authentication methods this user's MCP clients presented in the specified time period, for example OAUTH_XAA for Cross App Access.""" + @model_serializer(mode="wrap") def serialize_model(self, handler): optional_fields = set( - ["person", "totalCalls", "hostApplications", "tools", "servers"] + [ + "person", + "totalCalls", + "hostApplications", + "tools", + "servers", + "authMethods", + ] ) serialized = handler(self) m = {} diff --git a/src/glean/api_client/models/peoplerequest.py b/src/glean/api_client/models/peoplerequest.py index 520c04d8..1ecee9b1 100644 --- a/src/glean/api_client/models/peoplerequest.py +++ b/src/glean/api_client/models/peoplerequest.py @@ -28,6 +28,8 @@ class IncludeType(str, Enum): class PeopleRequestTypedDict(TypedDict): + fallback_to_authenticated_identity: NotRequired[bool] + r"""If true and the current user's people profile is missing, reads the stored SSO profile and returns a minimal Person with its display name, the authenticated user's email, the same obfuscatedId used by a normal self-lookup, and identityOnly set to true. If the SSO profile or its name is unavailable, preserves the missing-profile error. Applies only when emailIds and obfuscatedIds are empty and the request doesn't use act-as, a virtual identity, anonymous authentication, or the INVALID_ENTITIES includeType. The fallback doesn't mask lookup or enrichment errors and doesn't create a directory profile. Normal people profiles don't require an SSO lookup.""" timezone_offset: NotRequired[int] r"""The offset of the client's timezone in minutes from UTC. e.g. PDT is -420 because it's 7 hours behind UTC.""" obfuscated_ids: NotRequired[List[str]] @@ -43,6 +45,11 @@ class PeopleRequestTypedDict(TypedDict): class PeopleRequest(BaseModel): + fallback_to_authenticated_identity: Annotated[ + Optional[bool], pydantic.Field(alias="fallbackToAuthenticatedIdentity") + ] = False + r"""If true and the current user's people profile is missing, reads the stored SSO profile and returns a minimal Person with its display name, the authenticated user's email, the same obfuscatedId used by a normal self-lookup, and identityOnly set to true. If the SSO profile or its name is unavailable, preserves the missing-profile error. Applies only when emailIds and obfuscatedIds are empty and the request doesn't use act-as, a virtual identity, anonymous authentication, or the INVALID_ENTITIES includeType. The fallback doesn't mask lookup or enrichment errors and doesn't create a directory profile. Normal people profiles don't require an SSO lookup.""" + timezone_offset: Annotated[ Optional[int], pydantic.Field(alias="timezoneOffset") ] = None @@ -73,6 +80,7 @@ class PeopleRequest(BaseModel): def serialize_model(self, handler): optional_fields = set( [ + "fallbackToAuthenticatedIdentity", "timezoneOffset", "obfuscatedIds", "emailIds", diff --git a/src/glean/api_client/models/person.py b/src/glean/api_client/models/person.py index 24355a99..be88dd7e 100644 --- a/src/glean/api_client/models/person.py +++ b/src/glean/api_client/models/person.py @@ -17,6 +17,8 @@ class PersonTypedDict(TypedDict): r"""The display name.""" obfuscated_id: str r"""An opaque identifier that can be used to request metadata for a Person.""" + identity_only: NotRequired[bool] + r"""True when this is an authenticated identity fallback rather than a people profile. Directory metadata is unavailable.""" related_documents: NotRequired[List["RelatedDocumentsTypedDict"]] r"""A list of documents related to this person.""" metadata: NotRequired["PersonMetadataTypedDict"] @@ -29,6 +31,11 @@ class Person(BaseModel): obfuscated_id: Annotated[str, pydantic.Field(alias="obfuscatedId")] r"""An opaque identifier that can be used to request metadata for a Person.""" + identity_only: Annotated[Optional[bool], pydantic.Field(alias="identityOnly")] = ( + None + ) + r"""True when this is an authenticated identity fallback rather than a people profile. Directory metadata is unavailable.""" + related_documents: Annotated[ Optional[List["RelatedDocuments"]], pydantic.Field(alias="relatedDocuments") ] = None @@ -38,7 +45,7 @@ class Person(BaseModel): @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = set(["relatedDocuments", "metadata"]) + optional_fields = set(["identityOnly", "relatedDocuments", "metadata"]) serialized = handler(self) m = {} diff --git a/src/glean/api_client/models/platform_admin_usage_requests_getop.py b/src/glean/api_client/models/platform_admin_usage_requests_getop.py new file mode 100644 index 00000000..da130624 --- /dev/null +++ b/src/glean/api_client/models/platform_admin_usage_requests_getop.py @@ -0,0 +1,18 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from glean.api_client.types import BaseModel +from glean.api_client.utils import FieldMetadata, PathParamMetadata +from typing_extensions import Annotated, TypedDict + + +class PlatformAdminUsageRequestsGetRequestTypedDict(TypedDict): + request_id: str + r"""Opaque request identifier; not an authorization grant.""" + + +class PlatformAdminUsageRequestsGetRequest(BaseModel): + request_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + r"""Opaque request identifier; not an authorization grant.""" diff --git a/src/glean/api_client/models/platform_admin_usage_requests_listop.py b/src/glean/api_client/models/platform_admin_usage_requests_listop.py new file mode 100644 index 00000000..02b0f11f --- /dev/null +++ b/src/glean/api_client/models/platform_admin_usage_requests_listop.py @@ -0,0 +1,54 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformrequestfilter import PlatformRequestFilter, PlatformRequestFilterTypedDict +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from glean.api_client.utils import FieldMetadata, QueryParamMetadata +from pydantic import model_serializer +from typing import List, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class PlatformAdminUsageRequestsListRequestTypedDict(TypedDict): + page_size: NotRequired[int] + r"""Maximum page size; defaults to 20 and cannot exceed 100.""" + cursor: NotRequired[str] + r"""Opaque continuation bound to filters and current authorization.""" + filters: NotRequired[List[PlatformRequestFilterTypedDict]] + r"""Optional structured filters on request status.""" + + +class PlatformAdminUsageRequestsListRequest(BaseModel): + page_size: Annotated[ + Optional[int], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = 20 + r"""Maximum page size; defaults to 20 and cannot exceed 100.""" + + cursor: Annotated[ + Optional[str], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = None + r"""Opaque continuation bound to filters and current authorization.""" + + filters: Annotated[ + Optional[List[PlatformRequestFilter]], + FieldMetadata(query=QueryParamMetadata(serialization="json")), + ] = None + r"""Optional structured filters on request status.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["page_size", "cursor", "filters"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m diff --git a/src/glean/api_client/models/platform_skills_list_versionsop.py b/src/glean/api_client/models/platform_skills_list_versionsop.py index 145d396d..b34fd73f 100644 --- a/src/glean/api_client/models/platform_skills_list_versionsop.py +++ b/src/glean/api_client/models/platform_skills_list_versionsop.py @@ -12,7 +12,7 @@ class PlatformSkillsListVersionsRequestTypedDict(TypedDict): skill_id: str r"""Glean skill ID.""" page_size: NotRequired[int] - r"""Maximum number of versions to return.""" + r"""Maximum number of versions to return. Defaults to 20. Maximum is 100.""" cursor: NotRequired[str] r"""Opaque pagination cursor from a previous response.""" @@ -26,8 +26,8 @@ class PlatformSkillsListVersionsRequest(BaseModel): page_size: Annotated[ Optional[int], FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), - ] = None - r"""Maximum number of versions to return.""" + ] = 20 + r"""Maximum number of versions to return. Defaults to 20. Maximum is 100.""" cursor: Annotated[ Optional[str], diff --git a/src/glean/api_client/models/platform_skills_listop.py b/src/glean/api_client/models/platform_skills_listop.py index 3f774193..5c21fa77 100644 --- a/src/glean/api_client/models/platform_skills_listop.py +++ b/src/glean/api_client/models/platform_skills_listop.py @@ -10,7 +10,7 @@ class PlatformSkillsListRequestTypedDict(TypedDict): page_size: NotRequired[int] - r"""Maximum number of skills to return.""" + r"""Maximum number of skills to return. Defaults to 20. Maximum is 100.""" cursor: NotRequired[str] r"""Opaque pagination cursor from a previous response.""" @@ -19,8 +19,8 @@ class PlatformSkillsListRequest(BaseModel): page_size: Annotated[ Optional[int], FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), - ] = None - r"""Maximum number of skills to return.""" + ] = 20 + r"""Maximum number of skills to return. Defaults to 20. Maximum is 100.""" cursor: Annotated[ Optional[str], diff --git a/src/glean/api_client/models/platformskillsourcepreviewrequest.py b/src/glean/api_client/models/platform_skills_preview_source_streamop.py similarity index 58% rename from src/glean/api_client/models/platformskillsourcepreviewrequest.py rename to src/glean/api_client/models/platform_skills_preview_source_streamop.py index 92057490..2ce11df6 100644 --- a/src/glean/api_client/models/platformskillsourcepreviewrequest.py +++ b/src/glean/api_client/models/platform_skills_preview_source_streamop.py @@ -2,24 +2,28 @@ from __future__ import annotations from glean.api_client.types import BaseModel, UNSET_SENTINEL +from glean.api_client.utils import validate_const +import pydantic from pydantic import model_serializer -from typing import Optional -from typing_extensions import NotRequired, TypedDict +from pydantic.functional_validators import AfterValidator +from typing import Literal, Optional +from typing_extensions import Annotated, TypedDict -class PlatformSkillSourcePreviewRequestTypedDict(TypedDict): +class PlatformSkillsPreviewSourceStreamRequestTypedDict(TypedDict): source_url: str r"""GitHub URL for a skill directory, SKILL.md file, or repository to inspect.""" - stream: NotRequired[bool] - r"""Whether to stream repository scan progress using server-sent events.""" + stream: Literal[True] -class PlatformSkillSourcePreviewRequest(BaseModel): +class PlatformSkillsPreviewSourceStreamRequest(BaseModel): source_url: str r"""GitHub URL for a skill directory, SKILL.md file, or repository to inspect.""" - stream: Optional[bool] = False - r"""Whether to stream repository scan progress using server-sent events.""" + STREAM: Annotated[ + Annotated[Optional[Literal[True]], AfterValidator(validate_const(True))], + pydantic.Field(alias="stream"), + ] = True @model_serializer(mode="wrap") def serialize_model(self, handler): @@ -36,3 +40,9 @@ def serialize_model(self, handler): m[k] = val return m + + +try: + PlatformSkillsPreviewSourceStreamRequest.model_rebuild() +except NameError: + pass diff --git a/src/glean/api_client/models/platform_skills_preview_sourceop.py b/src/glean/api_client/models/platform_skills_preview_sourceop.py index 30dcdd72..f5667276 100644 --- a/src/glean/api_client/models/platform_skills_preview_sourceop.py +++ b/src/glean/api_client/models/platform_skills_preview_sourceop.py @@ -1,21 +1,48 @@ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" from __future__ import annotations -from .platformskillsourcepreviewresponse import ( - PlatformSkillSourcePreviewResponse, - PlatformSkillSourcePreviewResponseTypedDict, -) -from typing import Union -from typing_extensions import TypeAliasType +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from glean.api_client.utils import validate_const +import pydantic +from pydantic import model_serializer +from pydantic.functional_validators import AfterValidator +from typing import Literal, Optional +from typing_extensions import Annotated, TypedDict -PlatformSkillsPreviewSourceResponseTypedDict = TypeAliasType( - "PlatformSkillsPreviewSourceResponseTypedDict", - Union[PlatformSkillSourcePreviewResponseTypedDict, str], -) +class PlatformSkillsPreviewSourceRequestTypedDict(TypedDict): + source_url: str + r"""GitHub URL for a skill directory, SKILL.md file, or repository to inspect.""" + stream: Literal[False] -PlatformSkillsPreviewSourceResponse = TypeAliasType( - "PlatformSkillsPreviewSourceResponse", - Union[PlatformSkillSourcePreviewResponse, str], -) +class PlatformSkillsPreviewSourceRequest(BaseModel): + source_url: str + r"""GitHub URL for a skill directory, SKILL.md file, or repository to inspect.""" + + STREAM: Annotated[ + Annotated[Optional[Literal[False]], AfterValidator(validate_const(False))], + pydantic.Field(alias="stream"), + ] = False + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["stream"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m + + +try: + PlatformSkillsPreviewSourceRequest.model_rebuild() +except NameError: + pass diff --git a/src/glean/api_client/models/platform_usage_requests_getop.py b/src/glean/api_client/models/platform_usage_requests_getop.py new file mode 100644 index 00000000..31a885aa --- /dev/null +++ b/src/glean/api_client/models/platform_usage_requests_getop.py @@ -0,0 +1,18 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from glean.api_client.types import BaseModel +from glean.api_client.utils import FieldMetadata, PathParamMetadata +from typing_extensions import Annotated, TypedDict + + +class PlatformUsageRequestsGetRequestTypedDict(TypedDict): + request_id: str + r"""Opaque personal request identifier; not an authorization grant.""" + + +class PlatformUsageRequestsGetRequest(BaseModel): + request_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + r"""Opaque personal request identifier; not an authorization grant.""" diff --git a/src/glean/api_client/models/platform_usage_requests_listop.py b/src/glean/api_client/models/platform_usage_requests_listop.py new file mode 100644 index 00000000..e03e60d4 --- /dev/null +++ b/src/glean/api_client/models/platform_usage_requests_listop.py @@ -0,0 +1,54 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformrequestfilter import PlatformRequestFilter, PlatformRequestFilterTypedDict +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from glean.api_client.utils import FieldMetadata, QueryParamMetadata +from pydantic import model_serializer +from typing import List, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class PlatformUsageRequestsListRequestTypedDict(TypedDict): + page_size: NotRequired[int] + r"""Maximum page size; defaults to 20 and cannot exceed 100.""" + cursor: NotRequired[str] + r"""Opaque continuation bound to filters and current authorization.""" + filters: NotRequired[List[PlatformRequestFilterTypedDict]] + r"""Optional structured filters on request status.""" + + +class PlatformUsageRequestsListRequest(BaseModel): + page_size: Annotated[ + Optional[int], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = 20 + r"""Maximum page size; defaults to 20 and cannot exceed 100.""" + + cursor: Annotated[ + Optional[str], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = None + r"""Opaque continuation bound to filters and current authorization.""" + + filters: Annotated[ + Optional[List[PlatformRequestFilter]], + FieldMetadata(query=QueryParamMetadata(serialization="json")), + ] = None + r"""Optional structured filters on request status.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["page_size", "cursor", "filters"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m diff --git a/src/glean/api_client/models/platformagentrequestcreate.py b/src/glean/api_client/models/platformagentrequestcreate.py new file mode 100644 index 00000000..f3614d69 --- /dev/null +++ b/src/glean/api_client/models/platformagentrequestcreate.py @@ -0,0 +1,47 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from pydantic import model_serializer +from typing import Optional +from typing_extensions import NotRequired, TypedDict + + +class PlatformAgentRequestCreateTypedDict(TypedDict): + r"""New client-scoped request for an editable agent in the server's current UTC month.""" + + agent_id: str + r"""Identifier of the agent whose limit the request concerns.""" + client_id: str + r"""Explicit spend client whose limit the request concerns.""" + business_justification: NotRequired[str] + r"""Optional explanation of why the increase is needed.""" + + +class PlatformAgentRequestCreate(BaseModel): + r"""New client-scoped request for an editable agent in the server's current UTC month.""" + + agent_id: str + r"""Identifier of the agent whose limit the request concerns.""" + + client_id: str + r"""Explicit spend client whose limit the request concerns.""" + + business_justification: Optional[str] = None + r"""Optional explanation of why the increase is needed.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["business_justification"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m diff --git a/src/glean/api_client/models/platformlimitincreaserequest.py b/src/glean/api_client/models/platformlimitincreaserequest.py new file mode 100644 index 00000000..ffa63593 --- /dev/null +++ b/src/glean/api_client/models/platformlimitincreaserequest.py @@ -0,0 +1,176 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformrequestresolutiontarget import PlatformRequestResolutionTarget +from .platformrequestscope import PlatformRequestScope +from .platformrequeststatus import PlatformRequestStatus +from datetime import datetime +from enum import Enum +from glean.api_client import models, utils +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from pydantic import field_serializer, model_serializer +from typing import Optional +from typing_extensions import NotRequired, TypedDict + + +class PlatformLimitIncreaseRequestEntityType(str, Enum, metaclass=utils.OpenEnumMeta): + r"""Whether the request concerns a user or an agent.""" + + USER = "USER" + AGENT = "AGENT" + + +class PlatformLimitIncreaseRequestTypedDict(TypedDict): + r"""Stored user or agent request, with optional resolution fields when available.""" + + request_id: str + r"""Server-assigned resource identifier, distinct from the response's trace request_id.""" + entity_type: PlatformLimitIncreaseRequestEntityType + r"""Whether the request concerns a user or an agent.""" + entity_id: str + r"""Canonical user ID or agent ID whose limit the request concerns.""" + client_id: str + r"""Spend client for this user or agent request.""" + requester_user_id: str + r"""Authenticated user who created the request.""" + period: str + r"""UTC calendar month in YYYY-MM format, assigned by the server at creation.""" + status: PlatformRequestStatus + r"""Stored request state.""" + created_at: datetime + r"""Request creation time.""" + business_justification: NotRequired[str] + r"""Stored explanation of why the increase is needed, when supplied.""" + resolved_by_user_id: NotRequired[str] + r"""User who resolved the request, when available.""" + approved_increase_amount: NotRequired[str] + r"""Positive additive increase in the applicable rule's denomination, encoded as a plain decimal string. The backend stores float32 values, not arbitrary-precision decimals. + + """ + scope: NotRequired[PlatformRequestScope] + r"""Increase for the stored request month or an ongoing standing-rule increase.""" + resolution_target: NotRequired[PlatformRequestResolutionTarget] + r"""Breadth of the approved increase; GROUP identifies an IdP group.""" + resolution_target_id: NotRequired[str] + r"""Stored department or canonical IdP group ID, when available.""" + resolution_note: NotRequired[str] + r"""Stored denial note, when supplied.""" + updated_at: NotRequired[datetime] + r"""Last stored update time; this is the resolution time for resolved requests.""" + + +class PlatformLimitIncreaseRequest(BaseModel): + r"""Stored user or agent request, with optional resolution fields when available.""" + + request_id: str + r"""Server-assigned resource identifier, distinct from the response's trace request_id.""" + + entity_type: PlatformLimitIncreaseRequestEntityType + r"""Whether the request concerns a user or an agent.""" + + entity_id: str + r"""Canonical user ID or agent ID whose limit the request concerns.""" + + client_id: str + r"""Spend client for this user or agent request.""" + + requester_user_id: str + r"""Authenticated user who created the request.""" + + period: str + r"""UTC calendar month in YYYY-MM format, assigned by the server at creation.""" + + status: PlatformRequestStatus + r"""Stored request state.""" + + created_at: datetime + r"""Request creation time.""" + + business_justification: Optional[str] = None + r"""Stored explanation of why the increase is needed, when supplied.""" + + resolved_by_user_id: Optional[str] = None + r"""User who resolved the request, when available.""" + + approved_increase_amount: Optional[str] = None + r"""Positive additive increase in the applicable rule's denomination, encoded as a plain decimal string. The backend stores float32 values, not arbitrary-precision decimals. + + """ + + scope: Optional[PlatformRequestScope] = None + r"""Increase for the stored request month or an ongoing standing-rule increase.""" + + resolution_target: Optional[PlatformRequestResolutionTarget] = None + r"""Breadth of the approved increase; GROUP identifies an IdP group.""" + + resolution_target_id: Optional[str] = None + r"""Stored department or canonical IdP group ID, when available.""" + + resolution_note: Optional[str] = None + r"""Stored denial note, when supplied.""" + + updated_at: Optional[datetime] = None + r"""Last stored update time; this is the resolution time for resolved requests.""" + + @field_serializer("entity_type") + def serialize_entity_type(self, value): + if isinstance(value, str): + try: + return models.PlatformLimitIncreaseRequestEntityType(value) + except ValueError: + return value + return value + + @field_serializer("status") + def serialize_status(self, value): + if isinstance(value, str): + try: + return models.PlatformRequestStatus(value) + except ValueError: + return value + return value + + @field_serializer("scope") + def serialize_scope(self, value): + if isinstance(value, str): + try: + return models.PlatformRequestScope(value) + except ValueError: + return value + return value + + @field_serializer("resolution_target") + def serialize_resolution_target(self, value): + if isinstance(value, str): + try: + return models.PlatformRequestResolutionTarget(value) + except ValueError: + return value + return value + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set( + [ + "business_justification", + "resolved_by_user_id", + "approved_increase_amount", + "scope", + "resolution_target", + "resolution_target_id", + "resolution_note", + "updated_at", + ] + ) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m diff --git a/src/glean/api_client/models/platformlimitincreaserequestsettings.py b/src/glean/api_client/models/platformlimitincreaserequestsettings.py new file mode 100644 index 00000000..ac77b5eb --- /dev/null +++ b/src/glean/api_client/models/platformlimitincreaserequestsettings.py @@ -0,0 +1,42 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from enum import Enum +from glean.api_client import models, utils +from glean.api_client.types import BaseModel +from pydantic import field_serializer +from typing_extensions import TypedDict + + +class BusinessJustification(str, Enum, metaclass=utils.OpenEnumMeta): + r"""Whether a business justification is required when requesting a usage limit increase.""" + + OPTIONAL = "OPTIONAL" + REQUIRED = "REQUIRED" + + +class PlatformLimitIncreaseRequestSettingsTypedDict(TypedDict): + r"""Settings that govern usage limit increase requests.""" + + business_justification: BusinessJustification + r"""Whether a business justification is required when requesting a usage limit increase. + + """ + + +class PlatformLimitIncreaseRequestSettings(BaseModel): + r"""Settings that govern usage limit increase requests.""" + + business_justification: BusinessJustification + r"""Whether a business justification is required when requesting a usage limit increase. + + """ + + @field_serializer("business_justification") + def serialize_business_justification(self, value): + if isinstance(value, str): + try: + return models.BusinessJustification(value) + except ValueError: + return value + return value diff --git a/src/glean/api_client/models/platformmultiplemembershipresolutionsettings.py b/src/glean/api_client/models/platformmultiplemembershipresolutionsettings.py new file mode 100644 index 00000000..d3669b07 --- /dev/null +++ b/src/glean/api_client/models/platformmultiplemembershipresolutionsettings.py @@ -0,0 +1,23 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformpermembersettings import ( + PlatformPerMemberSettings, + PlatformPerMemberSettingsTypedDict, +) +from glean.api_client.types import BaseModel +from typing_extensions import TypedDict + + +class PlatformMultipleMembershipResolutionSettingsTypedDict(TypedDict): + r"""Settings for resolving limits across multiple memberships.""" + + per_member: PlatformPerMemberSettingsTypedDict + r"""Resolution settings for the per-member limit family.""" + + +class PlatformMultipleMembershipResolutionSettings(BaseModel): + r"""Settings for resolving limits across multiple memberships.""" + + per_member: PlatformPerMemberSettings + r"""Resolution settings for the per-member limit family.""" diff --git a/src/glean/api_client/models/platformpermembersettings.py b/src/glean/api_client/models/platformpermembersettings.py new file mode 100644 index 00000000..55f1d0ee --- /dev/null +++ b/src/glean/api_client/models/platformpermembersettings.py @@ -0,0 +1,42 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from enum import Enum +from glean.api_client import models, utils +from glean.api_client.types import BaseModel +from pydantic import field_serializer +from typing_extensions import TypedDict + + +class IdpGroups(str, Enum, metaclass=utils.OpenEnumMeta): + r"""How to resolve effective usage limits when a user belongs to multiple IdP groups.""" + + HIGHEST = "HIGHEST" + LOWEST = "LOWEST" + + +class PlatformPerMemberSettingsTypedDict(TypedDict): + r"""Resolution settings for the per-member limit family.""" + + idp_groups: IdpGroups + r"""How to resolve effective usage limits when a user belongs to multiple IdP groups. + + """ + + +class PlatformPerMemberSettings(BaseModel): + r"""Resolution settings for the per-member limit family.""" + + idp_groups: IdpGroups + r"""How to resolve effective usage limits when a user belongs to multiple IdP groups. + + """ + + @field_serializer("idp_groups") + def serialize_idp_groups(self, value): + if isinstance(value, str): + try: + return models.IdpGroups(value) + except ValueError: + return value + return value diff --git a/src/glean/api_client/models/platformpersonalrequestcreate.py b/src/glean/api_client/models/platformpersonalrequestcreate.py new file mode 100644 index 00000000..9df2f166 --- /dev/null +++ b/src/glean/api_client/models/platformpersonalrequestcreate.py @@ -0,0 +1,42 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from pydantic import model_serializer +from typing import Optional +from typing_extensions import NotRequired, TypedDict + + +class PlatformPersonalRequestCreateTypedDict(TypedDict): + r"""New request for the authenticated canonical user in the server's current UTC month.""" + + client_id: str + r"""Explicit spend client whose limit the request concerns.""" + business_justification: NotRequired[str] + r"""Optional explanation of why the increase is needed.""" + + +class PlatformPersonalRequestCreate(BaseModel): + r"""New request for the authenticated canonical user in the server's current UTC month.""" + + client_id: str + r"""Explicit spend client whose limit the request concerns.""" + + business_justification: Optional[str] = None + r"""Optional explanation of why the increase is needed.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["business_justification"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m diff --git a/src/glean/api_client/models/platformproblemdetail.py b/src/glean/api_client/models/platformproblemdetail.py new file mode 100644 index 00000000..05d4d46e --- /dev/null +++ b/src/glean/api_client/models/platformproblemdetail.py @@ -0,0 +1,87 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformproblemdetailcode import PlatformProblemDetailCode +from .platformproblemdetailerror import ( + PlatformProblemDetailError, + PlatformProblemDetailErrorTypedDict, +) +from glean.api_client import models +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from pydantic import field_serializer, model_serializer +from typing import List, Optional +from typing_extensions import NotRequired, TypedDict + + +class PlatformProblemDetailTypedDict(TypedDict): + r"""Error response following RFC 9457, extended with `code` and `documentation_url` for machine-readable classification and self-service remediation.""" + + type: str + r"""URI identifying the error type.""" + title: str + r"""Short, human-readable summary of the error.""" + status: int + r"""HTTP status code mirrored from the response.""" + detail: str + r"""Human-readable explanation specific to this occurrence.""" + code: PlatformProblemDetailCode + r"""Stable machine-readable error code.""" + request_id: str + r"""Platform-generated request ID for support correlation.""" + documentation_url: NotRequired[str] + r"""Direct URL to documentation for this error code.""" + errors: NotRequired[List[PlatformProblemDetailErrorTypedDict]] + r"""Field-level validation problems, one entry per offending field.""" + + +class PlatformProblemDetail(BaseModel): + r"""Error response following RFC 9457, extended with `code` and `documentation_url` for machine-readable classification and self-service remediation.""" + + type: str + r"""URI identifying the error type.""" + + title: str + r"""Short, human-readable summary of the error.""" + + status: int + r"""HTTP status code mirrored from the response.""" + + detail: str + r"""Human-readable explanation specific to this occurrence.""" + + code: PlatformProblemDetailCode + r"""Stable machine-readable error code.""" + + request_id: str + r"""Platform-generated request ID for support correlation.""" + + documentation_url: Optional[str] = None + r"""Direct URL to documentation for this error code.""" + + errors: Optional[List[PlatformProblemDetailError]] = None + r"""Field-level validation problems, one entry per offending field.""" + + @field_serializer("code") + def serialize_code(self, value): + if isinstance(value, str): + try: + return models.PlatformProblemDetailCode(value) + except ValueError: + return value + return value + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["documentation_url", "errors"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m diff --git a/src/glean/api_client/models/platformrequestfilter.py b/src/glean/api_client/models/platformrequestfilter.py new file mode 100644 index 00000000..193c028f --- /dev/null +++ b/src/glean/api_client/models/platformrequestfilter.py @@ -0,0 +1,60 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformrequeststatus import PlatformRequestStatus +from enum import Enum +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from pydantic import model_serializer +from typing import List, Optional +from typing_extensions import NotRequired, TypedDict + + +class Operator(str, Enum): + r"""Only EQUALS is supported; defaults to EQUALS when omitted.""" + + EQUALS = "EQUALS" + NOT_EQUALS = "NOT_EQUALS" + GT = "GT" + GTE = "GTE" + LT = "LT" + LTE = "LTE" + + +class PlatformRequestFilterTypedDict(TypedDict): + r"""A status filter using the backend's status-IN matching.""" + + field: str + r"""Allowed field is status, spelled exactly in lowercase.""" + values: List[PlatformRequestStatus] + r"""Status values to match with OR.""" + operator: NotRequired[Operator] + r"""Only EQUALS is supported; defaults to EQUALS when omitted.""" + + +class PlatformRequestFilter(BaseModel): + r"""A status filter using the backend's status-IN matching.""" + + field: str + r"""Allowed field is status, spelled exactly in lowercase.""" + + values: List[PlatformRequestStatus] + r"""Status values to match with OR.""" + + operator: Optional[Operator] = Operator.EQUALS + r"""Only EQUALS is supported; defaults to EQUALS when omitted.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["operator"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m diff --git a/src/glean/api_client/models/platformrequestlistresponse_union.py b/src/glean/api_client/models/platformrequestlistresponse_union.py new file mode 100644 index 00000000..cbbf2ff1 --- /dev/null +++ b/src/glean/api_client/models/platformrequestlistresponse_union.py @@ -0,0 +1,128 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformlimitincreaserequest import ( + PlatformLimitIncreaseRequest, + PlatformLimitIncreaseRequestTypedDict, +) +from glean.api_client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from pydantic import model_serializer +from typing import List, Union +from typing_extensions import NotRequired, TypeAliasType, TypedDict + + +class PlatformRequestListResponse2TypedDict(TypedDict): + r"""The last page has no continuation cursor.""" + + has_more: bool + r"""Whether a further page is available through next_cursor.""" + results: List[PlatformLimitIncreaseRequestTypedDict] + r"""Requests visible to the caller under the current filters and authorization.""" + request_id: str + r"""Trace identifier for this list response, not a request resource ID.""" + next_cursor: NotRequired[Nullable[str]] + r"""Opaque nonempty continuation when has_more is true; null or omitted otherwise.""" + + +class PlatformRequestListResponse2(BaseModel): + r"""The last page has no continuation cursor.""" + + has_more: bool + r"""Whether a further page is available through next_cursor.""" + + results: List[PlatformLimitIncreaseRequest] + r"""Requests visible to the caller under the current filters and authorization.""" + + request_id: str + r"""Trace identifier for this list response, not a request resource ID.""" + + next_cursor: OptionalNullable[str] = UNSET + r"""Opaque nonempty continuation when has_more is true; null or omitted otherwise.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["next_cursor"]) + nullable_fields = set(["next_cursor"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + is_nullable_and_explicitly_set = ( + k in nullable_fields + and (self.__pydantic_fields_set__.intersection({n})) # pylint: disable=no-member + ) + + if val != UNSET_SENTINEL: + if ( + val is not None + or k not in optional_fields + or is_nullable_and_explicitly_set + ): + m[k] = val + + return m + + +class PlatformRequestListResponse1TypedDict(TypedDict): + r"""A further page requires a usable continuation cursor.""" + + has_more: bool + r"""Whether a further page is available through next_cursor.""" + next_cursor: Nullable[str] + r"""Opaque nonempty continuation when has_more is true; null or omitted otherwise.""" + results: List[PlatformLimitIncreaseRequestTypedDict] + r"""Requests visible to the caller under the current filters and authorization.""" + request_id: str + r"""Trace identifier for this list response, not a request resource ID.""" + + +class PlatformRequestListResponse1(BaseModel): + r"""A further page requires a usable continuation cursor.""" + + has_more: bool + r"""Whether a further page is available through next_cursor.""" + + next_cursor: Nullable[str] + r"""Opaque nonempty continuation when has_more is true; null or omitted otherwise.""" + + results: List[PlatformLimitIncreaseRequest] + r"""Requests visible to the caller under the current filters and authorization.""" + + request_id: str + r"""Trace identifier for this list response, not a request resource ID.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + m[k] = val + + return m + + +PlatformRequestListResponseUnionTypedDict = TypeAliasType( + "PlatformRequestListResponseUnionTypedDict", + Union[PlatformRequestListResponse1TypedDict, PlatformRequestListResponse2TypedDict], +) +r"""Bounded page of authorized requests with opaque continuation state.""" + + +PlatformRequestListResponseUnion = TypeAliasType( + "PlatformRequestListResponseUnion", + Union[PlatformRequestListResponse1, PlatformRequestListResponse2], +) +r"""Bounded page of authorized requests with opaque continuation state.""" diff --git a/src/glean/api_client/models/platformrequestresolutiontarget.py b/src/glean/api_client/models/platformrequestresolutiontarget.py new file mode 100644 index 00000000..91372973 --- /dev/null +++ b/src/glean/api_client/models/platformrequestresolutiontarget.py @@ -0,0 +1,14 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from enum import Enum +from glean.api_client import utils + + +class PlatformRequestResolutionTarget(str, Enum, metaclass=utils.OpenEnumMeta): + r"""Breadth of the approved increase; GROUP identifies an IdP group.""" + + USER = "USER" + ALL = "ALL" + DEPARTMENT = "DEPARTMENT" + GROUP = "GROUP" diff --git a/src/glean/api_client/models/platformrequestresponse.py b/src/glean/api_client/models/platformrequestresponse.py new file mode 100644 index 00000000..b77c0919 --- /dev/null +++ b/src/glean/api_client/models/platformrequestresponse.py @@ -0,0 +1,28 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformlimitincreaserequest import ( + PlatformLimitIncreaseRequest, + PlatformLimitIncreaseRequestTypedDict, +) +from glean.api_client.types import BaseModel +from typing_extensions import TypedDict + + +class PlatformRequestResponseTypedDict(TypedDict): + r"""Single authorized request with the enclosing response's trace identifier.""" + + request: PlatformLimitIncreaseRequestTypedDict + r"""Stored user or agent request, with optional resolution fields when available.""" + request_id: str + r"""Trace identifier, distinct from the resource ID.""" + + +class PlatformRequestResponse(BaseModel): + r"""Single authorized request with the enclosing response's trace identifier.""" + + request: PlatformLimitIncreaseRequest + r"""Stored user or agent request, with optional resolution fields when available.""" + + request_id: str + r"""Trace identifier, distinct from the resource ID.""" diff --git a/src/glean/api_client/models/platformrequestscope.py b/src/glean/api_client/models/platformrequestscope.py new file mode 100644 index 00000000..7aa6be66 --- /dev/null +++ b/src/glean/api_client/models/platformrequestscope.py @@ -0,0 +1,12 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from enum import Enum +from glean.api_client import utils + + +class PlatformRequestScope(str, Enum, metaclass=utils.OpenEnumMeta): + r"""Increase for the stored request month or an ongoing standing-rule increase.""" + + PERIOD = "PERIOD" + ONGOING = "ONGOING" diff --git a/src/glean/api_client/models/platformrequeststatus.py b/src/glean/api_client/models/platformrequeststatus.py new file mode 100644 index 00000000..87664735 --- /dev/null +++ b/src/glean/api_client/models/platformrequeststatus.py @@ -0,0 +1,13 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from enum import Enum +from glean.api_client import utils + + +class PlatformRequestStatus(str, Enum, metaclass=utils.OpenEnumMeta): + r"""Stored request state.""" + + PENDING = "PENDING" + APPROVED = "APPROVED" + DENIED = "DENIED" diff --git a/src/glean/api_client/models/platformskill.py b/src/glean/api_client/models/platformskill.py index 4b7e21a7..d77b1fa2 100644 --- a/src/glean/api_client/models/platformskill.py +++ b/src/glean/api_client/models/platformskill.py @@ -20,7 +20,7 @@ class PlatformSkillTypedDict(TypedDict): - id: str + skill_id: str r"""Glean skill ID.""" display_name: str r"""Human-readable skill name.""" @@ -31,7 +31,9 @@ class PlatformSkillTypedDict(TypedDict): latest_minor_version: int r"""Latest minor version number for the skill.""" status: PlatformSkillStatus - r"""Current skill status.""" + r"""The caller's effective activation. The owner sees the skill's stored status. Another caller sees their personal setting, or DISABLED when they have none. DRAFT is the stored draft state and is not set by update. Effective activation may also reflect workspace governance policy. + + """ origin: PlatformSkillOrigin r"""Source category for the skill.""" owner: PlatformPersonReferenceTypedDict @@ -44,7 +46,7 @@ class PlatformSkillTypedDict(TypedDict): class PlatformSkill(BaseModel): - id: str + skill_id: str r"""Glean skill ID.""" display_name: str @@ -60,7 +62,9 @@ class PlatformSkill(BaseModel): r"""Latest minor version number for the skill.""" status: PlatformSkillStatus - r"""Current skill status.""" + r"""The caller's effective activation. The owner sees the skill's stored status. Another caller sees their personal setting, or DISABLED when they have none. DRAFT is the stored draft state and is not set by update. Effective activation may also reflect workspace governance policy. + + """ origin: PlatformSkillOrigin r"""Source category for the skill.""" @@ -85,6 +89,15 @@ def serialize_status(self, value): return value return value + @field_serializer("origin") + def serialize_origin(self, value): + if isinstance(value, str): + try: + return models.PlatformSkillOrigin(value) + except ValueError: + return value + return value + @model_serializer(mode="wrap") def serialize_model(self, handler): optional_fields = set(["source_provenance"]) diff --git a/src/glean/api_client/models/platformskillimportresponse.py b/src/glean/api_client/models/platformskillimportresponse.py index 4e8827e5..f0789925 100644 --- a/src/glean/api_client/models/platformskillimportresponse.py +++ b/src/glean/api_client/models/platformskillimportresponse.py @@ -9,14 +9,18 @@ class PlatformSkillImportResponseTypedDict(TypedDict): skills: List[PlatformSkillTypedDict] - r"""Independently persisted skills in request order.""" + r"""Imported skills in request order. The import is atomic: either every source persists or none does. + + """ request_id: str r"""Platform-generated request ID for support correlation.""" class PlatformSkillImportResponse(BaseModel): skills: List[PlatformSkill] - r"""Independently persisted skills in request order.""" + r"""Imported skills in request order. The import is atomic: either every source persists or none does. + + """ request_id: str r"""Platform-generated request ID for support correlation.""" diff --git a/src/glean/api_client/models/platformskillorigin.py b/src/glean/api_client/models/platformskillorigin.py index 320c60ec..f05da6ac 100644 --- a/src/glean/api_client/models/platformskillorigin.py +++ b/src/glean/api_client/models/platformskillorigin.py @@ -2,9 +2,11 @@ from __future__ import annotations from enum import Enum +from glean.api_client import utils -class PlatformSkillOrigin(str, Enum): +class PlatformSkillOrigin(str, Enum, metaclass=utils.OpenEnumMeta): r"""Source category for the skill.""" CUSTOM = "CUSTOM" + GITHUB = "GITHUB" diff --git a/src/glean/api_client/models/platformskillslistresponse.py b/src/glean/api_client/models/platformskillslistresponse.py index 7303b051..8d37912a 100644 --- a/src/glean/api_client/models/platformskillslistresponse.py +++ b/src/glean/api_client/models/platformskillslistresponse.py @@ -9,7 +9,7 @@ class PlatformSkillsListResponseTypedDict(TypedDict): - skills: List[PlatformSkillTypedDict] + results: List[PlatformSkillTypedDict] r"""Skills available to the user.""" has_more: bool r"""Whether additional results are available.""" @@ -20,7 +20,7 @@ class PlatformSkillsListResponseTypedDict(TypedDict): class PlatformSkillsListResponse(BaseModel): - skills: List[PlatformSkill] + results: List[PlatformSkill] r"""Skills available to the user.""" has_more: bool diff --git a/src/glean/api_client/models/platformskillsourcepreviewstreamerror.py b/src/glean/api_client/models/platformskillsourcepreviewstreamerror.py new file mode 100644 index 00000000..68f225d3 --- /dev/null +++ b/src/glean/api_client/models/platformskillsourcepreviewstreamerror.py @@ -0,0 +1,65 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformauthenticationsuggestion import ( + PlatformAuthenticationSuggestion, + PlatformAuthenticationSuggestionTypedDict, +) +from .platformproblemdetail import PlatformProblemDetail, PlatformProblemDetailTypedDict +from enum import Enum +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from pydantic import model_serializer +from typing import List, Optional +from typing_extensions import NotRequired, TypedDict + + +class PlatformSkillSourcePreviewStreamErrorType(str, Enum): + r"""Event type, also sent as the SSE `event` name.""" + + ERROR = "ERROR" + + +class PlatformSkillSourcePreviewStreamErrorTypedDict(TypedDict): + r"""Terminal failure event carrying the failure as a problem detail. Most GitHub authorization failures return HTTP 422 before the stream opens. If authorization fails after the stream opens, `error.code` is `tools_unauthorized` and `authentication_suggestions` is present.""" + + type: PlatformSkillSourcePreviewStreamErrorType + r"""Event type, also sent as the SSE `event` name.""" + error: PlatformProblemDetailTypedDict + r"""Error response following RFC 9457, extended with `code` and `documentation_url` for machine-readable classification and self-service remediation. + + """ + authentication_suggestions: NotRequired[ + List[PlatformAuthenticationSuggestionTypedDict] + ] + r"""Present only when `error.code` is `tools_unauthorized`. Names the GitHub action pack to authorize, with the same retry flow as the 422 response.""" + + +class PlatformSkillSourcePreviewStreamError(BaseModel): + r"""Terminal failure event carrying the failure as a problem detail. Most GitHub authorization failures return HTTP 422 before the stream opens. If authorization fails after the stream opens, `error.code` is `tools_unauthorized` and `authentication_suggestions` is present.""" + + type: PlatformSkillSourcePreviewStreamErrorType + r"""Event type, also sent as the SSE `event` name.""" + + error: PlatformProblemDetail + r"""Error response following RFC 9457, extended with `code` and `documentation_url` for machine-readable classification and self-service remediation. + + """ + + authentication_suggestions: Optional[List[PlatformAuthenticationSuggestion]] = None + r"""Present only when `error.code` is `tools_unauthorized`. Names the GitHub action pack to authorize, with the same retry flow as the 422 response.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["authentication_suggestions"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m diff --git a/src/glean/api_client/models/platformskillsourcepreviewstreamerrorserversentevent.py b/src/glean/api_client/models/platformskillsourcepreviewstreamerrorserversentevent.py new file mode 100644 index 00000000..cd9a68bd --- /dev/null +++ b/src/glean/api_client/models/platformskillsourcepreviewstreamerrorserversentevent.py @@ -0,0 +1,55 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformskillsourcepreviewstreamerror import ( + PlatformSkillSourcePreviewStreamError, + PlatformSkillSourcePreviewStreamErrorTypedDict, +) +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from glean.api_client.utils import validate_const +import pydantic +from pydantic import model_serializer +from pydantic.functional_validators import AfterValidator +from typing import Literal, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class PlatformSkillSourcePreviewStreamErrorServerSentEventTypedDict(TypedDict): + data: PlatformSkillSourcePreviewStreamErrorTypedDict + r"""Terminal failure event carrying the failure as a problem detail. Most GitHub authorization failures return HTTP 422 before the stream opens. If authorization fails after the stream opens, `error.code` is `tools_unauthorized` and `authentication_suggestions` is present.""" + id: NotRequired[str] + event: Literal["ERROR"] + + +class PlatformSkillSourcePreviewStreamErrorServerSentEvent(BaseModel): + data: PlatformSkillSourcePreviewStreamError + r"""Terminal failure event carrying the failure as a problem detail. Most GitHub authorization failures return HTTP 422 before the stream opens. If authorization fails after the stream opens, `error.code` is `tools_unauthorized` and `authentication_suggestions` is present.""" + + id: Optional[str] = None + + EVENT: Annotated[ + Annotated[Literal["ERROR"], AfterValidator(validate_const("ERROR"))], + pydantic.Field(alias="event"), + ] = "ERROR" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["id"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m + + +try: + PlatformSkillSourcePreviewStreamErrorServerSentEvent.model_rebuild() +except NameError: + pass diff --git a/src/glean/api_client/models/platformskillsourcepreviewstreameventserversentevent.py b/src/glean/api_client/models/platformskillsourcepreviewstreameventserversentevent.py new file mode 100644 index 00000000..a4974c16 --- /dev/null +++ b/src/glean/api_client/models/platformskillsourcepreviewstreameventserversentevent.py @@ -0,0 +1,52 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformskillsourcepreviewstreamerrorserversentevent import ( + PlatformSkillSourcePreviewStreamErrorServerSentEvent, + PlatformSkillSourcePreviewStreamErrorServerSentEventTypedDict, +) +from .platformskillsourcepreviewstreamprogressserversentevent import ( + PlatformSkillSourcePreviewStreamProgressServerSentEvent, + PlatformSkillSourcePreviewStreamProgressServerSentEventTypedDict, +) +from .platformskillsourcepreviewstreamresultserversentevent import ( + PlatformSkillSourcePreviewStreamResultServerSentEvent, + PlatformSkillSourcePreviewStreamResultServerSentEventTypedDict, +) +from .platformskillsourcepreviewstreamscanserversentevent import ( + PlatformSkillSourcePreviewStreamScanServerSentEvent, + PlatformSkillSourcePreviewStreamScanServerSentEventTypedDict, +) +from .platformskillsourcepreviewstreamskillserversentevent import ( + PlatformSkillSourcePreviewStreamSkillServerSentEvent, + PlatformSkillSourcePreviewStreamSkillServerSentEventTypedDict, +) +from pydantic import Field +from typing import Union +from typing_extensions import Annotated, TypeAliasType + + +PlatformSkillSourcePreviewStreamEventServerSentEventTypedDict = TypeAliasType( + "PlatformSkillSourcePreviewStreamEventServerSentEventTypedDict", + Union[ + PlatformSkillSourcePreviewStreamScanServerSentEventTypedDict, + PlatformSkillSourcePreviewStreamProgressServerSentEventTypedDict, + PlatformSkillSourcePreviewStreamSkillServerSentEventTypedDict, + PlatformSkillSourcePreviewStreamResultServerSentEventTypedDict, + PlatformSkillSourcePreviewStreamErrorServerSentEventTypedDict, + ], +) +r"""A typed server-sent event.""" + + +PlatformSkillSourcePreviewStreamEventServerSentEvent = Annotated[ + Union[ + PlatformSkillSourcePreviewStreamScanServerSentEvent, + PlatformSkillSourcePreviewStreamProgressServerSentEvent, + PlatformSkillSourcePreviewStreamSkillServerSentEvent, + PlatformSkillSourcePreviewStreamResultServerSentEvent, + PlatformSkillSourcePreviewStreamErrorServerSentEvent, + ], + Field(discriminator="EVENT"), +] +r"""A typed server-sent event.""" diff --git a/src/glean/api_client/models/platformskillsourcepreviewstreamprogress.py b/src/glean/api_client/models/platformskillsourcepreviewstreamprogress.py new file mode 100644 index 00000000..ecca3b70 --- /dev/null +++ b/src/glean/api_client/models/platformskillsourcepreviewstreamprogress.py @@ -0,0 +1,41 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from enum import Enum +from glean.api_client.types import BaseModel +from typing_extensions import TypedDict + + +class PlatformSkillSourcePreviewStreamProgressType(str, Enum): + r"""Event type, also sent as the SSE `event` name.""" + + PROGRESS = "PROGRESS" + + +class PlatformSkillSourcePreviewStreamProgressTypedDict(TypedDict): + r"""One skill finished inspecting; names the skill in progress.""" + + type: PlatformSkillSourcePreviewStreamProgressType + r"""Event type, also sent as the SSE `event` name.""" + completed: int + r"""Number of skills inspected so far.""" + total: int + r"""Number of skills to inspect.""" + current_skill: str + r"""Path of the skill being inspected.""" + + +class PlatformSkillSourcePreviewStreamProgress(BaseModel): + r"""One skill finished inspecting; names the skill in progress.""" + + type: PlatformSkillSourcePreviewStreamProgressType + r"""Event type, also sent as the SSE `event` name.""" + + completed: int + r"""Number of skills inspected so far.""" + + total: int + r"""Number of skills to inspect.""" + + current_skill: str + r"""Path of the skill being inspected.""" diff --git a/src/glean/api_client/models/platformskillsourcepreviewstreamprogressserversentevent.py b/src/glean/api_client/models/platformskillsourcepreviewstreamprogressserversentevent.py new file mode 100644 index 00000000..60c2dbed --- /dev/null +++ b/src/glean/api_client/models/platformskillsourcepreviewstreamprogressserversentevent.py @@ -0,0 +1,55 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformskillsourcepreviewstreamprogress import ( + PlatformSkillSourcePreviewStreamProgress, + PlatformSkillSourcePreviewStreamProgressTypedDict, +) +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from glean.api_client.utils import validate_const +import pydantic +from pydantic import model_serializer +from pydantic.functional_validators import AfterValidator +from typing import Literal, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class PlatformSkillSourcePreviewStreamProgressServerSentEventTypedDict(TypedDict): + data: PlatformSkillSourcePreviewStreamProgressTypedDict + r"""One skill finished inspecting; names the skill in progress.""" + id: NotRequired[str] + event: Literal["PROGRESS"] + + +class PlatformSkillSourcePreviewStreamProgressServerSentEvent(BaseModel): + data: PlatformSkillSourcePreviewStreamProgress + r"""One skill finished inspecting; names the skill in progress.""" + + id: Optional[str] = None + + EVENT: Annotated[ + Annotated[Literal["PROGRESS"], AfterValidator(validate_const("PROGRESS"))], + pydantic.Field(alias="event"), + ] = "PROGRESS" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["id"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m + + +try: + PlatformSkillSourcePreviewStreamProgressServerSentEvent.model_rebuild() +except NameError: + pass diff --git a/src/glean/api_client/models/platformskillsourcepreviewstreamresult.py b/src/glean/api_client/models/platformskillsourcepreviewstreamresult.py new file mode 100644 index 00000000..df6d3b6e --- /dev/null +++ b/src/glean/api_client/models/platformskillsourcepreviewstreamresult.py @@ -0,0 +1,33 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformskillsourcepreviewresponse import ( + PlatformSkillSourcePreviewResponse, + PlatformSkillSourcePreviewResponseTypedDict, +) +from enum import Enum +from glean.api_client.types import BaseModel +from typing_extensions import TypedDict + + +class PlatformSkillSourcePreviewStreamResultType(str, Enum): + r"""Event type, also sent as the SSE `event` name.""" + + RESULT = "RESULT" + + +class PlatformSkillSourcePreviewStreamResultTypedDict(TypedDict): + r"""Terminal success event carrying the fully assembled preview.""" + + type: PlatformSkillSourcePreviewStreamResultType + r"""Event type, also sent as the SSE `event` name.""" + response: PlatformSkillSourcePreviewResponseTypedDict + + +class PlatformSkillSourcePreviewStreamResult(BaseModel): + r"""Terminal success event carrying the fully assembled preview.""" + + type: PlatformSkillSourcePreviewStreamResultType + r"""Event type, also sent as the SSE `event` name.""" + + response: PlatformSkillSourcePreviewResponse diff --git a/src/glean/api_client/models/platformskillsourcepreviewstreamresultserversentevent.py b/src/glean/api_client/models/platformskillsourcepreviewstreamresultserversentevent.py new file mode 100644 index 00000000..0741143e --- /dev/null +++ b/src/glean/api_client/models/platformskillsourcepreviewstreamresultserversentevent.py @@ -0,0 +1,55 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformskillsourcepreviewstreamresult import ( + PlatformSkillSourcePreviewStreamResult, + PlatformSkillSourcePreviewStreamResultTypedDict, +) +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from glean.api_client.utils import validate_const +import pydantic +from pydantic import model_serializer +from pydantic.functional_validators import AfterValidator +from typing import Literal, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class PlatformSkillSourcePreviewStreamResultServerSentEventTypedDict(TypedDict): + data: PlatformSkillSourcePreviewStreamResultTypedDict + r"""Terminal success event carrying the fully assembled preview.""" + id: NotRequired[str] + event: Literal["RESULT"] + + +class PlatformSkillSourcePreviewStreamResultServerSentEvent(BaseModel): + data: PlatformSkillSourcePreviewStreamResult + r"""Terminal success event carrying the fully assembled preview.""" + + id: Optional[str] = None + + EVENT: Annotated[ + Annotated[Literal["RESULT"], AfterValidator(validate_const("RESULT"))], + pydantic.Field(alias="event"), + ] = "RESULT" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["id"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m + + +try: + PlatformSkillSourcePreviewStreamResultServerSentEvent.model_rebuild() +except NameError: + pass diff --git a/src/glean/api_client/models/platformskillsourcepreviewstreamscan.py b/src/glean/api_client/models/platformskillsourcepreviewstreamscan.py new file mode 100644 index 00000000..a8fd4229 --- /dev/null +++ b/src/glean/api_client/models/platformskillsourcepreviewstreamscan.py @@ -0,0 +1,37 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from enum import Enum +from glean.api_client.types import BaseModel +from typing import List +from typing_extensions import TypedDict + + +class PlatformSkillSourcePreviewStreamScanType(str, Enum): + r"""Event type, also sent as the SSE `event` name.""" + + SCAN = "SCAN" + + +class PlatformSkillSourcePreviewStreamScanTypedDict(TypedDict): + r"""Repository scan started; names every skill path found.""" + + type: PlatformSkillSourcePreviewStreamScanType + r"""Event type, also sent as the SSE `event` name.""" + total: int + r"""Number of skill paths found in the scan.""" + skill_paths: List[str] + r"""Skill paths found in the scan.""" + + +class PlatformSkillSourcePreviewStreamScan(BaseModel): + r"""Repository scan started; names every skill path found.""" + + type: PlatformSkillSourcePreviewStreamScanType + r"""Event type, also sent as the SSE `event` name.""" + + total: int + r"""Number of skill paths found in the scan.""" + + skill_paths: List[str] + r"""Skill paths found in the scan.""" diff --git a/src/glean/api_client/models/platformskillsourcepreviewstreamscanserversentevent.py b/src/glean/api_client/models/platformskillsourcepreviewstreamscanserversentevent.py new file mode 100644 index 00000000..aa588667 --- /dev/null +++ b/src/glean/api_client/models/platformskillsourcepreviewstreamscanserversentevent.py @@ -0,0 +1,55 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformskillsourcepreviewstreamscan import ( + PlatformSkillSourcePreviewStreamScan, + PlatformSkillSourcePreviewStreamScanTypedDict, +) +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from glean.api_client.utils import validate_const +import pydantic +from pydantic import model_serializer +from pydantic.functional_validators import AfterValidator +from typing import Literal, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class PlatformSkillSourcePreviewStreamScanServerSentEventTypedDict(TypedDict): + data: PlatformSkillSourcePreviewStreamScanTypedDict + r"""Repository scan started; names every skill path found.""" + id: NotRequired[str] + event: Literal["SCAN"] + + +class PlatformSkillSourcePreviewStreamScanServerSentEvent(BaseModel): + data: PlatformSkillSourcePreviewStreamScan + r"""Repository scan started; names every skill path found.""" + + id: Optional[str] = None + + EVENT: Annotated[ + Annotated[Literal["SCAN"], AfterValidator(validate_const("SCAN"))], + pydantic.Field(alias="event"), + ] = "SCAN" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["id"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m + + +try: + PlatformSkillSourcePreviewStreamScanServerSentEvent.model_rebuild() +except NameError: + pass diff --git a/src/glean/api_client/models/platformskillsourcepreviewstreamskill.py b/src/glean/api_client/models/platformskillsourcepreviewstreamskill.py new file mode 100644 index 00000000..937205e3 --- /dev/null +++ b/src/glean/api_client/models/platformskillsourcepreviewstreamskill.py @@ -0,0 +1,33 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformskillsourcepreview import ( + PlatformSkillSourcePreview, + PlatformSkillSourcePreviewTypedDict, +) +from enum import Enum +from glean.api_client.types import BaseModel +from typing_extensions import TypedDict + + +class PlatformSkillSourcePreviewStreamSkillType(str, Enum): + r"""Event type, also sent as the SSE `event` name.""" + + SKILL = "SKILL" + + +class PlatformSkillSourcePreviewStreamSkillTypedDict(TypedDict): + r"""One skill previewed; carries the previewed skill.""" + + type: PlatformSkillSourcePreviewStreamSkillType + r"""Event type, also sent as the SSE `event` name.""" + skill: PlatformSkillSourcePreviewTypedDict + + +class PlatformSkillSourcePreviewStreamSkill(BaseModel): + r"""One skill previewed; carries the previewed skill.""" + + type: PlatformSkillSourcePreviewStreamSkillType + r"""Event type, also sent as the SSE `event` name.""" + + skill: PlatformSkillSourcePreview diff --git a/src/glean/api_client/models/platformskillsourcepreviewstreamskillserversentevent.py b/src/glean/api_client/models/platformskillsourcepreviewstreamskillserversentevent.py new file mode 100644 index 00000000..6197d06d --- /dev/null +++ b/src/glean/api_client/models/platformskillsourcepreviewstreamskillserversentevent.py @@ -0,0 +1,55 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformskillsourcepreviewstreamskill import ( + PlatformSkillSourcePreviewStreamSkill, + PlatformSkillSourcePreviewStreamSkillTypedDict, +) +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from glean.api_client.utils import validate_const +import pydantic +from pydantic import model_serializer +from pydantic.functional_validators import AfterValidator +from typing import Literal, Optional +from typing_extensions import Annotated, NotRequired, TypedDict + + +class PlatformSkillSourcePreviewStreamSkillServerSentEventTypedDict(TypedDict): + data: PlatformSkillSourcePreviewStreamSkillTypedDict + r"""One skill previewed; carries the previewed skill.""" + id: NotRequired[str] + event: Literal["SKILL"] + + +class PlatformSkillSourcePreviewStreamSkillServerSentEvent(BaseModel): + data: PlatformSkillSourcePreviewStreamSkill + r"""One skill previewed; carries the previewed skill.""" + + id: Optional[str] = None + + EVENT: Annotated[ + Annotated[Literal["SKILL"], AfterValidator(validate_const("SKILL"))], + pydantic.Field(alias="event"), + ] = "SKILL" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["id"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m + + +try: + PlatformSkillSourcePreviewStreamSkillServerSentEvent.model_rebuild() +except NameError: + pass diff --git a/src/glean/api_client/models/platformskillstatus.py b/src/glean/api_client/models/platformskillstatus.py index d57185fb..d7058723 100644 --- a/src/glean/api_client/models/platformskillstatus.py +++ b/src/glean/api_client/models/platformskillstatus.py @@ -6,7 +6,7 @@ class PlatformSkillStatus(str, Enum, metaclass=utils.OpenEnumMeta): - r"""Current skill status.""" + r"""The caller's effective activation. The owner sees the skill's stored status. Another caller sees their personal setting, or DISABLED when they have none. DRAFT is the stored draft state and is not set by update. Effective activation may also reflect workspace governance policy.""" DRAFT = "DRAFT" ENABLED = "ENABLED" diff --git a/src/glean/api_client/models/platformskillsyncresponse.py b/src/glean/api_client/models/platformskillsyncresponse.py index 731c531d..8fe7526e 100644 --- a/src/glean/api_client/models/platformskillsyncresponse.py +++ b/src/glean/api_client/models/platformskillsyncresponse.py @@ -1,30 +1,24 @@ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" from __future__ import annotations -from .platformskillsyncresultstatus import PlatformSkillSyncResultStatus from glean.api_client.types import BaseModel from typing_extensions import TypedDict class PlatformSkillSyncResponseTypedDict(TypedDict): - sync_status: PlatformSkillSyncResultStatus - r"""Synchronization status after a successful refresh.""" commit_sha: str r"""Git commit SHA now associated with the skill.""" - updated: bool + is_updated: bool r"""Whether this request created a new skill version.""" request_id: str r"""Platform-generated request ID for support correlation.""" class PlatformSkillSyncResponse(BaseModel): - sync_status: PlatformSkillSyncResultStatus - r"""Synchronization status after a successful refresh.""" - commit_sha: str r"""Git commit SHA now associated with the skill.""" - updated: bool + is_updated: bool r"""Whether this request created a new skill version.""" request_id: str diff --git a/src/glean/api_client/models/platformskillsyncresultstatus.py b/src/glean/api_client/models/platformskillsyncresultstatus.py deleted file mode 100644 index b85415a1..00000000 --- a/src/glean/api_client/models/platformskillsyncresultstatus.py +++ /dev/null @@ -1,10 +0,0 @@ -"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" - -from __future__ import annotations -from enum import Enum - - -class PlatformSkillSyncResultStatus(str, Enum): - r"""Synchronization status after a successful refresh.""" - - UP_TO_DATE = "UP_TO_DATE" diff --git a/src/glean/api_client/models/platformskillupdaterequest.py b/src/glean/api_client/models/platformskillupdaterequest.py index 0d87a591..77732fcd 100644 --- a/src/glean/api_client/models/platformskillupdaterequest.py +++ b/src/glean/api_client/models/platformskillupdaterequest.py @@ -8,9 +8,13 @@ class PlatformSkillUpdateRequestTypedDict(TypedDict): status: PlatformSkillUpdateStatus - r"""New status for the skill.""" + r"""Activation to apply for the authenticated caller. For the owner, this updates the skill's stored status. For any other caller, it updates only that caller's setting. + + """ class PlatformSkillUpdateRequest(BaseModel): status: PlatformSkillUpdateStatus - r"""New status for the skill.""" + r"""Activation to apply for the authenticated caller. For the owner, this updates the skill's stored status. For any other caller, it updates only that caller's setting. + + """ diff --git a/src/glean/api_client/models/platformskillupdatestatus.py b/src/glean/api_client/models/platformskillupdatestatus.py index ede7b308..50cf71de 100644 --- a/src/glean/api_client/models/platformskillupdatestatus.py +++ b/src/glean/api_client/models/platformskillupdatestatus.py @@ -5,7 +5,7 @@ class PlatformSkillUpdateStatus(str, Enum): - r"""New status for the skill.""" + r"""Activation to apply for the authenticated caller. For the owner, this updates the skill's stored status. For any other caller, it updates only that caller's setting.""" ENABLED = "ENABLED" DISABLED = "DISABLED" diff --git a/src/glean/api_client/models/platformskillversionslistresponse.py b/src/glean/api_client/models/platformskillversionslistresponse.py index 2ae04090..37b4b1c8 100644 --- a/src/glean/api_client/models/platformskillversionslistresponse.py +++ b/src/glean/api_client/models/platformskillversionslistresponse.py @@ -9,7 +9,7 @@ class PlatformSkillVersionsListResponseTypedDict(TypedDict): - versions: List[PlatformSkillVersionTypedDict] + results: List[PlatformSkillVersionTypedDict] r"""Versions available for the skill.""" has_more: bool r"""Whether additional results are available.""" @@ -20,7 +20,7 @@ class PlatformSkillVersionsListResponseTypedDict(TypedDict): class PlatformSkillVersionsListResponse(BaseModel): - versions: List[PlatformSkillVersion] + results: List[PlatformSkillVersion] r"""Versions available for the skill.""" has_more: bool diff --git a/src/glean/api_client/models/platformusagesettingsresource.py b/src/glean/api_client/models/platformusagesettingsresource.py new file mode 100644 index 00000000..668619d0 --- /dev/null +++ b/src/glean/api_client/models/platformusagesettingsresource.py @@ -0,0 +1,70 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformlimitincreaserequestsettings import ( + PlatformLimitIncreaseRequestSettings, + PlatformLimitIncreaseRequestSettingsTypedDict, +) +from .platformmultiplemembershipresolutionsettings import ( + PlatformMultipleMembershipResolutionSettings, + PlatformMultipleMembershipResolutionSettingsTypedDict, +) +from datetime import datetime +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from pydantic import model_serializer +from typing import Optional +from typing_extensions import NotRequired, TypedDict + + +class PlatformUsageSettingsResourceTypedDict(TypedDict): + r"""Workspace-wide usage settings.""" + + multiple_membership_resolution: NotRequired[ + PlatformMultipleMembershipResolutionSettingsTypedDict + ] + r"""Settings for resolving limits across multiple memberships.""" + limit_increase_requests: NotRequired[PlatformLimitIncreaseRequestSettingsTypedDict] + r"""Settings that govern usage limit increase requests. + + """ + updated_at: NotRequired[datetime] + r"""ISO 8601 timestamp of the last settings update. + + """ + + +class PlatformUsageSettingsResource(BaseModel): + r"""Workspace-wide usage settings.""" + + multiple_membership_resolution: Optional[ + PlatformMultipleMembershipResolutionSettings + ] = None + r"""Settings for resolving limits across multiple memberships.""" + + limit_increase_requests: Optional[PlatformLimitIncreaseRequestSettings] = None + r"""Settings that govern usage limit increase requests. + + """ + + updated_at: Optional[datetime] = None + r"""ISO 8601 timestamp of the last settings update. + + """ + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set( + ["multiple_membership_resolution", "limit_increase_requests", "updated_at"] + ) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m diff --git a/src/glean/api_client/models/platformusagesettingsresponse.py b/src/glean/api_client/models/platformusagesettingsresponse.py new file mode 100644 index 00000000..6e997915 --- /dev/null +++ b/src/glean/api_client/models/platformusagesettingsresponse.py @@ -0,0 +1,36 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformusagesettingsresource import ( + PlatformUsageSettingsResource, + PlatformUsageSettingsResourceTypedDict, +) +from glean.api_client.types import BaseModel +from typing_extensions import TypedDict + + +class PlatformUsageSettingsResponseTypedDict(TypedDict): + r"""Response envelope for usage settings operations.""" + + usage_settings: PlatformUsageSettingsResourceTypedDict + r"""Workspace-wide usage settings. + + """ + request_id: str + r"""Opaque request identifier. + + """ + + +class PlatformUsageSettingsResponse(BaseModel): + r"""Response envelope for usage settings operations.""" + + usage_settings: PlatformUsageSettingsResource + r"""Workspace-wide usage settings. + + """ + + request_id: str + r"""Opaque request identifier. + + """ diff --git a/src/glean/api_client/models/platformusagesettingsupdaterequest_union.py b/src/glean/api_client/models/platformusagesettingsupdaterequest_union.py new file mode 100644 index 00000000..229beb91 --- /dev/null +++ b/src/glean/api_client/models/platformusagesettingsupdaterequest_union.py @@ -0,0 +1,112 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from __future__ import annotations +from .platformlimitincreaserequestsettings import ( + PlatformLimitIncreaseRequestSettings, + PlatformLimitIncreaseRequestSettingsTypedDict, +) +from .platformmultiplemembershipresolutionsettings import ( + PlatformMultipleMembershipResolutionSettings, + PlatformMultipleMembershipResolutionSettingsTypedDict, +) +from glean.api_client.types import BaseModel, UNSET_SENTINEL +from pydantic import model_serializer +from typing import Optional, Union +from typing_extensions import NotRequired, TypeAliasType, TypedDict + + +class PlatformUsageSettingsUpdateRequest2TypedDict(TypedDict): + limit_increase_requests: PlatformLimitIncreaseRequestSettingsTypedDict + r"""Settings that govern usage limit increase requests. + + """ + multiple_membership_resolution: NotRequired[ + PlatformMultipleMembershipResolutionSettingsTypedDict + ] + r"""Settings for resolving limits across multiple memberships.""" + + +class PlatformUsageSettingsUpdateRequest2(BaseModel): + limit_increase_requests: PlatformLimitIncreaseRequestSettings + r"""Settings that govern usage limit increase requests. + + """ + + multiple_membership_resolution: Optional[ + PlatformMultipleMembershipResolutionSettings + ] = None + r"""Settings for resolving limits across multiple memberships.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["multiple_membership_resolution"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m + + +class PlatformUsageSettingsUpdateRequest1TypedDict(TypedDict): + multiple_membership_resolution: ( + PlatformMultipleMembershipResolutionSettingsTypedDict + ) + r"""Settings for resolving limits across multiple memberships.""" + limit_increase_requests: NotRequired[PlatformLimitIncreaseRequestSettingsTypedDict] + r"""Settings that govern usage limit increase requests. + + """ + + +class PlatformUsageSettingsUpdateRequest1(BaseModel): + multiple_membership_resolution: PlatformMultipleMembershipResolutionSettings + r"""Settings for resolving limits across multiple memberships.""" + + limit_increase_requests: Optional[PlatformLimitIncreaseRequestSettings] = None + r"""Settings that govern usage limit increase requests. + + """ + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["limit_increase_requests"]) + serialized = handler(self) + m = {} + + for n, f in type(self).model_fields.items(): + k = f.alias or n + val = serialized.get(k, serialized.get(n)) + + if val != UNSET_SENTINEL: + if val is not None or k not in optional_fields: + m[k] = val + + return m + + +PlatformUsageSettingsUpdateRequestUnionTypedDict = TypeAliasType( + "PlatformUsageSettingsUpdateRequestUnionTypedDict", + Union[ + PlatformUsageSettingsUpdateRequest1TypedDict, + PlatformUsageSettingsUpdateRequest2TypedDict, + ], +) +r"""Request body for updating workspace-wide usage settings. + +""" + + +PlatformUsageSettingsUpdateRequestUnion = TypeAliasType( + "PlatformUsageSettingsUpdateRequestUnion", + Union[PlatformUsageSettingsUpdateRequest1, PlatformUsageSettingsUpdateRequest2], +) +r"""Request body for updating workspace-wide usage settings. + +""" diff --git a/src/glean/api_client/models/ugctype.py b/src/glean/api_client/models/ugctype.py index a628cc8f..01c9179a 100644 --- a/src/glean/api_client/models/ugctype.py +++ b/src/glean/api_client/models/ugctype.py @@ -26,4 +26,5 @@ class UgcType(str, Enum, metaclass=utils.OpenEnumMeta): SPREADSHEET_TYPE = "SPREADSHEET_TYPE" INLINE_HTML_TYPE = "INLINE_HTML_TYPE" PODCAST_TYPE = "PODCAST_TYPE" + VIDEO_TYPE = "VIDEO_TYPE" WORKFLOWS_TYPE = "WORKFLOWS_TYPE" diff --git a/src/glean/api_client/sdk.py b/src/glean/api_client/sdk.py index 4efe2dd7..ade34d5f 100644 --- a/src/glean/api_client/sdk.py +++ b/src/glean/api_client/sdk.py @@ -15,6 +15,7 @@ import weakref if TYPE_CHECKING: + from glean.api_client.admin import Admin from glean.api_client.agents import Agents from glean.api_client.chat_sdk import ChatSDK from glean.api_client.client import Client @@ -22,6 +23,7 @@ from glean.api_client.search import Search from glean.api_client.skills import Skills from glean.api_client.triggers import Triggers + from glean.api_client.usage import Usage class Glean(BaseSDK): @@ -48,6 +50,8 @@ class Glean(BaseSDK): chat: "ChatSDK" skills: "Skills" search: "Search" + admin: "Admin" + usage: "Usage" triggers: "Triggers" client: "Client" indexing: "Indexing" @@ -56,6 +60,8 @@ class Glean(BaseSDK): "chat": ("glean.api_client.chat_sdk", "ChatSDK"), "skills": ("glean.api_client.skills", "Skills"), "search": ("glean.api_client.search", "Search"), + "admin": ("glean.api_client.admin", "Admin"), + "usage": ("glean.api_client.usage", "Usage"), "triggers": ("glean.api_client.triggers", "Triggers"), "client": ("glean.api_client.client", "Client"), "indexing": ("glean.api_client.indexing", "Indexing"), diff --git a/src/glean/api_client/search.py b/src/glean/api_client/search.py index 0c1935e0..7150efbf 100644 --- a/src/glean/api_client/search.py +++ b/src/glean/api_client/search.py @@ -115,6 +115,10 @@ def query( tags=["Search"], extensions={ "x-codegen-request-body-name": "payload", + "x-glean-scopes": { + "legacy": ["SEARCH"], + "platform": ["search:query"], + }, "x-visibility": "Public", }, ), @@ -254,6 +258,10 @@ async def query_async( tags=["Search"], extensions={ "x-codegen-request-body-name": "payload", + "x-glean-scopes": { + "legacy": ["SEARCH"], + "platform": ["search:query"], + }, "x-visibility": "Public", }, ), @@ -363,7 +371,13 @@ def list_filters( self.sdk_configuration.security, models.Security ), tags=["Search"], - extensions={"x-visibility": "Public"}, + extensions={ + "x-glean-scopes": { + "legacy": ["SEARCH"], + "platform": ["search:query"], + }, + "x-visibility": "Public", + }, ), request=req, is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), @@ -476,7 +490,13 @@ async def list_filters_async( self.sdk_configuration.security, models.Security ), tags=["Search"], - extensions={"x-visibility": "Public"}, + extensions={ + "x-glean-scopes": { + "legacy": ["SEARCH"], + "platform": ["search:query"], + }, + "x-visibility": "Public", + }, ), request=req, is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), diff --git a/src/glean/api_client/skills.py b/src/glean/api_client/skills.py index 89e97e10..4a80b997 100644 --- a/src/glean/api_client/skills.py +++ b/src/glean/api_client/skills.py @@ -1,20 +1,14 @@ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" from .basesdk import BaseSDK -from enum import Enum from glean.api_client import errors, models, utils from glean.api_client._hooks import HookContext from glean.api_client.types import OptionalNullable, UNSET -from glean.api_client.utils import get_security_from_env +from glean.api_client.utils import eventstreaming, get_security_from_env from glean.api_client.utils.unmarshal_json_response import unmarshal_json_response from typing import Any, Iterable, List, Mapping, Optional, Union -class PreviewSourceAcceptEnum(str, Enum): - APPLICATION_JSON = "application/json" - TEXT_EVENT_STREAM = "text/event-stream" - - class Skills(BaseSDK): def create( self, @@ -30,7 +24,7 @@ def create( ) -> models.PlatformSkillCreateResponse: r"""Create skill - Create a skill from an uploaded SKILL.md, .zip, or .skill bundle. If the authenticated user already has a skill with the same name, the existing skill is superseded with a new version. + Create a skill from an uploaded SKILL.md, .zip, or .skill bundle. If the authenticated user already has a skill with the same name, the existing skill is superseded with a new version, unless it is source-managed: a same-name create over a GitHub-imported skill returns 409, and the caller syncs the existing skill instead. Two concurrent same-name creates can still produce two skills. :param file: SKILL.md, .zip, or .skill bundle to create. @@ -92,9 +86,9 @@ def create( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "3cd55572-0d5c-4898-9ecf-1b86c520d1c7", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -105,11 +99,11 @@ def create( ) response_data: Any = None - if utils.match_response(http_res, "200", "application/json"): + if utils.match_response(http_res, "201", "application/json"): return unmarshal_json_response(models.PlatformSkillCreateResponse, http_res) if utils.match_response( http_res, - ["400", "401", "403", "404", "408", "413", "429"], + ["400", "401", "403", "404", "408", "409", "413", "429"], "application/problem+json", ): response_data = unmarshal_json_response( @@ -144,7 +138,7 @@ async def create_async( ) -> models.PlatformSkillCreateResponse: r"""Create skill - Create a skill from an uploaded SKILL.md, .zip, or .skill bundle. If the authenticated user already has a skill with the same name, the existing skill is superseded with a new version. + Create a skill from an uploaded SKILL.md, .zip, or .skill bundle. If the authenticated user already has a skill with the same name, the existing skill is superseded with a new version, unless it is source-managed: a same-name create over a GitHub-imported skill returns 409, and the caller syncs the existing skill instead. Two concurrent same-name creates can still produce two skills. :param file: SKILL.md, .zip, or .skill bundle to create. @@ -206,9 +200,9 @@ async def create_async( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "3cd55572-0d5c-4898-9ecf-1b86c520d1c7", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -219,11 +213,11 @@ async def create_async( ) response_data: Any = None - if utils.match_response(http_res, "200", "application/json"): + if utils.match_response(http_res, "201", "application/json"): return unmarshal_json_response(models.PlatformSkillCreateResponse, http_res) if utils.match_response( http_res, - ["400", "401", "403", "404", "408", "413", "429"], + ["400", "401", "403", "404", "408", "409", "413", "429"], "application/problem+json", ): response_data = unmarshal_json_response( @@ -247,7 +241,7 @@ async def create_async( def list( self, *, - page_size: Optional[int] = None, + page_size: Optional[int] = 20, cursor: Optional[str] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, @@ -256,10 +250,10 @@ def list( ) -> models.PlatformSkillsListResponse: r"""List skills - List skills available to the authenticated user. + List every custom skill the authenticated caller can access. Built-in skills are excluded: they have no versions, content download, update, or delete, so their identifiers would fail most skill operations. Chat-authored skills shared with the caller without a listed grant are omitted: they stay retrievable by identifier when it is known, but this list does not discover them. - :param page_size: Maximum number of skills to return. + :param page_size: Maximum number of skills to return. Defaults to 20. Maximum is 100. :param cursor: Opaque pagination cursor from a previous response. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method @@ -317,9 +311,9 @@ def list( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "3eb65937-03a3-472b-9a00-be713f302b5f", - "introduced": "2026-06-23", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:read"], }, "x-visibility": "Public", }, @@ -358,7 +352,7 @@ def list( async def list_async( self, *, - page_size: Optional[int] = None, + page_size: Optional[int] = 20, cursor: Optional[str] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, @@ -367,10 +361,10 @@ async def list_async( ) -> models.PlatformSkillsListResponse: r"""List skills - List skills available to the authenticated user. + List every custom skill the authenticated caller can access. Built-in skills are excluded: they have no versions, content download, update, or delete, so their identifiers would fail most skill operations. Chat-authored skills shared with the caller without a listed grant are omitted: they stay retrievable by identifier when it is known, but this list does not discover them. - :param page_size: Maximum number of skills to return. + :param page_size: Maximum number of skills to return. Defaults to 20. Maximum is 100. :param cursor: Opaque pagination cursor from a previous response. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method @@ -428,9 +422,9 @@ async def list_async( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "3eb65937-03a3-472b-9a00-be713f302b5f", - "introduced": "2026-06-23", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:read"], }, "x-visibility": "Public", }, @@ -540,9 +534,9 @@ def import_( tags=["Skills"], extensions={ "x-codegen-request-body-name": "request", - "x-glean-experimental": { - "id": "9162d790-e101-437d-a9a0-25e4687d150b", - "introduced": "2026-07-28", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -553,8 +547,15 @@ def import_( ) response_data: Any = None - if utils.match_response(http_res, "200", "application/json"): + if utils.match_response(http_res, "201", "application/json"): return unmarshal_json_response(models.PlatformSkillImportResponse, http_res) + if utils.match_response(http_res, "422", "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformUnauthorizedAgentToolsProblemErrorData, http_res + ) + raise errors.PlatformUnauthorizedAgentToolsProblemError( + response_data, http_res + ) if utils.match_response( http_res, ["400", "401", "403", "408", "409", "413", "429"], @@ -652,9 +653,9 @@ async def import__async( tags=["Skills"], extensions={ "x-codegen-request-body-name": "request", - "x-glean-experimental": { - "id": "9162d790-e101-437d-a9a0-25e4687d150b", - "introduced": "2026-07-28", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -665,8 +666,15 @@ async def import__async( ) response_data: Any = None - if utils.match_response(http_res, "200", "application/json"): + if utils.match_response(http_res, "201", "application/json"): return unmarshal_json_response(models.PlatformSkillImportResponse, http_res) + if utils.match_response(http_res, "422", "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformUnauthorizedAgentToolsProblemErrorData, http_res + ) + raise errors.PlatformUnauthorizedAgentToolsProblemError( + response_data, http_res + ) if utils.match_response( http_res, ["400", "401", "403", "408", "409", "413", "429"], @@ -772,9 +780,9 @@ def validate( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "0b086fa6-30f8-4279-8d11-10ab0059c14a", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -894,9 +902,9 @@ async def validate_async( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "0b086fa6-30f8-4279-8d11-10ab0059c14a", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -938,24 +946,20 @@ def preview_source( self, *, source_url: str, - stream: Optional[bool] = False, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, - accept_header_override: Optional[PreviewSourceAcceptEnum] = None, timeout_ms: Optional[int] = None, http_headers: Optional[Mapping[str, str]] = None, - ) -> models.PlatformSkillsPreviewSourceResponse: + ) -> models.PlatformSkillSourcePreviewResponse: r"""Preview a GitHub skill source Inspect a GitHub URL without persisting a source or any discovered skills. Set stream to true to receive repository scan progress as server-sent events; otherwise the response contains the completed preview. :param source_url: GitHub URL for a skill directory, SKILL.md file, or repository to inspect. - :param stream: Whether to stream repository scan progress using server-sent events. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds - :param accept_header_override: Override the default accept header for this method :param http_headers: Additional headers to set or replace on requests. """ base_url = None @@ -968,9 +972,8 @@ def preview_source( else: base_url = self._get_url(base_url, url_variables) - request = models.PlatformSkillSourcePreviewRequest( + request = models.PlatformSkillsPreviewSourceRequest( source_url=source_url, - stream=stream, ) req = self._build_request( @@ -983,13 +986,11 @@ def preview_source( request_has_path_params=False, request_has_query_params=True, user_agent_header="user-agent", - accept_header_value=accept_header_override.value - if accept_header_override is not None - else "application/json;q=1, text/event-stream;q=0", + accept_header_value="application/json", http_headers=http_headers, security=self.sdk_configuration.security, get_serialized_body=lambda: utils.serialize_request_body( - request, False, False, "json", models.PlatformSkillSourcePreviewRequest + request, False, False, "json", models.PlatformSkillsPreviewSourceRequest ), allow_empty_value=None, timeout_ms=timeout_ms, @@ -1015,9 +1016,9 @@ def preview_source( tags=["Skills"], extensions={ "x-codegen-request-body-name": "request", - "x-glean-experimental": { - "id": "1629009b-244a-400a-bf55-c441dfbc586c", - "introduced": "2026-07-23", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -1032,8 +1033,13 @@ def preview_source( return unmarshal_json_response( models.PlatformSkillSourcePreviewResponse, http_res ) - if utils.match_response(http_res, "200", "text/event-stream"): - return http_res.text + if utils.match_response(http_res, "422", "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformUnauthorizedAgentToolsProblemErrorData, http_res + ) + raise errors.PlatformUnauthorizedAgentToolsProblemError( + response_data, http_res + ) if utils.match_response( http_res, ["400", "401", "403", "408", "413", "429"], @@ -1061,24 +1067,20 @@ async def preview_source_async( self, *, source_url: str, - stream: Optional[bool] = False, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, - accept_header_override: Optional[PreviewSourceAcceptEnum] = None, timeout_ms: Optional[int] = None, http_headers: Optional[Mapping[str, str]] = None, - ) -> models.PlatformSkillsPreviewSourceResponse: + ) -> models.PlatformSkillSourcePreviewResponse: r"""Preview a GitHub skill source Inspect a GitHub URL without persisting a source or any discovered skills. Set stream to true to receive repository scan progress as server-sent events; otherwise the response contains the completed preview. :param source_url: GitHub URL for a skill directory, SKILL.md file, or repository to inspect. - :param stream: Whether to stream repository scan progress using server-sent events. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds - :param accept_header_override: Override the default accept header for this method :param http_headers: Additional headers to set or replace on requests. """ base_url = None @@ -1091,9 +1093,8 @@ async def preview_source_async( else: base_url = self._get_url(base_url, url_variables) - request = models.PlatformSkillSourcePreviewRequest( + request = models.PlatformSkillsPreviewSourceRequest( source_url=source_url, - stream=stream, ) req = self._build_request_async( @@ -1106,13 +1107,11 @@ async def preview_source_async( request_has_path_params=False, request_has_query_params=True, user_agent_header="user-agent", - accept_header_value=accept_header_override.value - if accept_header_override is not None - else "application/json;q=1, text/event-stream;q=0", + accept_header_value="application/json", http_headers=http_headers, security=self.sdk_configuration.security, get_serialized_body=lambda: utils.serialize_request_body( - request, False, False, "json", models.PlatformSkillSourcePreviewRequest + request, False, False, "json", models.PlatformSkillsPreviewSourceRequest ), allow_empty_value=None, timeout_ms=timeout_ms, @@ -1138,9 +1137,9 @@ async def preview_source_async( tags=["Skills"], extensions={ "x-codegen-request-body-name": "request", - "x-glean-experimental": { - "id": "1629009b-244a-400a-bf55-c441dfbc586c", - "introduced": "2026-07-23", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -1155,8 +1154,13 @@ async def preview_source_async( return unmarshal_json_response( models.PlatformSkillSourcePreviewResponse, http_res ) - if utils.match_response(http_res, "200", "text/event-stream"): - return http_res.text + if utils.match_response(http_res, "422", "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformUnauthorizedAgentToolsProblemErrorData, http_res + ) + raise errors.PlatformUnauthorizedAgentToolsProblemError( + response_data, http_res + ) if utils.match_response( http_res, ["400", "401", "403", "408", "413", "429"], @@ -1192,11 +1196,12 @@ def update( ) -> models.PlatformSkillUpdateResponse: r"""Update skill - Update mutable metadata for a skill. V1 supports enabling or disabling a skill without changing its content. + Enable or disable the skill for the authenticated caller without changing its content. The owner's update sets the skill's stored status. Any other caller's update applies only to that caller. :param skill_id: Glean skill ID. - :param status: New status for the skill. + :param status: Activation to apply for the authenticated caller. For the owner, this updates the skill's stored status. For any other caller, it updates only that caller's setting. + :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds @@ -1262,9 +1267,9 @@ def update( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "262e1f6b-6c2d-4d6d-943b-fc251d2fb38b", - "introduced": "2026-07-20", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -1312,11 +1317,12 @@ async def update_async( ) -> models.PlatformSkillUpdateResponse: r"""Update skill - Update mutable metadata for a skill. V1 supports enabling or disabling a skill without changing its content. + Enable or disable the skill for the authenticated caller without changing its content. The owner's update sets the skill's stored status. Any other caller's update applies only to that caller. :param skill_id: Glean skill ID. - :param status: New status for the skill. + :param status: Activation to apply for the authenticated caller. For the owner, this updates the skill's stored status. For any other caller, it updates only that caller's setting. + :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method :param timeout_ms: Override the default request timeout configuration for this method in milliseconds @@ -1382,9 +1388,9 @@ async def update_async( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "262e1f6b-6c2d-4d6d-943b-fc251d2fb38b", - "introduced": "2026-07-20", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -1490,9 +1496,9 @@ def delete( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "c4351fd0-4d28-4ad4-ab93-587ca4778173", - "introduced": "2026-07-31", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -1598,9 +1604,9 @@ async def delete_async( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "c4351fd0-4d28-4ad4-ab93-587ca4778173", - "introduced": "2026-07-31", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -1706,9 +1712,9 @@ def retrieve( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "8f8d1c92-a484-4769-9903-200613dc8a72", - "introduced": "2026-06-23", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:read"], }, "x-visibility": "Public", }, @@ -1814,9 +1820,9 @@ async def retrieve_async( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "8f8d1c92-a484-4769-9903-200613dc8a72", - "introduced": "2026-06-23", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:read"], }, "x-visibility": "Public", }, @@ -1922,9 +1928,9 @@ def retrieve_content( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "fd6908d8-f230-4cd5-bf45-f71e69266b1d", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:read"], }, "x-visibility": "Public", }, @@ -2040,9 +2046,9 @@ async def retrieve_content_async( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "fd6908d8-f230-4cd5-bf45-f71e69266b1d", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:read"], }, "x-visibility": "Public", }, @@ -2158,9 +2164,9 @@ def sync( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "568aa3f8-2af8-449c-9e4f-818ed4b877ef", - "introduced": "2026-08-03", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -2173,9 +2179,16 @@ def sync( response_data: Any = None if utils.match_response(http_res, "200", "application/json"): return unmarshal_json_response(models.PlatformSkillSyncResponse, http_res) + if utils.match_response(http_res, "422", "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformUnauthorizedAgentToolsProblemErrorData, http_res + ) + raise errors.PlatformUnauthorizedAgentToolsProblemError( + response_data, http_res + ) if utils.match_response( http_res, - ["400", "401", "403", "404", "408", "409", "413", "429"], + ["400", "401", "403", "404", "408", "409", "429"], "application/problem+json", ): response_data = unmarshal_json_response( @@ -2266,9 +2279,9 @@ async def sync_async( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "568aa3f8-2af8-449c-9e4f-818ed4b877ef", - "introduced": "2026-08-03", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -2281,9 +2294,16 @@ async def sync_async( response_data: Any = None if utils.match_response(http_res, "200", "application/json"): return unmarshal_json_response(models.PlatformSkillSyncResponse, http_res) + if utils.match_response(http_res, "422", "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformUnauthorizedAgentToolsProblemErrorData, http_res + ) + raise errors.PlatformUnauthorizedAgentToolsProblemError( + response_data, http_res + ) if utils.match_response( http_res, - ["400", "401", "403", "404", "408", "409", "413", "429"], + ["400", "401", "403", "404", "408", "409", "429"], "application/problem+json", ): response_data = unmarshal_json_response( @@ -2319,7 +2339,7 @@ def create_version( ) -> models.PlatformSkillVersionCreateResponse: r"""Create skill version - Create a new immutable version for an existing caller-managed skill from an uploaded SKILL.md, .zip, or .skill bundle. + Create a new immutable version for an existing caller-managed skill from an uploaded SKILL.md, .zip, or .skill bundle. A create-version over a GitHub-imported skill returns 409, and the caller syncs the existing skill instead. :param skill_id: Glean skill ID. @@ -2391,9 +2411,9 @@ def create_version( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "0d5e48e2-7a41-4d54-b3aa-5026f0dd65df", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -2404,7 +2424,7 @@ def create_version( ) response_data: Any = None - if utils.match_response(http_res, "200", "application/json"): + if utils.match_response(http_res, "201", "application/json"): return unmarshal_json_response( models.PlatformSkillVersionCreateResponse, http_res ) @@ -2446,7 +2466,7 @@ async def create_version_async( ) -> models.PlatformSkillVersionCreateResponse: r"""Create skill version - Create a new immutable version for an existing caller-managed skill from an uploaded SKILL.md, .zip, or .skill bundle. + Create a new immutable version for an existing caller-managed skill from an uploaded SKILL.md, .zip, or .skill bundle. A create-version over a GitHub-imported skill returns 409, and the caller syncs the existing skill instead. :param skill_id: Glean skill ID. @@ -2518,9 +2538,9 @@ async def create_version_async( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "0d5e48e2-7a41-4d54-b3aa-5026f0dd65df", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], }, "x-visibility": "Public", }, @@ -2531,7 +2551,7 @@ async def create_version_async( ) response_data: Any = None - if utils.match_response(http_res, "200", "application/json"): + if utils.match_response(http_res, "201", "application/json"): return unmarshal_json_response( models.PlatformSkillVersionCreateResponse, http_res ) @@ -2562,7 +2582,7 @@ def list_versions( self, *, skill_id: str, - page_size: Optional[int] = None, + page_size: Optional[int] = 20, cursor: Optional[str] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, @@ -2575,7 +2595,7 @@ def list_versions( :param skill_id: Glean skill ID. - :param page_size: Maximum number of versions to return. + :param page_size: Maximum number of versions to return. Defaults to 20. Maximum is 100. :param cursor: Opaque pagination cursor from a previous response. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method @@ -2634,9 +2654,9 @@ def list_versions( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "9efbb8a3-d546-4304-a653-09bb427e3681", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:read"], }, "x-visibility": "Public", }, @@ -2678,7 +2698,7 @@ async def list_versions_async( self, *, skill_id: str, - page_size: Optional[int] = None, + page_size: Optional[int] = 20, cursor: Optional[str] = None, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, @@ -2691,7 +2711,7 @@ async def list_versions_async( :param skill_id: Glean skill ID. - :param page_size: Maximum number of versions to return. + :param page_size: Maximum number of versions to return. Defaults to 20. Maximum is 100. :param cursor: Opaque pagination cursor from a previous response. :param retries: Override the default retry configuration for this method :param server_url: Override the default server URL for this method @@ -2750,9 +2770,9 @@ async def list_versions_async( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "9efbb8a3-d546-4304-a653-09bb427e3681", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:read"], }, "x-visibility": "Public", }, @@ -2863,9 +2883,9 @@ def retrieve_version( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "d70986b1-ad80-48dd-8e52-f294e7251dda", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:read"], }, "x-visibility": "Public", }, @@ -2976,9 +2996,9 @@ async def retrieve_version_async( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "d70986b1-ad80-48dd-8e52-f294e7251dda", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:read"], }, "x-visibility": "Public", }, @@ -3089,9 +3109,9 @@ def retrieve_version_content( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "70c85692-7042-403a-a3a5-5b315576432a", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:read"], }, "x-visibility": "Public", }, @@ -3210,9 +3230,9 @@ async def retrieve_version_content_async( ), tags=["Skills"], extensions={ - "x-glean-experimental": { - "id": "70c85692-7042-403a-a3a5-5b315576432a", - "introduced": "2026-06-24", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:read"], }, "x-visibility": "Public", }, @@ -3257,3 +3277,291 @@ async def retrieve_version_content_async( http_res_text = await utils.stream_to_text_async(http_res) raise errors.GleanError("Unexpected response received", http_res, http_res_text) + + def preview_source_stream( + self, + *, + source_url: str, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> eventstreaming.EventStream[ + models.PlatformSkillSourcePreviewStreamEventServerSentEvent + ]: + r"""Preview a GitHub skill source as events + + SDK-only logical operation. HTTP clients must call the base path; the URL fragment is not sent. Inspect a GitHub URL as server-sent events. HTTP clients request this mode by setting `stream` to true in the JSON body. + + + :param source_url: GitHub URL for a skill directory, SKILL.md file, or repository to inspect. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformSkillsPreviewSourceStreamRequest( + source_url=source_url, + ) + + req = self._build_request( + method="POST", + path="/api/skills/sources/preview#stream", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="text/event-stream", + http_headers=http_headers, + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request, + False, + False, + "json", + models.PlatformSkillsPreviewSourceStreamRequest, + ), + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-skills-preview-source-stream", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Skills"], + extensions={ + "x-codegen-request-body-name": "request", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + stream=True, + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "text/event-stream"): + return eventstreaming.EventStream( + http_res, + lambda raw: unmarshal_json_response( + models.PlatformSkillSourcePreviewStreamEventServerSentEvent, + http_res, + raw, + ), + client_ref=self, + ) + if utils.match_response(http_res, "422", "application/problem+json"): + http_res_text = utils.stream_to_text(http_res) + response_data = unmarshal_json_response( + errors.PlatformUnauthorizedAgentToolsProblemErrorData, + http_res, + http_res_text, + ) + raise errors.PlatformUnauthorizedAgentToolsProblemError( + response_data, http_res, http_res_text + ) + if utils.match_response( + http_res, + ["400", "401", "403", "408", "413", "429"], + "application/problem+json", + ): + http_res_text = utils.stream_to_text(http_res) + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res, http_res_text + ) + raise errors.PlatformProblemDetailError( + response_data, http_res, http_res_text + ) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + http_res_text = utils.stream_to_text(http_res) + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res, http_res_text + ) + raise errors.PlatformProblemDetailError( + response_data, http_res, http_res_text + ) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("Unexpected response received", http_res, http_res_text) + + async def preview_source_stream_async( + self, + *, + source_url: str, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> eventstreaming.EventStreamAsync[ + models.PlatformSkillSourcePreviewStreamEventServerSentEvent + ]: + r"""Preview a GitHub skill source as events + + SDK-only logical operation. HTTP clients must call the base path; the URL fragment is not sent. Inspect a GitHub URL as server-sent events. HTTP clients request this mode by setting `stream` to true in the JSON body. + + + :param source_url: GitHub URL for a skill directory, SKILL.md file, or repository to inspect. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformSkillsPreviewSourceStreamRequest( + source_url=source_url, + ) + + req = self._build_request_async( + method="POST", + path="/api/skills/sources/preview#stream", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="text/event-stream", + http_headers=http_headers, + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request, + False, + False, + "json", + models.PlatformSkillsPreviewSourceStreamRequest, + ), + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-skills-preview-source-stream", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Skills"], + extensions={ + "x-codegen-request-body-name": "request", + "x-glean-scopes": { + "legacy": ["SKILLS"], + "platform": ["skills:write"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + stream=True, + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "text/event-stream"): + return eventstreaming.EventStreamAsync( + http_res, + lambda raw: unmarshal_json_response( + models.PlatformSkillSourcePreviewStreamEventServerSentEvent, + http_res, + raw, + ), + client_ref=self, + ) + if utils.match_response(http_res, "422", "application/problem+json"): + http_res_text = await utils.stream_to_text_async(http_res) + response_data = unmarshal_json_response( + errors.PlatformUnauthorizedAgentToolsProblemErrorData, + http_res, + http_res_text, + ) + raise errors.PlatformUnauthorizedAgentToolsProblemError( + response_data, http_res, http_res_text + ) + if utils.match_response( + http_res, + ["400", "401", "403", "408", "413", "429"], + "application/problem+json", + ): + http_res_text = await utils.stream_to_text_async(http_res) + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res, http_res_text + ) + raise errors.PlatformProblemDetailError( + response_data, http_res, http_res_text + ) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + http_res_text = await utils.stream_to_text_async(http_res) + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res, http_res_text + ) + raise errors.PlatformProblemDetailError( + response_data, http_res, http_res_text + ) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("Unexpected response received", http_res, http_res_text) diff --git a/src/glean/api_client/triggers.py b/src/glean/api_client/triggers.py index d0546336..3bbd7579 100644 --- a/src/glean/api_client/triggers.py +++ b/src/glean/api_client/triggers.py @@ -99,6 +99,10 @@ def create( "id": "eb175f18-74e6-4c9c-ba02-23bcc9018fc9", "introduced": "2026-07-06", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:write"], + }, "x-visibility": "Public", }, ), @@ -224,6 +228,10 @@ async def create_async( "id": "eb175f18-74e6-4c9c-ba02-23bcc9018fc9", "introduced": "2026-07-06", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:write"], + }, "x-visibility": "Public", }, ), @@ -337,6 +345,10 @@ def list( "id": "e3554987-e043-4561-889a-a1117b1bce06", "introduced": "2026-07-06", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -446,6 +458,10 @@ async def list_async( "id": "e3554987-e043-4561-889a-a1117b1bce06", "introduced": "2026-07-06", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -552,6 +568,10 @@ def get( "id": "46de62cb-ba31-4f71-9646-649c1d604816", "introduced": "2026-07-06", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -660,6 +680,10 @@ async def get_async( "id": "46de62cb-ba31-4f71-9646-649c1d604816", "introduced": "2026-07-06", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -796,6 +820,10 @@ def update( "id": "3eb4c709-bd5c-4019-b913-0db36c766350", "introduced": "2026-07-06", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:write"], + }, "x-visibility": "Public", }, ), @@ -932,6 +960,10 @@ async def update_async( "id": "3eb4c709-bd5c-4019-b913-0db36c766350", "introduced": "2026-07-06", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:write"], + }, "x-visibility": "Public", }, ), @@ -1040,6 +1072,10 @@ def delete( "id": "e6564ed7-8b4b-4708-918b-eed97110859f", "introduced": "2026-07-06", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:write"], + }, "x-visibility": "Public", }, ), @@ -1148,6 +1184,10 @@ async def delete_async( "id": "e6564ed7-8b4b-4708-918b-eed97110859f", "introduced": "2026-07-06", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:write"], + }, "x-visibility": "Public", }, ), @@ -1270,6 +1310,10 @@ def search_events( "id": "c734a377-3dec-4ee2-9ec5-3848a8384f03", "introduced": "2026-08-07", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -1394,6 +1438,10 @@ async def search_events_async( "id": "c734a377-3dec-4ee2-9ec5-3848a8384f03", "introduced": "2026-08-07", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -1510,6 +1558,10 @@ def list_presets( "id": "f5b16196-0d4c-42f0-89bf-40313398728e", "introduced": "2026-07-22", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -1624,6 +1676,10 @@ async def list_presets_async( "id": "f5b16196-0d4c-42f0-89bf-40313398728e", "introduced": "2026-07-22", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -1732,6 +1788,10 @@ def get_preset( "id": "5277167d-909b-4eee-95d1-8958b07016bb", "introduced": "2026-07-22", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -1842,6 +1902,10 @@ async def get_preset_async( "id": "5277167d-909b-4eee-95d1-8958b07016bb", "introduced": "2026-07-22", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -1959,6 +2023,10 @@ def list_preset_input_values( "id": "24c5675d-a57a-48cb-9d71-3dece296f28c", "introduced": "2026-08-06", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -2076,6 +2144,10 @@ async def list_preset_input_values_async( "id": "24c5675d-a57a-48cb-9d71-3dece296f28c", "introduced": "2026-08-06", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -2204,6 +2276,10 @@ def search_preset_events( "id": "a48efd80-78d6-46de-9f23-5b8c63ecd157", "introduced": "2026-08-12", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), @@ -2332,6 +2408,10 @@ async def search_preset_events_async( "id": "a48efd80-78d6-46de-9f23-5b8c63ecd157", "introduced": "2026-08-12", }, + "x-glean-scopes": { + "legacy": ["TRIGGERS"], + "platform": ["triggers:read"], + }, "x-visibility": "Public", }, ), diff --git a/src/glean/api_client/usage.py b/src/glean/api_client/usage.py new file mode 100644 index 00000000..7db5ca18 --- /dev/null +++ b/src/glean/api_client/usage.py @@ -0,0 +1,725 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from .basesdk import BaseSDK +from glean.api_client import errors, models, utils +from glean.api_client._hooks import HookContext +from glean.api_client.types import OptionalNullable, UNSET +from glean.api_client.utils import get_security_from_env +from glean.api_client.utils.unmarshal_json_response import unmarshal_json_response +from typing import Any, Iterable, List, Mapping, Optional, Union + + +class Usage(BaseSDK): + def create_limit_increase_request( + self, + *, + client_id: str, + business_justification: Optional[str] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformRequestResponse: + r"""Submit a personal limit-increase request + + Requires usage.limit_increase_requests:write. The target is the authenticated canonical user, and requester identity comes from authentication. The caller supplies the client and optional business justification. The server assigns the request identifier and current UTC month. Billing grants do not widen this route. This internal scaffold returns 503 without creating a request. + + + :param client_id: Explicit spend client whose limit the request concerns. + :param business_justification: Optional explanation of why the increase is needed. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformPersonalRequestCreate( + client_id=client_id, + business_justification=business_justification, + ) + + req = self._build_request( + method="POST", + path="/api/usage/limit-increase-requests", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request, False, False, "json", models.PlatformPersonalRequestCreate + ), + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-usage-requests-create", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "d9f125f8-85f3-4221-8627-0b39f6d5b4ab", + "introduced": "2026-09-25", + }, + "x-glean-scopes": { + "legacy": ["USAGE_LIMIT_INCREASE_REQUESTS"], + "platform": ["usage.limit_increase_requests:write"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "201", "application/json"): + return unmarshal_json_response(models.PlatformRequestResponse, http_res) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "409", "413", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + async def create_limit_increase_request_async( + self, + *, + client_id: str, + business_justification: Optional[str] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformRequestResponse: + r"""Submit a personal limit-increase request + + Requires usage.limit_increase_requests:write. The target is the authenticated canonical user, and requester identity comes from authentication. The caller supplies the client and optional business justification. The server assigns the request identifier and current UTC month. Billing grants do not widen this route. This internal scaffold returns 503 without creating a request. + + + :param client_id: Explicit spend client whose limit the request concerns. + :param business_justification: Optional explanation of why the increase is needed. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformPersonalRequestCreate( + client_id=client_id, + business_justification=business_justification, + ) + + req = self._build_request_async( + method="POST", + path="/api/usage/limit-increase-requests", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + get_serialized_body=lambda: utils.serialize_request_body( + request, False, False, "json", models.PlatformPersonalRequestCreate + ), + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-usage-requests-create", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "d9f125f8-85f3-4221-8627-0b39f6d5b4ab", + "introduced": "2026-09-25", + }, + "x-glean-scopes": { + "legacy": ["USAGE_LIMIT_INCREASE_REQUESTS"], + "platform": ["usage.limit_increase_requests:write"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "201", "application/json"): + return unmarshal_json_response(models.PlatformRequestResponse, http_res) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "409", "413", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + def list_limit_increase_requests( + self, + *, + page_size: Optional[int] = 20, + cursor: Optional[str] = None, + filters: Optional[ + Union[ + Iterable[models.PlatformRequestFilter], + Iterable[models.PlatformRequestFilterTypedDict], + ] + ] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformRequestListResponseUnion: + r"""List personal limit-increase requests + + Requires usage.limit_increase_requests:read. The collection is limited to the authenticated canonical user's requests, including resolved requests. Cursors bind the filters and current authorization context; a billing grant cannot widen results. This internal scaffold returns 503 without reading requests. + + + :param page_size: Maximum page size; defaults to 20 and cannot exceed 100. + :param cursor: Opaque continuation bound to filters and current authorization. + :param filters: Optional structured filters on request status. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformUsageRequestsListRequest( + page_size=page_size, + cursor=cursor, + filters=utils.get_pydantic_model( + filters, Optional[List[models.PlatformRequestFilter]] + ), + ) + + req = self._build_request( + method="GET", + path="/api/usage/limit-increase-requests", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-usage-requests-list", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "d92d077c-81c0-4d91-868d-021eed013d8d", + "introduced": "2026-09-25", + }, + "x-glean-scopes": { + "legacy": ["USAGE_LIMIT_INCREASE_REQUESTS"], + "platform": ["usage.limit_increase_requests:read"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response( + models.PlatformRequestListResponseUnion, http_res + ) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + async def list_limit_increase_requests_async( + self, + *, + page_size: Optional[int] = 20, + cursor: Optional[str] = None, + filters: Optional[ + Union[ + Iterable[models.PlatformRequestFilter], + Iterable[models.PlatformRequestFilterTypedDict], + ] + ] = None, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformRequestListResponseUnion: + r"""List personal limit-increase requests + + Requires usage.limit_increase_requests:read. The collection is limited to the authenticated canonical user's requests, including resolved requests. Cursors bind the filters and current authorization context; a billing grant cannot widen results. This internal scaffold returns 503 without reading requests. + + + :param page_size: Maximum page size; defaults to 20 and cannot exceed 100. + :param cursor: Opaque continuation bound to filters and current authorization. + :param filters: Optional structured filters on request status. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformUsageRequestsListRequest( + page_size=page_size, + cursor=cursor, + filters=utils.get_pydantic_model( + filters, Optional[List[models.PlatformRequestFilter]] + ), + ) + + req = self._build_request_async( + method="GET", + path="/api/usage/limit-increase-requests", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=False, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-usage-requests-list", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "d92d077c-81c0-4d91-868d-021eed013d8d", + "introduced": "2026-09-25", + }, + "x-glean-scopes": { + "legacy": ["USAGE_LIMIT_INCREASE_REQUESTS"], + "platform": ["usage.limit_increase_requests:read"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response( + models.PlatformRequestListResponseUnion, http_res + ) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + def get_limit_increase_request( + self, + *, + request_id: str, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformRequestResponse: + r"""Get a personal limit-increase request + + Requires usage.limit_increase_requests:read and the current user's request. Authorization precedes resource disclosure. This internal scaffold returns 503 without reading the request. + + + :param request_id: Opaque personal request identifier; not an authorization grant. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformUsageRequestsGetRequest( + request_id=request_id, + ) + + req = self._build_request( + method="GET", + path="/api/usage/limit-increase-requests/{request_id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = self.do_request( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-usage-requests-get", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "29a2f132-a0c2-429f-95e7-7995de058cd3", + "introduced": "2026-09-25", + }, + "x-glean-scopes": { + "legacy": ["USAGE_LIMIT_INCREASE_REQUESTS"], + "platform": ["usage.limit_increase_requests:read"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response(models.PlatformRequestResponse, http_res) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) + + async def get_limit_increase_request_async( + self, + *, + request_id: str, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.PlatformRequestResponse: + r"""Get a personal limit-increase request + + Requires usage.limit_increase_requests:read and the current user's request. Authorization precedes resource disclosure. This internal scaffold returns 503 without reading the request. + + + :param request_id: Opaque personal request identifier; not an authorization grant. + :param retries: Override the default retry configuration for this method + :param server_url: Override the default server URL for this method + :param timeout_ms: Override the default request timeout configuration for this method in milliseconds + :param http_headers: Additional headers to set or replace on requests. + """ + base_url = None + url_variables = None + if timeout_ms is None: + timeout_ms = self.sdk_configuration.timeout_ms + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.PlatformUsageRequestsGetRequest( + request_id=request_id, + ) + + req = self._build_request_async( + method="GET", + path="/api/usage/limit-increase-requests/{request_id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=False, + request_has_path_params=True, + request_has_query_params=True, + user_agent_header="user-agent", + accept_header_value="application/json", + http_headers=http_headers, + security=self.sdk_configuration.security, + allow_empty_value=None, + timeout_ms=timeout_ms, + ) + + if retries == UNSET: + if self.sdk_configuration.retry_config is not UNSET: + retries = self.sdk_configuration.retry_config + + retry_config = None + if isinstance(retries, utils.RetryConfig): + retry_config = (retries, ["429", "500", "502", "503", "504"]) + + http_res = await self.do_request_async( + hook_ctx=HookContext( + config=self.sdk_configuration, + base_url=base_url or "", + operation_id="platform-usage-requests-get", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + tags=["Usage"], + extensions={ + "x-glean-experimental": { + "id": "29a2f132-a0c2-429f-95e7-7995de058cd3", + "introduced": "2026-09-25", + }, + "x-glean-scopes": { + "legacy": ["USAGE_LIMIT_INCREASE_REQUESTS"], + "platform": ["usage.limit_increase_requests:read"], + }, + "x-visibility": "Public", + }, + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + response_data: Any = None + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response(models.PlatformRequestResponse, http_res) + if utils.match_response( + http_res, + ["400", "401", "403", "404", "408", "429"], + "application/problem+json", + ): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, ["500", "503"], "application/problem+json"): + response_data = unmarshal_json_response( + errors.PlatformProblemDetailErrorData, http_res + ) + raise errors.PlatformProblemDetailError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + if utils.match_response(http_res, "5XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.GleanError("API error occurred", http_res, http_res_text) + + raise errors.GleanError("Unexpected response received", http_res) diff --git a/src/glean/api_client/utils/datetimes.py b/src/glean/api_client/utils/datetimes.py index adad2476..688c29a5 100644 --- a/src/glean/api_client/utils/datetimes.py +++ b/src/glean/api_client/utils/datetimes.py @@ -35,3 +35,7 @@ def parse_duration(duration_string: str) -> timedelta: pydantic, which is already a runtime dependency of the SDK. """ return _DURATION_ADAPTER.validate_python(duration_string) + + +def format_duration(duration: timedelta) -> str: + return _DURATION_ADAPTER.dump_python(duration, mode="json") diff --git a/src/glean/api_client/utils/url.py b/src/glean/api_client/utils/url.py index c78ccbae..8eeaa7b0 100644 --- a/src/glean/api_client/utils/url.py +++ b/src/glean/api_client/utils/url.py @@ -1,6 +1,5 @@ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" -from decimal import Decimal from typing import ( Any, Dict, @@ -105,7 +104,7 @@ def _populate_path_params( else: pp_vals.append(f"{pp_key},{_val_to_string(param[pp_key])}") path_param_values[f_name] = ",".join(pp_vals) - elif not isinstance(param, (str, int, float, complex, bool, Decimal)): + elif isinstance(param, BaseModel): param_fields: Dict[str, FieldInfo] = param.__class__.model_fields for name in param_fields: param_field = param_fields[name] @@ -132,7 +131,7 @@ def _populate_path_params( f"{param_name},{_val_to_string(param_field_val)}" ) path_param_values[f_name] = ",".join(pp_vals) - elif _is_set(param): + else: path_param_values[f_name] = _val_to_string(param) return globals_already_populated diff --git a/src/glean/api_client/utils/values.py b/src/glean/api_client/utils/values.py index ac217f47..094755b7 100644 --- a/src/glean/api_client/utils/values.py +++ b/src/glean/api_client/utils/values.py @@ -1,6 +1,6 @@ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" -from datetime import datetime +from datetime import datetime, timedelta from enum import Enum from email.message import Message from functools import partial @@ -13,6 +13,7 @@ from ..types.basemodel import Unset +from .datetimes import format_duration from .serializers import marshal_json from .metadata import ParamMetadata, find_field_metadata @@ -117,6 +118,8 @@ def _val_to_string(val) -> str: return str(val).lower() if isinstance(val, datetime): return str(val.isoformat().replace("+00:00", "Z")) + if isinstance(val, timedelta): + return format_duration(val) if isinstance(val, Enum): return str(val.value) diff --git a/tests/mockserver/internal/handler/generated_handlers.go b/tests/mockserver/internal/handler/generated_handlers.go index 0bea5676..c1637f6d 100644 --- a/tests/mockserver/internal/handler/generated_handlers.go +++ b/tests/mockserver/internal/handler/generated_handlers.go @@ -14,6 +14,9 @@ func GeneratedHandlers(ctx context.Context, dir *logging.HTTPFileDirectory, rt * return []*GeneratedHandler{ NewGeneratedHandler(ctx, http.MethodDelete, "/rest/api/index/custom-metadata/schema/{groupName}", pathDeleteRestAPIIndexCustomMetadataSchemaGroupName(dir, rt)), NewGeneratedHandler(ctx, http.MethodDelete, "/rest/api/index/document/{docId}/custom-metadata/{groupName}", pathDeleteRestAPIIndexDocumentDocIDCustomMetadataGroupName(dir, rt)), + NewGeneratedHandler(ctx, http.MethodGet, "/api/admin/usage/limit-increase-requests", pathGetAPIAdminUsageLimitIncreaseRequests(dir, rt)), + NewGeneratedHandler(ctx, http.MethodGet, "/api/admin/usage/limit-increase-requests/{request_id}", pathGetAPIAdminUsageLimitIncreaseRequestsRequestID(dir, rt)), + NewGeneratedHandler(ctx, http.MethodGet, "/api/admin/usage/settings", pathGetAPIAdminUsageSettings(dir, rt)), NewGeneratedHandler(ctx, http.MethodGet, "/api/agents/{agent_id}", pathGetAPIAgentsAgentID(dir, rt)), NewGeneratedHandler(ctx, http.MethodGet, "/api/agents/{agent_id}/runs/{run_id}", pathGetAPIAgentsAgentIDRunsRunID(dir, rt)), NewGeneratedHandler(ctx, http.MethodGet, "/api/agents/{agent_id}/schemas", pathGetAPIAgentsAgentIDSchemas(dir, rt)), @@ -29,6 +32,8 @@ func GeneratedHandlers(ctx context.Context, dir *logging.HTTPFileDirectory, rt * NewGeneratedHandler(ctx, http.MethodGet, "/api/trigger-presets/{preset_id}/input-values", pathGetAPITriggerPresetsPresetIDInputValues(dir, rt)), NewGeneratedHandler(ctx, http.MethodGet, "/api/triggers", pathGetAPITriggers(dir, rt)), NewGeneratedHandler(ctx, http.MethodGet, "/api/triggers/{trigger_id}", pathGetAPITriggersTriggerID(dir, rt)), + NewGeneratedHandler(ctx, http.MethodGet, "/api/usage/limit-increase-requests", pathGetAPIUsageLimitIncreaseRequests(dir, rt)), + NewGeneratedHandler(ctx, http.MethodGet, "/api/usage/limit-increase-requests/{request_id}", pathGetAPIUsageLimitIncreaseRequestsRequestID(dir, rt)), NewGeneratedHandler(ctx, http.MethodGet, "/rest/api/index/custom-metadata/schema/{groupName}", pathGetRestAPIIndexCustomMetadataSchemaGroupName(dir, rt)), NewGeneratedHandler(ctx, http.MethodGet, "/rest/api/v1/actions/actionpack/{actionPackId}/auth", pathGetRestAPIV1ActionsActionpackActionPackIDAuth(dir, rt)), NewGeneratedHandler(ctx, http.MethodGet, "/rest/api/v1/agents/{agent_id}", pathGetRestAPIV1AgentsAgentID(dir, rt)), @@ -43,9 +48,11 @@ func GeneratedHandlers(ctx context.Context, dir *logging.HTTPFileDirectory, rt * NewGeneratedHandler(ctx, http.MethodGet, "/rest/api/v1/tool-servers/{serverId}/auth", pathGetRestAPIV1ToolServersServerIDAuth(dir, rt)), NewGeneratedHandler(ctx, http.MethodGet, "/rest/api/v1/tool-servers/{serverId}/tools", pathGetRestAPIV1ToolServersServerIDTools(dir, rt)), NewGeneratedHandler(ctx, http.MethodGet, "/rest/api/v1/tools/list", pathGetRestAPIV1ToolsList(dir, rt)), + NewGeneratedHandler(ctx, http.MethodPatch, "/api/admin/usage/settings", pathPatchAPIAdminUsageSettings(dir, rt)), NewGeneratedHandler(ctx, http.MethodPatch, "/api/skills/{skill_id}", pathPatchAPISkillsSkillID(dir, rt)), NewGeneratedHandler(ctx, http.MethodPatch, "/api/triggers/{trigger_id}", pathPatchAPITriggersTriggerID(dir, rt)), NewGeneratedHandler(ctx, http.MethodPatch, "/rest/api/v1/configure/datasources/{datasourceId}/instances/{instanceId}", pathPatchRestAPIV1ConfigureDatasourcesDatasourceIDInstancesInstanceID(dir, rt)), + NewGeneratedHandler(ctx, http.MethodPost, "/api/admin/usage/limit-increase-requests", pathPostAPIAdminUsageLimitIncreaseRequests(dir, rt)), NewGeneratedHandler(ctx, http.MethodPost, "/api/agents/search", pathPostAPIAgentsSearch(dir, rt)), NewGeneratedHandler(ctx, http.MethodPost, "/api/agents/{agent_id}/cancellations", pathPostAPIAgentsAgentIDCancellations(dir, rt)), NewGeneratedHandler(ctx, http.MethodPost, "/api/agents/{agent_id}/responses", pathPostAPIAgentsAgentIDResponses(dir, rt)), @@ -90,6 +97,7 @@ func GeneratedHandlers(ctx context.Context, dir *logging.HTTPFileDirectory, rt * NewGeneratedHandler(ctx, http.MethodPost, "/api/trigger-presets/{preset_id}/events/search", pathPostAPITriggerPresetsPresetIDEventsSearch(dir, rt)), NewGeneratedHandler(ctx, http.MethodPost, "/api/triggers", pathPostAPITriggers(dir, rt)), NewGeneratedHandler(ctx, http.MethodPost, "/api/triggers/{trigger_id}/events/search", pathPostAPITriggersTriggerIDEventsSearch(dir, rt)), + NewGeneratedHandler(ctx, http.MethodPost, "/api/usage/limit-increase-requests", pathPostAPIUsageLimitIncreaseRequests(dir, rt)), NewGeneratedHandler(ctx, http.MethodPost, "/rest/api/index/submissions/{datasourceInstance}/{type}", pathPostRestAPIIndexSubmissionsDatasourceInstanceType(dir, rt)), NewGeneratedHandler(ctx, http.MethodPost, "/rest/api/v1/actions/actionpack/{actionPackId}/auth", pathPostRestAPIV1ActionsActionpackActionPackIDAuth(dir, rt)), NewGeneratedHandler(ctx, http.MethodPost, "/rest/api/v1/activity", pathPostRestAPIV1Activity(dir, rt)), diff --git a/tests/mockserver/internal/handler/pathgetapiadminusagelimitincreaserequests.go b/tests/mockserver/internal/handler/pathgetapiadminusagelimitincreaserequests.go new file mode 100644 index 00000000..468ea6c3 --- /dev/null +++ b/tests/mockserver/internal/handler/pathgetapiadminusagelimitincreaserequests.go @@ -0,0 +1,81 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package handler + +import ( + "fmt" + "log" + "mockserver/internal/handler/assert" + "mockserver/internal/logging" + "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/types" + "mockserver/internal/sdk/utils" + "mockserver/internal/tracking" + "net/http" +) + +func pathGetAPIAdminUsageLimitIncreaseRequests(dir *logging.HTTPFileDirectory, rt *tracking.RequestTracker) http.HandlerFunc { + return func(w http.ResponseWriter, req *http.Request) { + test := req.Header.Get("x-speakeasy-test-name") + instanceID := req.Header.Get("x-speakeasy-test-instance-id") + + count := rt.GetRequestCount(test, instanceID) + + switch fmt.Sprintf("%s[%d]", test, count) { + case "platform-admin-usage-requests-list[0]": + dir.HandlerFunc("platform-admin-usage-requests-list", testPlatformAdminUsageRequestsListPlatformAdminUsageRequestsList0)(w, req) + default: + http.Error(w, fmt.Sprintf("Unknown test: %s[%d]", test, count), http.StatusBadRequest) + } + } +} + +func testPlatformAdminUsageRequestsListPlatformAdminUsageRequestsList0(w http.ResponseWriter, req *http.Request) { + if err := assert.SecurityAuthorizationHeader(req, false, "Bearer"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusUnauthorized) + return + } + if err := assert.AcceptHeader(req, []string{"application/json"}); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + if err := assert.HeaderExists(req, "User-Agent"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + var respBody *components.PlatformRequestListResponseUnion = types.Pointer(components.CreatePlatformRequestListResponseUnionPlatformRequestListResponse1( + components.PlatformRequestListResponse1{ + HasMore: false, + NextCursor: types.String(""), + Results: []components.PlatformLimitIncreaseRequest{ + components.PlatformLimitIncreaseRequest{ + RequestID: "", + EntityType: components.PlatformLimitIncreaseRequestEntityTypeUser, + EntityID: "", + ClientID: "", + RequesterUserID: "", + Period: "", + Status: components.PlatformRequestStatusPending, + CreatedAt: types.MustTimeFromString("2024-01-15T07:33:22.777Z"), + }, + }, + RequestID: "", + }, + )) + respBodyBytes, err := utils.MarshalJSON(respBody, "", true) + + if err != nil { + http.Error( + w, + "Unable to encode response body as JSON: "+err.Error(), + http.StatusInternalServerError, + ) + return + } + w.Header().Set("Content-Type", "application/json") + w.WriteHeader(http.StatusOK) + _, _ = w.Write(respBodyBytes) +} diff --git a/tests/mockserver/internal/handler/pathgetapiadminusagelimitincreaserequestsrequestid.go b/tests/mockserver/internal/handler/pathgetapiadminusagelimitincreaserequestsrequestid.go new file mode 100644 index 00000000..20caa9fe --- /dev/null +++ b/tests/mockserver/internal/handler/pathgetapiadminusagelimitincreaserequestsrequestid.go @@ -0,0 +1,75 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package handler + +import ( + "fmt" + "log" + "mockserver/internal/handler/assert" + "mockserver/internal/logging" + "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/types" + "mockserver/internal/sdk/utils" + "mockserver/internal/tracking" + "net/http" +) + +func pathGetAPIAdminUsageLimitIncreaseRequestsRequestID(dir *logging.HTTPFileDirectory, rt *tracking.RequestTracker) http.HandlerFunc { + return func(w http.ResponseWriter, req *http.Request) { + test := req.Header.Get("x-speakeasy-test-name") + instanceID := req.Header.Get("x-speakeasy-test-instance-id") + + count := rt.GetRequestCount(test, instanceID) + + switch fmt.Sprintf("%s[%d]", test, count) { + case "platform-admin-usage-requests-get[0]": + dir.HandlerFunc("platform-admin-usage-requests-get", testPlatformAdminUsageRequestsGetPlatformAdminUsageRequestsGet0)(w, req) + default: + http.Error(w, fmt.Sprintf("Unknown test: %s[%d]", test, count), http.StatusBadRequest) + } + } +} + +func testPlatformAdminUsageRequestsGetPlatformAdminUsageRequestsGet0(w http.ResponseWriter, req *http.Request) { + if err := assert.SecurityAuthorizationHeader(req, false, "Bearer"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusUnauthorized) + return + } + if err := assert.AcceptHeader(req, []string{"application/json"}); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + if err := assert.HeaderExists(req, "User-Agent"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + var respBody *components.PlatformRequestResponse = &components.PlatformRequestResponse{ + Request: components.PlatformLimitIncreaseRequest{ + RequestID: "", + EntityType: components.PlatformLimitIncreaseRequestEntityTypeUser, + EntityID: "", + ClientID: "", + RequesterUserID: "", + Period: "", + Status: components.PlatformRequestStatusApproved, + CreatedAt: types.MustTimeFromString("2024-11-21T17:52:20.403Z"), + }, + RequestID: "", + } + respBodyBytes, err := utils.MarshalJSON(respBody, "", true) + + if err != nil { + http.Error( + w, + "Unable to encode response body as JSON: "+err.Error(), + http.StatusInternalServerError, + ) + return + } + w.Header().Set("Content-Type", "application/json") + w.WriteHeader(http.StatusOK) + _, _ = w.Write(respBodyBytes) +} diff --git a/tests/mockserver/internal/handler/pathgetapiadminusagesettings.go b/tests/mockserver/internal/handler/pathgetapiadminusagesettings.go new file mode 100644 index 00000000..c67f41c3 --- /dev/null +++ b/tests/mockserver/internal/handler/pathgetapiadminusagesettings.go @@ -0,0 +1,65 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package handler + +import ( + "fmt" + "log" + "mockserver/internal/handler/assert" + "mockserver/internal/logging" + "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/utils" + "mockserver/internal/tracking" + "net/http" +) + +func pathGetAPIAdminUsageSettings(dir *logging.HTTPFileDirectory, rt *tracking.RequestTracker) http.HandlerFunc { + return func(w http.ResponseWriter, req *http.Request) { + test := req.Header.Get("x-speakeasy-test-name") + instanceID := req.Header.Get("x-speakeasy-test-instance-id") + + count := rt.GetRequestCount(test, instanceID) + + switch fmt.Sprintf("%s[%d]", test, count) { + case "platform-admin-usage-settings-get[0]": + dir.HandlerFunc("platform-admin-usage-settings-get", testPlatformAdminUsageSettingsGetPlatformAdminUsageSettingsGet0)(w, req) + default: + http.Error(w, fmt.Sprintf("Unknown test: %s[%d]", test, count), http.StatusBadRequest) + } + } +} + +func testPlatformAdminUsageSettingsGetPlatformAdminUsageSettingsGet0(w http.ResponseWriter, req *http.Request) { + if err := assert.SecurityAuthorizationHeader(req, false, "Bearer"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusUnauthorized) + return + } + if err := assert.AcceptHeader(req, []string{"application/json"}); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + if err := assert.HeaderExists(req, "User-Agent"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + var respBody *components.PlatformUsageSettingsResponse = &components.PlatformUsageSettingsResponse{ + UsageSettings: components.PlatformUsageSettingsResource{}, + RequestID: "", + } + respBodyBytes, err := utils.MarshalJSON(respBody, "", true) + + if err != nil { + http.Error( + w, + "Unable to encode response body as JSON: "+err.Error(), + http.StatusInternalServerError, + ) + return + } + w.Header().Set("Content-Type", "application/json") + w.WriteHeader(http.StatusOK) + _, _ = w.Write(respBodyBytes) +} diff --git a/tests/mockserver/internal/handler/pathgetapiskills.go b/tests/mockserver/internal/handler/pathgetapiskills.go index 7baa51e7..7eb2a3a1 100644 --- a/tests/mockserver/internal/handler/pathgetapiskills.go +++ b/tests/mockserver/internal/handler/pathgetapiskills.go @@ -47,7 +47,7 @@ func testPlatformSkillsListPlatformSkillsList0(w http.ResponseWriter, req *http. return } var respBody *components.PlatformSkillsListResponse = &components.PlatformSkillsListResponse{ - Skills: []components.PlatformSkill{}, + Results: []components.PlatformSkill{}, HasMore: true, NextCursor: types.String(""), RequestID: "", diff --git a/tests/mockserver/internal/handler/pathgetapiskillsskillid.go b/tests/mockserver/internal/handler/pathgetapiskillsskillid.go index 4f097d84..7e0b98d7 100644 --- a/tests/mockserver/internal/handler/pathgetapiskillsskillid.go +++ b/tests/mockserver/internal/handler/pathgetapiskillsskillid.go @@ -48,7 +48,7 @@ func testPlatformSkillsGetPlatformSkillsGet0(w http.ResponseWriter, req *http.Re } var respBody *components.PlatformSkillGetResponse = &components.PlatformSkillGetResponse{ Skill: components.PlatformSkill{ - ID: "", + SkillID: "", DisplayName: "Chad_Herzog", Description: "whenever up aha controvert", LatestVersion: 151495, diff --git a/tests/mockserver/internal/handler/pathgetapiskillsskillidversions.go b/tests/mockserver/internal/handler/pathgetapiskillsskillidversions.go index 878e7567..41840fae 100644 --- a/tests/mockserver/internal/handler/pathgetapiskillsskillidversions.go +++ b/tests/mockserver/internal/handler/pathgetapiskillsskillidversions.go @@ -47,7 +47,7 @@ func testPlatformSkillsListVersionsPlatformSkillsListVersions0(w http.ResponseWr return } var respBody *components.PlatformSkillVersionsListResponse = &components.PlatformSkillVersionsListResponse{ - Versions: []components.PlatformSkillVersion{}, + Results: []components.PlatformSkillVersion{}, HasMore: false, NextCursor: types.String(""), RequestID: "", diff --git a/tests/mockserver/internal/handler/pathgetapiusagelimitincreaserequests.go b/tests/mockserver/internal/handler/pathgetapiusagelimitincreaserequests.go new file mode 100644 index 00000000..5aea708c --- /dev/null +++ b/tests/mockserver/internal/handler/pathgetapiusagelimitincreaserequests.go @@ -0,0 +1,69 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package handler + +import ( + "fmt" + "log" + "mockserver/internal/handler/assert" + "mockserver/internal/logging" + "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/types" + "mockserver/internal/sdk/utils" + "mockserver/internal/tracking" + "net/http" +) + +func pathGetAPIUsageLimitIncreaseRequests(dir *logging.HTTPFileDirectory, rt *tracking.RequestTracker) http.HandlerFunc { + return func(w http.ResponseWriter, req *http.Request) { + test := req.Header.Get("x-speakeasy-test-name") + instanceID := req.Header.Get("x-speakeasy-test-instance-id") + + count := rt.GetRequestCount(test, instanceID) + + switch fmt.Sprintf("%s[%d]", test, count) { + case "platform-usage-requests-list[0]": + dir.HandlerFunc("platform-usage-requests-list", testPlatformUsageRequestsListPlatformUsageRequestsList0)(w, req) + default: + http.Error(w, fmt.Sprintf("Unknown test: %s[%d]", test, count), http.StatusBadRequest) + } + } +} + +func testPlatformUsageRequestsListPlatformUsageRequestsList0(w http.ResponseWriter, req *http.Request) { + if err := assert.SecurityAuthorizationHeader(req, false, "Bearer"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusUnauthorized) + return + } + if err := assert.AcceptHeader(req, []string{"application/json"}); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + if err := assert.HeaderExists(req, "User-Agent"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + var respBody *components.PlatformRequestListResponseUnion = types.Pointer(components.CreatePlatformRequestListResponseUnionPlatformRequestListResponse2( + components.PlatformRequestListResponse2{ + HasMore: false, + Results: []components.PlatformLimitIncreaseRequest{}, + RequestID: "", + }, + )) + respBodyBytes, err := utils.MarshalJSON(respBody, "", true) + + if err != nil { + http.Error( + w, + "Unable to encode response body as JSON: "+err.Error(), + http.StatusInternalServerError, + ) + return + } + w.Header().Set("Content-Type", "application/json") + w.WriteHeader(http.StatusOK) + _, _ = w.Write(respBodyBytes) +} diff --git a/tests/mockserver/internal/handler/pathgetapiusagelimitincreaserequestsrequestid.go b/tests/mockserver/internal/handler/pathgetapiusagelimitincreaserequestsrequestid.go new file mode 100644 index 00000000..8870512c --- /dev/null +++ b/tests/mockserver/internal/handler/pathgetapiusagelimitincreaserequestsrequestid.go @@ -0,0 +1,75 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package handler + +import ( + "fmt" + "log" + "mockserver/internal/handler/assert" + "mockserver/internal/logging" + "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/types" + "mockserver/internal/sdk/utils" + "mockserver/internal/tracking" + "net/http" +) + +func pathGetAPIUsageLimitIncreaseRequestsRequestID(dir *logging.HTTPFileDirectory, rt *tracking.RequestTracker) http.HandlerFunc { + return func(w http.ResponseWriter, req *http.Request) { + test := req.Header.Get("x-speakeasy-test-name") + instanceID := req.Header.Get("x-speakeasy-test-instance-id") + + count := rt.GetRequestCount(test, instanceID) + + switch fmt.Sprintf("%s[%d]", test, count) { + case "platform-usage-requests-get[0]": + dir.HandlerFunc("platform-usage-requests-get", testPlatformUsageRequestsGetPlatformUsageRequestsGet0)(w, req) + default: + http.Error(w, fmt.Sprintf("Unknown test: %s[%d]", test, count), http.StatusBadRequest) + } + } +} + +func testPlatformUsageRequestsGetPlatformUsageRequestsGet0(w http.ResponseWriter, req *http.Request) { + if err := assert.SecurityAuthorizationHeader(req, false, "Bearer"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusUnauthorized) + return + } + if err := assert.AcceptHeader(req, []string{"application/json"}); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + if err := assert.HeaderExists(req, "User-Agent"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + var respBody *components.PlatformRequestResponse = &components.PlatformRequestResponse{ + Request: components.PlatformLimitIncreaseRequest{ + RequestID: "", + EntityType: components.PlatformLimitIncreaseRequestEntityTypeAgent, + EntityID: "", + ClientID: "", + RequesterUserID: "", + Period: "", + Status: components.PlatformRequestStatusDenied, + CreatedAt: types.MustTimeFromString("2026-10-11T16:53:21.602Z"), + }, + RequestID: "", + } + respBodyBytes, err := utils.MarshalJSON(respBody, "", true) + + if err != nil { + http.Error( + w, + "Unable to encode response body as JSON: "+err.Error(), + http.StatusInternalServerError, + ) + return + } + w.Header().Set("Content-Type", "application/json") + w.WriteHeader(http.StatusOK) + _, _ = w.Write(respBodyBytes) +} diff --git a/tests/mockserver/internal/handler/pathpatchapiadminusagesettings.go b/tests/mockserver/internal/handler/pathpatchapiadminusagesettings.go new file mode 100644 index 00000000..53d7718e --- /dev/null +++ b/tests/mockserver/internal/handler/pathpatchapiadminusagesettings.go @@ -0,0 +1,70 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package handler + +import ( + "fmt" + "log" + "mockserver/internal/handler/assert" + "mockserver/internal/logging" + "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/utils" + "mockserver/internal/tracking" + "net/http" +) + +func pathPatchAPIAdminUsageSettings(dir *logging.HTTPFileDirectory, rt *tracking.RequestTracker) http.HandlerFunc { + return func(w http.ResponseWriter, req *http.Request) { + test := req.Header.Get("x-speakeasy-test-name") + instanceID := req.Header.Get("x-speakeasy-test-instance-id") + + count := rt.GetRequestCount(test, instanceID) + + switch fmt.Sprintf("%s[%d]", test, count) { + case "platform-admin-usage-settings-update[0]": + dir.HandlerFunc("platform-admin-usage-settings-update", testPlatformAdminUsageSettingsUpdatePlatformAdminUsageSettingsUpdate0)(w, req) + default: + http.Error(w, fmt.Sprintf("Unknown test: %s[%d]", test, count), http.StatusBadRequest) + } + } +} + +func testPlatformAdminUsageSettingsUpdatePlatformAdminUsageSettingsUpdate0(w http.ResponseWriter, req *http.Request) { + if err := assert.SecurityAuthorizationHeader(req, false, "Bearer"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusUnauthorized) + return + } + if err := assert.ContentType(req, "application/json", true); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + if err := assert.AcceptHeader(req, []string{"application/json"}); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + if err := assert.HeaderExists(req, "User-Agent"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + var respBody *components.PlatformUsageSettingsResponse = &components.PlatformUsageSettingsResponse{ + UsageSettings: components.PlatformUsageSettingsResource{}, + RequestID: "", + } + respBodyBytes, err := utils.MarshalJSON(respBody, "", true) + + if err != nil { + http.Error( + w, + "Unable to encode response body as JSON: "+err.Error(), + http.StatusInternalServerError, + ) + return + } + w.Header().Set("Content-Type", "application/json") + w.WriteHeader(http.StatusOK) + _, _ = w.Write(respBodyBytes) +} diff --git a/tests/mockserver/internal/handler/pathpatchapiskillsskillid.go b/tests/mockserver/internal/handler/pathpatchapiskillsskillid.go index 2b4d9db5..abc15386 100644 --- a/tests/mockserver/internal/handler/pathpatchapiskillsskillid.go +++ b/tests/mockserver/internal/handler/pathpatchapiskillsskillid.go @@ -53,7 +53,7 @@ func testPlatformSkillsUpdatePlatformSkillsUpdate0(w http.ResponseWriter, req *h } var respBody *components.PlatformSkillUpdateResponse = &components.PlatformSkillUpdateResponse{ Skill: components.PlatformSkill{ - ID: "", + SkillID: "", DisplayName: "Afton14", Description: "taut netsuke duh sonata boastfully elegantly management come", LatestVersion: 425795, diff --git a/tests/mockserver/internal/handler/pathpostapiadminusagelimitincreaserequests.go b/tests/mockserver/internal/handler/pathpostapiadminusagelimitincreaserequests.go new file mode 100644 index 00000000..f4024d9b --- /dev/null +++ b/tests/mockserver/internal/handler/pathpostapiadminusagelimitincreaserequests.go @@ -0,0 +1,80 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package handler + +import ( + "fmt" + "log" + "mockserver/internal/handler/assert" + "mockserver/internal/logging" + "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/types" + "mockserver/internal/sdk/utils" + "mockserver/internal/tracking" + "net/http" +) + +func pathPostAPIAdminUsageLimitIncreaseRequests(dir *logging.HTTPFileDirectory, rt *tracking.RequestTracker) http.HandlerFunc { + return func(w http.ResponseWriter, req *http.Request) { + test := req.Header.Get("x-speakeasy-test-name") + instanceID := req.Header.Get("x-speakeasy-test-instance-id") + + count := rt.GetRequestCount(test, instanceID) + + switch fmt.Sprintf("%s[%d]", test, count) { + case "platform-admin-usage-requests-create[0]": + dir.HandlerFunc("platform-admin-usage-requests-create", testPlatformAdminUsageRequestsCreatePlatformAdminUsageRequestsCreate0)(w, req) + default: + http.Error(w, fmt.Sprintf("Unknown test: %s[%d]", test, count), http.StatusBadRequest) + } + } +} + +func testPlatformAdminUsageRequestsCreatePlatformAdminUsageRequestsCreate0(w http.ResponseWriter, req *http.Request) { + if err := assert.SecurityAuthorizationHeader(req, false, "Bearer"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusUnauthorized) + return + } + if err := assert.ContentType(req, "application/json", true); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + if err := assert.AcceptHeader(req, []string{"application/json"}); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + if err := assert.HeaderExists(req, "User-Agent"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + var respBody *components.PlatformRequestResponse = &components.PlatformRequestResponse{ + Request: components.PlatformLimitIncreaseRequest{ + RequestID: "", + EntityType: components.PlatformLimitIncreaseRequestEntityTypeUser, + EntityID: "", + ClientID: "", + RequesterUserID: "", + Period: "", + Status: components.PlatformRequestStatusDenied, + CreatedAt: types.MustTimeFromString("2024-10-18T04:43:55.054Z"), + }, + RequestID: "", + } + respBodyBytes, err := utils.MarshalJSON(respBody, "", true) + + if err != nil { + http.Error( + w, + "Unable to encode response body as JSON: "+err.Error(), + http.StatusInternalServerError, + ) + return + } + w.Header().Set("Content-Type", "application/json") + w.WriteHeader(http.StatusCreated) + _, _ = w.Write(respBodyBytes) +} diff --git a/tests/mockserver/internal/handler/pathpostapiskills.go b/tests/mockserver/internal/handler/pathpostapiskills.go index dfe54aaf..d6998289 100644 --- a/tests/mockserver/internal/handler/pathpostapiskills.go +++ b/tests/mockserver/internal/handler/pathpostapiskills.go @@ -53,7 +53,7 @@ func testPlatformSkillsCreatePlatformSkillsCreate0(w http.ResponseWriter, req *h } var respBody *components.PlatformSkillCreateResponse = &components.PlatformSkillCreateResponse{ Skill: components.PlatformSkill{ - ID: "", + SkillID: "", DisplayName: "Merl18", Description: "rural ugh unexpectedly excepting livid", LatestVersion: 504149, @@ -63,8 +63,8 @@ func testPlatformSkillsCreatePlatformSkillsCreate0(w http.ResponseWriter, req *h Owner: components.PlatformPersonReference{ Name: "", }, - CreatedAt: types.MustTimeFromString("2025-01-04T03:16:16.951Z"), - UpdatedAt: types.MustTimeFromString("2025-09-10T16:05:46.046Z"), + CreatedAt: types.MustTimeFromString("2025-09-10T16:05:46.046Z"), + UpdatedAt: types.MustTimeFromString("2025-08-13T23:05:45.737Z"), }, RequestID: "", } @@ -79,6 +79,6 @@ func testPlatformSkillsCreatePlatformSkillsCreate0(w http.ResponseWriter, req *h return } w.Header().Set("Content-Type", "application/json") - w.WriteHeader(http.StatusOK) + w.WriteHeader(http.StatusCreated) _, _ = w.Write(respBodyBytes) } diff --git a/tests/mockserver/internal/handler/pathpostapiskillsimport.go b/tests/mockserver/internal/handler/pathpostapiskillsimport.go index cdcc73da..6c82be5d 100644 --- a/tests/mockserver/internal/handler/pathpostapiskillsimport.go +++ b/tests/mockserver/internal/handler/pathpostapiskillsimport.go @@ -65,6 +65,6 @@ func testPlatformSkillsImportPlatformSkillsImport0(w http.ResponseWriter, req *h return } w.Header().Set("Content-Type", "application/json") - w.WriteHeader(http.StatusOK) + w.WriteHeader(http.StatusCreated) _, _ = w.Write(respBodyBytes) } diff --git a/tests/mockserver/internal/handler/pathpostapiskillsskillidsync.go b/tests/mockserver/internal/handler/pathpostapiskillsskillidsync.go index 0cab544f..c54314fa 100644 --- a/tests/mockserver/internal/handler/pathpostapiskillsskillidsync.go +++ b/tests/mockserver/internal/handler/pathpostapiskillsskillidsync.go @@ -46,10 +46,9 @@ func testPlatformSkillsSyncPlatformSkillsSync0(w http.ResponseWriter, req *http. return } var respBody *components.PlatformSkillSyncResponse = &components.PlatformSkillSyncResponse{ - SyncStatus: components.PlatformSkillSyncResultStatusUpToDate, - CommitSha: "", - Updated: false, - RequestID: "", + CommitSha: "", + IsUpdated: false, + RequestID: "", } respBodyBytes, err := utils.MarshalJSON(respBody, "", true) diff --git a/tests/mockserver/internal/handler/pathpostapiskillsskillidversions.go b/tests/mockserver/internal/handler/pathpostapiskillsskillidversions.go index 1f3d1fde..664245fc 100644 --- a/tests/mockserver/internal/handler/pathpostapiskillsskillidversions.go +++ b/tests/mockserver/internal/handler/pathpostapiskillsskillidversions.go @@ -76,6 +76,6 @@ func testPlatformSkillsCreateVersionPlatformSkillsCreateVersion0(w http.Response return } w.Header().Set("Content-Type", "application/json") - w.WriteHeader(http.StatusOK) + w.WriteHeader(http.StatusCreated) _, _ = w.Write(respBodyBytes) } diff --git a/tests/mockserver/internal/handler/pathpostapiskillssourcespreview.go b/tests/mockserver/internal/handler/pathpostapiskillssourcespreview.go index 11e0efca..f8a79c8f 100644 --- a/tests/mockserver/internal/handler/pathpostapiskillssourcespreview.go +++ b/tests/mockserver/internal/handler/pathpostapiskillssourcespreview.go @@ -40,7 +40,7 @@ func testPlatformSkillsPreviewSourcePlatformSkillsPreviewSource0(w http.Response http.Error(w, err.Error(), http.StatusBadRequest) return } - if err := assert.AcceptHeader(req, []string{"application/json;q=1", "text/event-stream;q=0"}); err != nil { + if err := assert.AcceptHeader(req, []string{"application/json"}); err != nil { log.Printf("assertion error: %s\n", err) http.Error(w, err.Error(), http.StatusBadRequest) return diff --git a/tests/mockserver/internal/handler/pathpostapiusagelimitincreaserequests.go b/tests/mockserver/internal/handler/pathpostapiusagelimitincreaserequests.go new file mode 100644 index 00000000..cbc96cd7 --- /dev/null +++ b/tests/mockserver/internal/handler/pathpostapiusagelimitincreaserequests.go @@ -0,0 +1,80 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package handler + +import ( + "fmt" + "log" + "mockserver/internal/handler/assert" + "mockserver/internal/logging" + "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/types" + "mockserver/internal/sdk/utils" + "mockserver/internal/tracking" + "net/http" +) + +func pathPostAPIUsageLimitIncreaseRequests(dir *logging.HTTPFileDirectory, rt *tracking.RequestTracker) http.HandlerFunc { + return func(w http.ResponseWriter, req *http.Request) { + test := req.Header.Get("x-speakeasy-test-name") + instanceID := req.Header.Get("x-speakeasy-test-instance-id") + + count := rt.GetRequestCount(test, instanceID) + + switch fmt.Sprintf("%s[%d]", test, count) { + case "platform-usage-requests-create[0]": + dir.HandlerFunc("platform-usage-requests-create", testPlatformUsageRequestsCreatePlatformUsageRequestsCreate0)(w, req) + default: + http.Error(w, fmt.Sprintf("Unknown test: %s[%d]", test, count), http.StatusBadRequest) + } + } +} + +func testPlatformUsageRequestsCreatePlatformUsageRequestsCreate0(w http.ResponseWriter, req *http.Request) { + if err := assert.SecurityAuthorizationHeader(req, false, "Bearer"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusUnauthorized) + return + } + if err := assert.ContentType(req, "application/json", true); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + if err := assert.AcceptHeader(req, []string{"application/json"}); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + if err := assert.HeaderExists(req, "User-Agent"); err != nil { + log.Printf("assertion error: %s\n", err) + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + var respBody *components.PlatformRequestResponse = &components.PlatformRequestResponse{ + Request: components.PlatformLimitIncreaseRequest{ + RequestID: "", + EntityType: components.PlatformLimitIncreaseRequestEntityTypeAgent, + EntityID: "", + ClientID: "", + RequesterUserID: "", + Period: "", + Status: components.PlatformRequestStatusPending, + CreatedAt: types.MustTimeFromString("2024-07-26T20:31:19.316Z"), + }, + RequestID: "", + } + respBodyBytes, err := utils.MarshalJSON(respBody, "", true) + + if err != nil { + http.Error( + w, + "Unable to encode response body as JSON: "+err.Error(), + http.StatusInternalServerError, + ) + return + } + w.Header().Set("Content-Type", "application/json") + w.WriteHeader(http.StatusCreated) + _, _ = w.Write(respBodyBytes) +} diff --git a/tests/mockserver/internal/handler/pathpostrestapiv1createcollection.go b/tests/mockserver/internal/handler/pathpostrestapiv1createcollection.go index 75fb8eb7..469bd6e6 100644 --- a/tests/mockserver/internal/handler/pathpostrestapiv1createcollection.go +++ b/tests/mockserver/internal/handler/pathpostrestapiv1createcollection.go @@ -56,14 +56,14 @@ func testCreatecollectionCreatecollection0(w http.ResponseWriter, req *http.Requ operations.ResponseBody2{ Collection: &components.Collection{ Name: "", - Description: "motionless whenever paintwork import over cuckoo", + Description: "whole busily jive hawk gee basic minus hence", AddedRoles: []components.UserRoleSpecification{ components.UserRoleSpecification{ Person: &components.Person{ Name: "George Clooney", ObfuscatedID: "abc123", }, - Role: components.UserRoleOwner, + Role: components.UserRoleAnswerModerator, }, }, RemovedRoles: []components.UserRoleSpecification{ @@ -90,7 +90,7 @@ func testCreatecollectionCreatecollection0(w http.ResponseWriter, req *http.Requ }, }, }, - ID: 363711, + ID: 158969, Creator: &components.Person{ Name: "George Clooney", ObfuscatedID: "abc123", @@ -101,7 +101,7 @@ func testCreatecollectionCreatecollection0(w http.ResponseWriter, req *http.Requ }, Items: []components.CollectionItem{ components.CollectionItem{ - CollectionID: 570197, + CollectionID: 110375, CreatedBy: &components.Person{ Name: "George Clooney", ObfuscatedID: "abc123", @@ -278,13 +278,13 @@ func testCreatecollectionCreatecollection0(w http.ResponseWriter, req *http.Requ Name: "George Clooney", ObfuscatedID: "abc123", }, - Role: components.UserRoleAnswerModerator, + Role: components.UserRoleEditor, }, }, }, Collection: &components.Collection{ Name: "", - Description: "athwart skateboard newsstand farm bourgeoisie ah how elliptical aha well-to-do", + Description: "wedge colorfully orientate rally", AudienceFilters: []components.FacetFilter{ components.FacetFilter{ FieldName: types.String("type"), @@ -300,7 +300,7 @@ func testCreatecollectionCreatecollection0(w http.ResponseWriter, req *http.Requ }, }, }, - ID: 643990, + ID: 131797, Creator: &components.Person{ Name: "George Clooney", ObfuscatedID: "abc123", @@ -312,7 +312,7 @@ func testCreatecollectionCreatecollection0(w http.ResponseWriter, req *http.Requ Children: []components.Collection{ components.Collection{ Name: "", - Description: "woot purse salty even as advanced", + Description: "outside yippee sidetrack mature regularly mouser inject worth", AudienceFilters: []components.FacetFilter{ components.FacetFilter{ FieldName: types.String("type"), @@ -328,7 +328,7 @@ func testCreatecollectionCreatecollection0(w http.ResponseWriter, req *http.Requ }, }, }, - ID: 359978, + ID: 149448, Creator: &components.Person{ Name: "George Clooney", ObfuscatedID: "abc123", @@ -340,7 +340,7 @@ func testCreatecollectionCreatecollection0(w http.ResponseWriter, req *http.Requ }, }, }, - ItemType: components.CollectionItemItemTypeURL, + ItemType: components.CollectionItemItemTypeCollection, }, }, }, diff --git a/tests/mockserver/internal/sdk/models/components/artifacttype.go b/tests/mockserver/internal/sdk/models/components/artifacttype.go new file mode 100644 index 00000000..c07eb6aa --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/artifacttype.go @@ -0,0 +1,47 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" +) + +// ArtifactType - Type of the Artifact +type ArtifactType string + +const ( + ArtifactTypePaper ArtifactType = "PAPER" + ArtifactTypeAgent ArtifactType = "AGENT" + ArtifactTypeMessage ArtifactType = "MESSAGE" + ArtifactTypeEmail ArtifactType = "EMAIL" + ArtifactTypeHTMLCode ArtifactType = "HTML_CODE" + ArtifactTypeSlide ArtifactType = "SLIDE" +) + +func (e ArtifactType) ToPointer() *ArtifactType { + return &e +} +func (e *ArtifactType) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "PAPER": + fallthrough + case "AGENT": + fallthrough + case "MESSAGE": + fallthrough + case "EMAIL": + fallthrough + case "HTML_CODE": + fallthrough + case "SLIDE": + *e = ArtifactType(v) + return nil + default: + return fmt.Errorf("invalid value for ArtifactType: %v", v) + } +} diff --git a/tests/mockserver/internal/sdk/models/components/autocompleterequest.go b/tests/mockserver/internal/sdk/models/components/autocompleterequest.go index 2b02c414..d3de9d57 100644 --- a/tests/mockserver/internal/sdk/models/components/autocompleterequest.go +++ b/tests/mockserver/internal/sdk/models/components/autocompleterequest.go @@ -13,12 +13,12 @@ const ( AutocompleteRequestResultTypeAdditionalDocument AutocompleteRequestResultType = "ADDITIONAL_DOCUMENT" AutocompleteRequestResultTypeApp AutocompleteRequestResultType = "APP" AutocompleteRequestResultTypeBrowserHistory AutocompleteRequestResultType = "BROWSER_HISTORY" + AutocompleteRequestResultTypeChatHistory AutocompleteRequestResultType = "CHAT_HISTORY" AutocompleteRequestResultTypeDatasource AutocompleteRequestResultType = "DATASOURCE" AutocompleteRequestResultTypeDocument AutocompleteRequestResultType = "DOCUMENT" AutocompleteRequestResultTypeEntity AutocompleteRequestResultType = "ENTITY" AutocompleteRequestResultTypeGolink AutocompleteRequestResultType = "GOLINK" AutocompleteRequestResultTypeHistory AutocompleteRequestResultType = "HISTORY" - AutocompleteRequestResultTypeChatHistory AutocompleteRequestResultType = "CHAT_HISTORY" AutocompleteRequestResultTypeNewChat AutocompleteRequestResultType = "NEW_CHAT" AutocompleteRequestResultTypeOperator AutocompleteRequestResultType = "OPERATOR" AutocompleteRequestResultTypeOperatorValue AutocompleteRequestResultType = "OPERATOR_VALUE" @@ -41,6 +41,8 @@ func (e *AutocompleteRequestResultType) UnmarshalJSON(data []byte) error { fallthrough case "BROWSER_HISTORY": fallthrough + case "CHAT_HISTORY": + fallthrough case "DATASOURCE": fallthrough case "DOCUMENT": @@ -51,8 +53,6 @@ func (e *AutocompleteRequestResultType) UnmarshalJSON(data []byte) error { fallthrough case "HISTORY": fallthrough - case "CHAT_HISTORY": - fallthrough case "NEW_CHAT": fallthrough case "OPERATOR": diff --git a/tests/mockserver/internal/sdk/models/components/chatsuggestion.go b/tests/mockserver/internal/sdk/models/components/chatsuggestion.go index b8269ceb..73c2c222 100644 --- a/tests/mockserver/internal/sdk/models/components/chatsuggestion.go +++ b/tests/mockserver/internal/sdk/models/components/chatsuggestion.go @@ -9,6 +9,8 @@ type ChatSuggestion struct { Cta *string `json:"cta,omitempty"` // Targeted Glean Chat feature for the suggestion. Feature *string `json:"feature,omitempty"` + // Type of the Artifact + ArtifactType *ArtifactType `json:"artifactType,omitempty"` // Document IDs that grounded the suggestion. SourceDocumentIds []string `json:"sourceDocumentIds,omitempty"` } @@ -34,6 +36,13 @@ func (o *ChatSuggestion) GetFeature() *string { return o.Feature } +func (o *ChatSuggestion) GetArtifactType() *ArtifactType { + if o == nil { + return nil + } + return o.ArtifactType +} + func (o *ChatSuggestion) GetSourceDocumentIds() []string { if o == nil { return nil diff --git a/tests/mockserver/internal/sdk/models/components/feedentry.go b/tests/mockserver/internal/sdk/models/components/feedentry.go index 44f5dfe7..44e6f90d 100644 --- a/tests/mockserver/internal/sdk/models/components/feedentry.go +++ b/tests/mockserver/internal/sdk/models/components/feedentry.go @@ -124,6 +124,8 @@ const ( JustificationTypeShareArtifact JustificationType = "SHARE_ARTIFACT" JustificationTypeCreateAgent JustificationType = "CREATE_AGENT" JustificationTypeManagerInvite JustificationType = "MANAGER_INVITE" + JustificationTypeOnboardingAuthorization JustificationType = "ONBOARDING_AUTHORIZATION" + JustificationTypeChatReminder JustificationType = "CHAT_REMINDER" ) func (e JustificationType) ToPointer() *JustificationType { @@ -270,6 +272,10 @@ func (e *JustificationType) UnmarshalJSON(data []byte) error { case "CREATE_AGENT": fallthrough case "MANAGER_INVITE": + fallthrough + case "ONBOARDING_AUTHORIZATION": + fallthrough + case "CHAT_REMINDER": *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 9489bdd5..b89f4ded 100644 --- a/tests/mockserver/internal/sdk/models/components/feedrequest.go +++ b/tests/mockserver/internal/sdk/models/components/feedrequest.go @@ -64,6 +64,8 @@ const ( FeedRequestCategoryShareArtifact FeedRequestCategory = "SHARE_ARTIFACT" FeedRequestCategoryCreateAgent FeedRequestCategory = "CREATE_AGENT" FeedRequestCategoryManagerInvite FeedRequestCategory = "MANAGER_INVITE" + FeedRequestCategoryOnboardingAuthorization FeedRequestCategory = "ONBOARDING_AUTHORIZATION" + FeedRequestCategoryChatReminder FeedRequestCategory = "CHAT_REMINDER" ) func (e FeedRequestCategory) ToPointer() *FeedRequestCategory { @@ -182,6 +184,10 @@ func (e *FeedRequestCategory) UnmarshalJSON(data []byte) error { case "CREATE_AGENT": fallthrough case "MANAGER_INVITE": + fallthrough + case "ONBOARDING_AUTHORIZATION": + fallthrough + case "CHAT_REMINDER": *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 4d9a33d3..e2417ff8 100644 --- a/tests/mockserver/internal/sdk/models/components/feedresult.go +++ b/tests/mockserver/internal/sdk/models/components/feedresult.go @@ -65,6 +65,8 @@ const ( FeedResultCategoryShareArtifact FeedResultCategory = "SHARE_ARTIFACT" FeedResultCategoryCreateAgent FeedResultCategory = "CREATE_AGENT" FeedResultCategoryManagerInvite FeedResultCategory = "MANAGER_INVITE" + FeedResultCategoryOnboardingAuthorization FeedResultCategory = "ONBOARDING_AUTHORIZATION" + FeedResultCategoryChatReminder FeedResultCategory = "CHAT_REMINDER" ) func (e FeedResultCategory) ToPointer() *FeedResultCategory { @@ -183,6 +185,10 @@ func (e *FeedResultCategory) UnmarshalJSON(data []byte) error { case "CREATE_AGENT": fallthrough case "MANAGER_INVITE": + fallthrough + case "ONBOARDING_AUTHORIZATION": + fallthrough + case "CHAT_REMINDER": *e = FeedResultCategory(v) return nil default: diff --git a/tests/mockserver/internal/sdk/models/components/mcpauthmethodbreakdown.go b/tests/mockserver/internal/sdk/models/components/mcpauthmethodbreakdown.go new file mode 100644 index 00000000..31f4103f --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/mcpauthmethodbreakdown.go @@ -0,0 +1,42 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +type McpAuthMethodBreakdown struct { + // Authentication method the MCP client presented, for example OAUTH_GLEAN, OAUTH_XAA (Cross App Access), or API_TOKEN. + AuthMethod *string `json:"authMethod,omitempty"` + // Total number of MCP calls for this authentication method in the specified time period. + TotalCalls *int64 `json:"totalCalls,omitempty"` + // Total number of active users for this authentication method in the specified time period. + ActiveUsers *int64 `json:"activeUsers,omitempty"` + // Host applications using this authentication method in the specified time period. + HostApplications []string `json:"hostApplications,omitempty"` +} + +func (o *McpAuthMethodBreakdown) GetAuthMethod() *string { + if o == nil { + return nil + } + return o.AuthMethod +} + +func (o *McpAuthMethodBreakdown) GetTotalCalls() *int64 { + if o == nil { + return nil + } + return o.TotalCalls +} + +func (o *McpAuthMethodBreakdown) GetActiveUsers() *int64 { + if o == nil { + return nil + } + return o.ActiveUsers +} + +func (o *McpAuthMethodBreakdown) GetHostApplications() []string { + if o == nil { + return nil + } + return o.HostApplications +} diff --git a/tests/mockserver/internal/sdk/models/components/mcpbreakdowninsightsrequest.go b/tests/mockserver/internal/sdk/models/components/mcpbreakdowninsightsrequest.go index ef9a081c..4c60272b 100644 --- a/tests/mockserver/internal/sdk/models/components/mcpbreakdowninsightsrequest.go +++ b/tests/mockserver/internal/sdk/models/components/mcpbreakdowninsightsrequest.go @@ -15,6 +15,7 @@ const ( BreakdownTypeHostApplications BreakdownType = "HOST_APPLICATIONS" BreakdownTypeTools BreakdownType = "TOOLS" BreakdownTypeServers BreakdownType = "SERVERS" + BreakdownTypeAuthMethods BreakdownType = "AUTH_METHODS" ) func (e BreakdownType) ToPointer() *BreakdownType { @@ -33,6 +34,8 @@ func (e *BreakdownType) UnmarshalJSON(data []byte) error { case "TOOLS": fallthrough case "SERVERS": + fallthrough + case "AUTH_METHODS": *e = BreakdownType(v) return nil default: @@ -56,6 +59,8 @@ type McpBreakdownInsightsRequest struct { Tools []string `json:"tools,omitempty"` // MCP servers to filter by. Empty array means all servers. Servers []string `json:"servers,omitempty"` + // Authentication methods to filter by, for example OAUTH_XAA for Cross App Access traffic. Empty array means all authentication methods. + AuthMethods []string `json:"authMethods,omitempty"` } func (o *McpBreakdownInsightsRequest) GetDepartments() []string { @@ -113,3 +118,10 @@ func (o *McpBreakdownInsightsRequest) GetServers() []string { } return o.Servers } + +func (o *McpBreakdownInsightsRequest) GetAuthMethods() []string { + if o == nil { + return nil + } + return o.AuthMethods +} diff --git a/tests/mockserver/internal/sdk/models/components/mcpbreakdowninsightsresponse.go b/tests/mockserver/internal/sdk/models/components/mcpbreakdowninsightsresponse.go index 8ae55f17..2383c4ea 100644 --- a/tests/mockserver/internal/sdk/models/components/mcpbreakdowninsightsresponse.go +++ b/tests/mockserver/internal/sdk/models/components/mcpbreakdowninsightsresponse.go @@ -7,6 +7,7 @@ type McpBreakdownInsightsResponse struct { HostApplicationsBreakdown []McpHostApplicationBreakdown `json:"hostApplicationsBreakdown,omitempty"` ToolsBreakdown []McpToolBreakdown `json:"toolsBreakdown,omitempty"` ServersBreakdown []McpServerBreakdown `json:"serversBreakdown,omitempty"` + AuthMethodsBreakdown []McpAuthMethodBreakdown `json:"authMethodsBreakdown,omitempty"` } func (o *McpBreakdownInsightsResponse) GetUsersBreakdown() []McpUserBreakdown { @@ -36,3 +37,10 @@ func (o *McpBreakdownInsightsResponse) GetServersBreakdown() []McpServerBreakdow } return o.ServersBreakdown } + +func (o *McpBreakdownInsightsResponse) GetAuthMethodsBreakdown() []McpAuthMethodBreakdown { + if o == nil { + return nil + } + return o.AuthMethodsBreakdown +} diff --git a/tests/mockserver/internal/sdk/models/components/mcpuserbreakdown.go b/tests/mockserver/internal/sdk/models/components/mcpuserbreakdown.go index 73014b6f..045685a2 100644 --- a/tests/mockserver/internal/sdk/models/components/mcpuserbreakdown.go +++ b/tests/mockserver/internal/sdk/models/components/mcpuserbreakdown.go @@ -12,6 +12,8 @@ type McpUserBreakdown struct { Tools []string `json:"tools,omitempty"` // MCP servers used by this user in the specified time period. Servers []string `json:"servers,omitempty"` + // Authentication methods this user's MCP clients presented in the specified time period, for example OAUTH_XAA for Cross App Access. + AuthMethods []string `json:"authMethods,omitempty"` } func (o *McpUserBreakdown) GetPerson() *Person { @@ -48,3 +50,10 @@ func (o *McpUserBreakdown) GetServers() []string { } return o.Servers } + +func (o *McpUserBreakdown) GetAuthMethods() []string { + if o == nil { + return nil + } + return o.AuthMethods +} diff --git a/tests/mockserver/internal/sdk/models/components/peoplerequest.go b/tests/mockserver/internal/sdk/models/components/peoplerequest.go index 1240c00e..4d75414b 100644 --- a/tests/mockserver/internal/sdk/models/components/peoplerequest.go +++ b/tests/mockserver/internal/sdk/models/components/peoplerequest.go @@ -5,6 +5,7 @@ package components import ( "encoding/json" "fmt" + "mockserver/internal/sdk/utils" ) type PeopleRequestIncludeField string @@ -84,6 +85,8 @@ func (e *IncludeType) UnmarshalJSON(data []byte) error { } type PeopleRequest struct { + // If true and the current user's people profile is missing, reads the stored SSO profile and returns a minimal Person with its display name, the authenticated user's email, the same obfuscatedId used by a normal self-lookup, and identityOnly set to true. If the SSO profile or its name is unavailable, preserves the missing-profile error. Applies only when emailIds and obfuscatedIds are empty and the request doesn't use act-as, a virtual identity, anonymous authentication, or the INVALID_ENTITIES includeType. The fallback doesn't mask lookup or enrichment errors and doesn't create a directory profile. Normal people profiles don't require an SSO lookup. + FallbackToAuthenticatedIdentity *bool `default:"false" json:"fallbackToAuthenticatedIdentity"` // The offset of the client's timezone in minutes from UTC. e.g. PDT is -420 because it's 7 hours behind UTC. TimezoneOffset *int64 `json:"timezoneOffset,omitempty"` // The Person IDs to retrieve. If no IDs are requested, the current user's details are returned. @@ -98,6 +101,24 @@ type PeopleRequest struct { Source *string `json:"source,omitempty"` } +func (p PeopleRequest) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PeopleRequest) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, nil); err != nil { + return err + } + return nil +} + +func (o *PeopleRequest) GetFallbackToAuthenticatedIdentity() *bool { + if o == nil { + return nil + } + return o.FallbackToAuthenticatedIdentity +} + func (o *PeopleRequest) GetTimezoneOffset() *int64 { if o == nil { return nil diff --git a/tests/mockserver/internal/sdk/models/components/person.go b/tests/mockserver/internal/sdk/models/components/person.go index ab2c5f86..e3bd9441 100644 --- a/tests/mockserver/internal/sdk/models/components/person.go +++ b/tests/mockserver/internal/sdk/models/components/person.go @@ -11,6 +11,8 @@ type Person struct { Name string `json:"name"` // An opaque identifier that can be used to request metadata for a Person. ObfuscatedID string `json:"obfuscatedId"` + // True when this is an authenticated identity fallback rather than a people profile. Directory metadata is unavailable. + IdentityOnly *bool `json:"identityOnly,omitempty"` // A list of documents related to this person. RelatedDocuments []RelatedDocuments `json:"relatedDocuments,omitempty"` Metadata *PersonMetadata `json:"metadata,omitempty"` @@ -41,6 +43,13 @@ func (o *Person) GetObfuscatedID() string { return o.ObfuscatedID } +func (o *Person) GetIdentityOnly() *bool { + if o == nil { + return nil + } + return o.IdentityOnly +} + func (o *Person) GetRelatedDocuments() []RelatedDocuments { if o == nil { return nil diff --git a/tests/mockserver/internal/sdk/models/components/platformagentrequestcreate.go b/tests/mockserver/internal/sdk/models/components/platformagentrequestcreate.go new file mode 100644 index 00000000..3f011c1a --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformagentrequestcreate.go @@ -0,0 +1,34 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +// PlatformAgentRequestCreate - New client-scoped request for an editable agent in the server's current UTC month. +type PlatformAgentRequestCreate struct { + // Identifier of the agent whose limit the request concerns. + AgentID string `json:"agent_id"` + // Explicit spend client whose limit the request concerns. + ClientID string `json:"client_id"` + // Optional explanation of why the increase is needed. + BusinessJustification *string `json:"business_justification,omitempty"` +} + +func (o *PlatformAgentRequestCreate) GetAgentID() string { + if o == nil { + return "" + } + return o.AgentID +} + +func (o *PlatformAgentRequestCreate) GetClientID() string { + if o == nil { + return "" + } + return o.ClientID +} + +func (o *PlatformAgentRequestCreate) GetBusinessJustification() *string { + if o == nil { + return nil + } + return o.BusinessJustification +} diff --git a/tests/mockserver/internal/sdk/models/components/platformauthenticationsuggestion.go b/tests/mockserver/internal/sdk/models/components/platformauthenticationsuggestion.go index 58281ae6..30dae6db 100644 --- a/tests/mockserver/internal/sdk/models/components/platformauthenticationsuggestion.go +++ b/tests/mockserver/internal/sdk/models/components/platformauthenticationsuggestion.go @@ -2,6 +2,10 @@ package components +import ( + "mockserver/internal/sdk/utils" +) + // PlatformAuthenticationSuggestion - One tool the caller must authorize before the agent can run. type PlatformAuthenticationSuggestion struct { // Human-readable tool name. @@ -10,6 +14,17 @@ type PlatformAuthenticationSuggestion struct { ServerID string `json:"server_id"` } +func (p PlatformAuthenticationSuggestion) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformAuthenticationSuggestion) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"server_id"}); err != nil { + return err + } + return nil +} + func (o *PlatformAuthenticationSuggestion) GetToolName() *string { if o == nil { return nil diff --git a/tests/mockserver/internal/sdk/models/components/platformlimitincreaserequest.go b/tests/mockserver/internal/sdk/models/components/platformlimitincreaserequest.go new file mode 100644 index 00000000..393f1ceb --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformlimitincreaserequest.go @@ -0,0 +1,197 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" + "mockserver/internal/sdk/utils" + "time" +) + +// PlatformLimitIncreaseRequestEntityType - Whether the request concerns a user or an agent. +type PlatformLimitIncreaseRequestEntityType string + +const ( + PlatformLimitIncreaseRequestEntityTypeUser PlatformLimitIncreaseRequestEntityType = "USER" + PlatformLimitIncreaseRequestEntityTypeAgent PlatformLimitIncreaseRequestEntityType = "AGENT" +) + +func (e PlatformLimitIncreaseRequestEntityType) ToPointer() *PlatformLimitIncreaseRequestEntityType { + return &e +} +func (e *PlatformLimitIncreaseRequestEntityType) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "USER": + fallthrough + case "AGENT": + *e = PlatformLimitIncreaseRequestEntityType(v) + return nil + default: + return fmt.Errorf("invalid value for PlatformLimitIncreaseRequestEntityType: %v", v) + } +} + +// PlatformLimitIncreaseRequest - Stored user or agent request, with optional resolution fields when available. +type PlatformLimitIncreaseRequest struct { + // Server-assigned resource identifier, distinct from the response's trace request_id. + RequestID string `json:"request_id"` + // Whether the request concerns a user or an agent. + EntityType PlatformLimitIncreaseRequestEntityType `json:"entity_type"` + // Canonical user ID or agent ID whose limit the request concerns. + EntityID string `json:"entity_id"` + // Spend client for this user or agent request. + ClientID string `json:"client_id"` + // Authenticated user who created the request. + RequesterUserID string `json:"requester_user_id"` + // Stored explanation of why the increase is needed, when supplied. + BusinessJustification *string `json:"business_justification,omitempty"` + // UTC calendar month in YYYY-MM format, assigned by the server at creation. + Period string `json:"period"` + // Stored request state. + Status PlatformRequestStatus `json:"status"` + // User who resolved the request, when available. + ResolvedByUserID *string `json:"resolved_by_user_id,omitempty"` + // Positive additive increase in the applicable rule's denomination, encoded as a plain decimal string. The backend stores float32 values, not arbitrary-precision decimals. + // + ApprovedIncreaseAmount *string `json:"approved_increase_amount,omitempty"` + // Increase for the stored request month or an ongoing standing-rule increase. + Scope *PlatformRequestScope `json:"scope,omitempty"` + // Breadth of the approved increase; GROUP identifies an IdP group. + ResolutionTarget *PlatformRequestResolutionTarget `json:"resolution_target,omitempty"` + // Stored department or canonical IdP group ID, when available. + ResolutionTargetID *string `json:"resolution_target_id,omitempty"` + // Stored denial note, when supplied. + ResolutionNote *string `json:"resolution_note,omitempty"` + // Request creation time. + CreatedAt time.Time `json:"created_at"` + // Last stored update time; this is the resolution time for resolved requests. + UpdatedAt *time.Time `json:"updated_at,omitempty"` +} + +func (p PlatformLimitIncreaseRequest) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformLimitIncreaseRequest) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"request_id", "entity_type", "entity_id", "client_id", "requester_user_id", "period", "status", "created_at"}); err != nil { + return err + } + return nil +} + +func (o *PlatformLimitIncreaseRequest) GetRequestID() string { + if o == nil { + return "" + } + return o.RequestID +} + +func (o *PlatformLimitIncreaseRequest) GetEntityType() PlatformLimitIncreaseRequestEntityType { + if o == nil { + return PlatformLimitIncreaseRequestEntityType("") + } + return o.EntityType +} + +func (o *PlatformLimitIncreaseRequest) GetEntityID() string { + if o == nil { + return "" + } + return o.EntityID +} + +func (o *PlatformLimitIncreaseRequest) GetClientID() string { + if o == nil { + return "" + } + return o.ClientID +} + +func (o *PlatformLimitIncreaseRequest) GetRequesterUserID() string { + if o == nil { + return "" + } + return o.RequesterUserID +} + +func (o *PlatformLimitIncreaseRequest) GetBusinessJustification() *string { + if o == nil { + return nil + } + return o.BusinessJustification +} + +func (o *PlatformLimitIncreaseRequest) GetPeriod() string { + if o == nil { + return "" + } + return o.Period +} + +func (o *PlatformLimitIncreaseRequest) GetStatus() PlatformRequestStatus { + if o == nil { + return PlatformRequestStatus("") + } + return o.Status +} + +func (o *PlatformLimitIncreaseRequest) GetResolvedByUserID() *string { + if o == nil { + return nil + } + return o.ResolvedByUserID +} + +func (o *PlatformLimitIncreaseRequest) GetApprovedIncreaseAmount() *string { + if o == nil { + return nil + } + return o.ApprovedIncreaseAmount +} + +func (o *PlatformLimitIncreaseRequest) GetScope() *PlatformRequestScope { + if o == nil { + return nil + } + return o.Scope +} + +func (o *PlatformLimitIncreaseRequest) GetResolutionTarget() *PlatformRequestResolutionTarget { + if o == nil { + return nil + } + return o.ResolutionTarget +} + +func (o *PlatformLimitIncreaseRequest) GetResolutionTargetID() *string { + if o == nil { + return nil + } + return o.ResolutionTargetID +} + +func (o *PlatformLimitIncreaseRequest) GetResolutionNote() *string { + if o == nil { + return nil + } + return o.ResolutionNote +} + +func (o *PlatformLimitIncreaseRequest) GetCreatedAt() time.Time { + if o == nil { + return time.Time{} + } + return o.CreatedAt +} + +func (o *PlatformLimitIncreaseRequest) GetUpdatedAt() *time.Time { + if o == nil { + return nil + } + return o.UpdatedAt +} diff --git a/tests/mockserver/internal/sdk/models/components/platformlimitincreaserequestsettings.go b/tests/mockserver/internal/sdk/models/components/platformlimitincreaserequestsettings.go new file mode 100644 index 00000000..90402268 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformlimitincreaserequestsettings.go @@ -0,0 +1,61 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" + "mockserver/internal/sdk/utils" +) + +// BusinessJustification - Whether a business justification is required when requesting a usage limit increase. +type BusinessJustification string + +const ( + BusinessJustificationOptional BusinessJustification = "OPTIONAL" + BusinessJustificationRequired BusinessJustification = "REQUIRED" +) + +func (e BusinessJustification) ToPointer() *BusinessJustification { + return &e +} +func (e *BusinessJustification) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "OPTIONAL": + fallthrough + case "REQUIRED": + *e = BusinessJustification(v) + return nil + default: + return fmt.Errorf("invalid value for BusinessJustification: %v", v) + } +} + +// PlatformLimitIncreaseRequestSettings - Settings that govern usage limit increase requests. +type PlatformLimitIncreaseRequestSettings struct { + // Whether a business justification is required when requesting a usage limit increase. + // + BusinessJustification BusinessJustification `json:"business_justification"` +} + +func (p PlatformLimitIncreaseRequestSettings) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformLimitIncreaseRequestSettings) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"business_justification"}); err != nil { + return err + } + return nil +} + +func (o *PlatformLimitIncreaseRequestSettings) GetBusinessJustification() BusinessJustification { + if o == nil { + return BusinessJustification("") + } + return o.BusinessJustification +} diff --git a/tests/mockserver/internal/sdk/models/components/platformmultiplemembershipresolutionsettings.go b/tests/mockserver/internal/sdk/models/components/platformmultiplemembershipresolutionsettings.go new file mode 100644 index 00000000..53a3c4a0 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformmultiplemembershipresolutionsettings.go @@ -0,0 +1,31 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "mockserver/internal/sdk/utils" +) + +// PlatformMultipleMembershipResolutionSettings - Settings for resolving limits across multiple memberships. +type PlatformMultipleMembershipResolutionSettings struct { + // Resolution settings for the per-member limit family. + PerMember PlatformPerMemberSettings `json:"per_member"` +} + +func (p PlatformMultipleMembershipResolutionSettings) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformMultipleMembershipResolutionSettings) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"per_member"}); err != nil { + return err + } + return nil +} + +func (o *PlatformMultipleMembershipResolutionSettings) GetPerMember() PlatformPerMemberSettings { + if o == nil { + return PlatformPerMemberSettings{} + } + return o.PerMember +} diff --git a/tests/mockserver/internal/sdk/models/components/platformpermembersettings.go b/tests/mockserver/internal/sdk/models/components/platformpermembersettings.go new file mode 100644 index 00000000..f28f77cb --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformpermembersettings.go @@ -0,0 +1,61 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" + "mockserver/internal/sdk/utils" +) + +// IdpGroups - How to resolve effective usage limits when a user belongs to multiple IdP groups. +type IdpGroups string + +const ( + IdpGroupsHighest IdpGroups = "HIGHEST" + IdpGroupsLowest IdpGroups = "LOWEST" +) + +func (e IdpGroups) ToPointer() *IdpGroups { + return &e +} +func (e *IdpGroups) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "HIGHEST": + fallthrough + case "LOWEST": + *e = IdpGroups(v) + return nil + default: + return fmt.Errorf("invalid value for IdpGroups: %v", v) + } +} + +// PlatformPerMemberSettings - Resolution settings for the per-member limit family. +type PlatformPerMemberSettings struct { + // How to resolve effective usage limits when a user belongs to multiple IdP groups. + // + IdpGroups IdpGroups `json:"idp_groups"` +} + +func (p PlatformPerMemberSettings) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformPerMemberSettings) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"idp_groups"}); err != nil { + return err + } + return nil +} + +func (o *PlatformPerMemberSettings) GetIdpGroups() IdpGroups { + if o == nil { + return IdpGroups("") + } + return o.IdpGroups +} diff --git a/tests/mockserver/internal/sdk/models/components/platformpersonalrequestcreate.go b/tests/mockserver/internal/sdk/models/components/platformpersonalrequestcreate.go new file mode 100644 index 00000000..0ce82dd3 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformpersonalrequestcreate.go @@ -0,0 +1,25 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +// PlatformPersonalRequestCreate - New request for the authenticated canonical user in the server's current UTC month. +type PlatformPersonalRequestCreate struct { + // Explicit spend client whose limit the request concerns. + ClientID string `json:"client_id"` + // Optional explanation of why the increase is needed. + BusinessJustification *string `json:"business_justification,omitempty"` +} + +func (o *PlatformPersonalRequestCreate) GetClientID() string { + if o == nil { + return "" + } + return o.ClientID +} + +func (o *PlatformPersonalRequestCreate) GetBusinessJustification() *string { + if o == nil { + return nil + } + return o.BusinessJustification +} diff --git a/tests/mockserver/internal/sdk/models/components/platformproblemdetail.go b/tests/mockserver/internal/sdk/models/components/platformproblemdetail.go new file mode 100644 index 00000000..f4cb5aa3 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformproblemdetail.go @@ -0,0 +1,94 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "mockserver/internal/sdk/utils" +) + +// PlatformProblemDetail - Error response following RFC 9457, extended with `code` and `documentation_url` for machine-readable classification and self-service remediation. +type PlatformProblemDetail struct { + // URI identifying the error type. + Type string `json:"type"` + // Short, human-readable summary of the error. + Title string `json:"title"` + // HTTP status code mirrored from the response. + Status int64 `json:"status"` + // Human-readable explanation specific to this occurrence. + Detail string `json:"detail"` + // Stable machine-readable error code. + Code PlatformProblemDetailCode `json:"code"` + // Direct URL to documentation for this error code. + DocumentationURL *string `json:"documentation_url,omitempty"` + // Platform-generated request ID for support correlation. + RequestID string `json:"request_id"` + // Field-level validation problems, one entry per offending field. + Errors []PlatformProblemDetailError `json:"errors,omitempty"` +} + +func (p PlatformProblemDetail) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformProblemDetail) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"type", "title", "status", "detail", "code", "request_id"}); err != nil { + return err + } + return nil +} + +func (o *PlatformProblemDetail) GetType() string { + if o == nil { + return "" + } + return o.Type +} + +func (o *PlatformProblemDetail) GetTitle() string { + if o == nil { + return "" + } + return o.Title +} + +func (o *PlatformProblemDetail) GetStatus() int64 { + if o == nil { + return 0 + } + return o.Status +} + +func (o *PlatformProblemDetail) GetDetail() string { + if o == nil { + return "" + } + return o.Detail +} + +func (o *PlatformProblemDetail) GetCode() PlatformProblemDetailCode { + if o == nil { + return PlatformProblemDetailCode("") + } + return o.Code +} + +func (o *PlatformProblemDetail) GetDocumentationURL() *string { + if o == nil { + return nil + } + return o.DocumentationURL +} + +func (o *PlatformProblemDetail) GetRequestID() string { + if o == nil { + return "" + } + return o.RequestID +} + +func (o *PlatformProblemDetail) GetErrors() []PlatformProblemDetailError { + if o == nil { + return nil + } + return o.Errors +} diff --git a/tests/mockserver/internal/sdk/models/components/platformproblemdetailerror.go b/tests/mockserver/internal/sdk/models/components/platformproblemdetailerror.go index 058f5e62..e013d644 100644 --- a/tests/mockserver/internal/sdk/models/components/platformproblemdetailerror.go +++ b/tests/mockserver/internal/sdk/models/components/platformproblemdetailerror.go @@ -2,6 +2,10 @@ package components +import ( + "mockserver/internal/sdk/utils" +) + // PlatformProblemDetailError - Field-level validation problem for a single offending field. type PlatformProblemDetailError struct { // RFC 6901 JSON Pointer to the offending field. @@ -12,6 +16,17 @@ type PlatformProblemDetailError struct { Code *PlatformProblemDetailCode `json:"code,omitempty"` } +func (p PlatformProblemDetailError) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformProblemDetailError) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"pointer", "detail"}); err != nil { + return err + } + return nil +} + func (o *PlatformProblemDetailError) GetPointer() string { if o == nil { return "" diff --git a/tests/mockserver/internal/sdk/models/components/platformrequestfilter.go b/tests/mockserver/internal/sdk/models/components/platformrequestfilter.go new file mode 100644 index 00000000..c5e00543 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformrequestfilter.go @@ -0,0 +1,90 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" + "mockserver/internal/sdk/utils" +) + +// Operator - Only EQUALS is supported; defaults to EQUALS when omitted. +type Operator string + +const ( + OperatorEquals Operator = "EQUALS" + OperatorNotEquals Operator = "NOT_EQUALS" + OperatorGt Operator = "GT" + OperatorGte Operator = "GTE" + OperatorLt Operator = "LT" + OperatorLte Operator = "LTE" +) + +func (e Operator) ToPointer() *Operator { + return &e +} +func (e *Operator) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "EQUALS": + fallthrough + case "NOT_EQUALS": + fallthrough + case "GT": + fallthrough + case "GTE": + fallthrough + case "LT": + fallthrough + case "LTE": + *e = Operator(v) + return nil + default: + return fmt.Errorf("invalid value for Operator: %v", v) + } +} + +// PlatformRequestFilter - A status filter using the backend's status-IN matching. +type PlatformRequestFilter struct { + // Allowed field is status, spelled exactly in lowercase. + Field string `json:"field"` + // Status values to match with OR. + Values []PlatformRequestStatus `json:"values"` + // Only EQUALS is supported; defaults to EQUALS when omitted. + Operator *Operator `default:"EQUALS" json:"operator"` +} + +func (p PlatformRequestFilter) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformRequestFilter) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"field", "values"}); err != nil { + return err + } + return nil +} + +func (o *PlatformRequestFilter) GetField() string { + if o == nil { + return "" + } + return o.Field +} + +func (o *PlatformRequestFilter) GetValues() []PlatformRequestStatus { + if o == nil { + return []PlatformRequestStatus{} + } + return o.Values +} + +func (o *PlatformRequestFilter) GetOperator() *Operator { + if o == nil { + return nil + } + return o.Operator +} diff --git a/tests/mockserver/internal/sdk/models/components/platformrequestlistresponseunion.go b/tests/mockserver/internal/sdk/models/components/platformrequestlistresponseunion.go new file mode 100644 index 00000000..56769fc9 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformrequestlistresponseunion.go @@ -0,0 +1,176 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "errors" + "fmt" + "mockserver/internal/sdk/optionalnullable" + "mockserver/internal/sdk/utils" +) + +// PlatformRequestListResponse2 - The last page has no continuation cursor. +type PlatformRequestListResponse2 struct { + // Whether a further page is available through next_cursor. + HasMore bool `json:"has_more"` + // Opaque nonempty continuation when has_more is true; null or omitted otherwise. + NextCursor optionalnullable.OptionalNullable[string] `json:"next_cursor,omitempty"` + // Requests visible to the caller under the current filters and authorization. + Results []PlatformLimitIncreaseRequest `json:"results"` + // Trace identifier for this list response, not a request resource ID. + RequestID string `json:"request_id"` +} + +func (p PlatformRequestListResponse2) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformRequestListResponse2) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"has_more", "results", "request_id"}); err != nil { + return err + } + return nil +} + +func (o *PlatformRequestListResponse2) GetHasMore() bool { + if o == nil { + return false + } + return o.HasMore +} + +func (o *PlatformRequestListResponse2) GetNextCursor() optionalnullable.OptionalNullable[string] { + if o == nil { + return nil + } + return o.NextCursor +} + +func (o *PlatformRequestListResponse2) GetResults() []PlatformLimitIncreaseRequest { + if o == nil { + return []PlatformLimitIncreaseRequest{} + } + return o.Results +} + +func (o *PlatformRequestListResponse2) GetRequestID() string { + if o == nil { + return "" + } + return o.RequestID +} + +// PlatformRequestListResponse1 - A further page requires a usable continuation cursor. +type PlatformRequestListResponse1 struct { + // Whether a further page is available through next_cursor. + HasMore bool `json:"has_more"` + // Opaque nonempty continuation when has_more is true; null or omitted otherwise. + NextCursor *string `json:"next_cursor"` + // Requests visible to the caller under the current filters and authorization. + Results []PlatformLimitIncreaseRequest `json:"results"` + // Trace identifier for this list response, not a request resource ID. + RequestID string `json:"request_id"` +} + +func (p PlatformRequestListResponse1) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformRequestListResponse1) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"has_more", "next_cursor", "results", "request_id"}); err != nil { + return err + } + return nil +} + +func (o *PlatformRequestListResponse1) GetHasMore() bool { + if o == nil { + return false + } + return o.HasMore +} + +func (o *PlatformRequestListResponse1) GetNextCursor() *string { + if o == nil { + return nil + } + return o.NextCursor +} + +func (o *PlatformRequestListResponse1) GetResults() []PlatformLimitIncreaseRequest { + if o == nil { + return []PlatformLimitIncreaseRequest{} + } + return o.Results +} + +func (o *PlatformRequestListResponse1) GetRequestID() string { + if o == nil { + return "" + } + return o.RequestID +} + +type PlatformRequestListResponseUnionType string + +const ( + PlatformRequestListResponseUnionTypePlatformRequestListResponse1 PlatformRequestListResponseUnionType = "PlatformRequestListResponse_1" + PlatformRequestListResponseUnionTypePlatformRequestListResponse2 PlatformRequestListResponseUnionType = "PlatformRequestListResponse_2" +) + +// PlatformRequestListResponseUnion - Bounded page of authorized requests with opaque continuation state. +type PlatformRequestListResponseUnion struct { + PlatformRequestListResponse1 *PlatformRequestListResponse1 `queryParam:"inline"` + PlatformRequestListResponse2 *PlatformRequestListResponse2 `queryParam:"inline"` + + Type PlatformRequestListResponseUnionType +} + +func CreatePlatformRequestListResponseUnionPlatformRequestListResponse1(platformRequestListResponse1 PlatformRequestListResponse1) PlatformRequestListResponseUnion { + typ := PlatformRequestListResponseUnionTypePlatformRequestListResponse1 + + return PlatformRequestListResponseUnion{ + PlatformRequestListResponse1: &platformRequestListResponse1, + Type: typ, + } +} + +func CreatePlatformRequestListResponseUnionPlatformRequestListResponse2(platformRequestListResponse2 PlatformRequestListResponse2) PlatformRequestListResponseUnion { + typ := PlatformRequestListResponseUnionTypePlatformRequestListResponse2 + + return PlatformRequestListResponseUnion{ + PlatformRequestListResponse2: &platformRequestListResponse2, + Type: typ, + } +} + +func (u *PlatformRequestListResponseUnion) UnmarshalJSON(data []byte) error { + + var platformRequestListResponse1 PlatformRequestListResponse1 = PlatformRequestListResponse1{} + if err := utils.UnmarshalJSON(data, &platformRequestListResponse1, "", true, nil); err == nil { + u.PlatformRequestListResponse1 = &platformRequestListResponse1 + u.Type = PlatformRequestListResponseUnionTypePlatformRequestListResponse1 + return nil + } + + var platformRequestListResponse2 PlatformRequestListResponse2 = PlatformRequestListResponse2{} + if err := utils.UnmarshalJSON(data, &platformRequestListResponse2, "", true, nil); err == nil { + u.PlatformRequestListResponse2 = &platformRequestListResponse2 + u.Type = PlatformRequestListResponseUnionTypePlatformRequestListResponse2 + return nil + } + + return fmt.Errorf("could not unmarshal `%s` into any supported union types for PlatformRequestListResponseUnion", string(data)) +} + +func (u PlatformRequestListResponseUnion) MarshalJSON() ([]byte, error) { + if u.PlatformRequestListResponse1 != nil { + return utils.MarshalJSON(u.PlatformRequestListResponse1, "", true) + } + + if u.PlatformRequestListResponse2 != nil { + return utils.MarshalJSON(u.PlatformRequestListResponse2, "", true) + } + + return nil, errors.New("could not marshal union type PlatformRequestListResponseUnion: all fields are null") +} diff --git a/tests/mockserver/internal/sdk/models/components/platformrequestresolutiontarget.go b/tests/mockserver/internal/sdk/models/components/platformrequestresolutiontarget.go new file mode 100644 index 00000000..59492e1e --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformrequestresolutiontarget.go @@ -0,0 +1,41 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" +) + +// PlatformRequestResolutionTarget - Breadth of the approved increase; GROUP identifies an IdP group. +type PlatformRequestResolutionTarget string + +const ( + PlatformRequestResolutionTargetUser PlatformRequestResolutionTarget = "USER" + PlatformRequestResolutionTargetAll PlatformRequestResolutionTarget = "ALL" + PlatformRequestResolutionTargetDepartment PlatformRequestResolutionTarget = "DEPARTMENT" + PlatformRequestResolutionTargetGroup PlatformRequestResolutionTarget = "GROUP" +) + +func (e PlatformRequestResolutionTarget) ToPointer() *PlatformRequestResolutionTarget { + return &e +} +func (e *PlatformRequestResolutionTarget) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "USER": + fallthrough + case "ALL": + fallthrough + case "DEPARTMENT": + fallthrough + case "GROUP": + *e = PlatformRequestResolutionTarget(v) + return nil + default: + return fmt.Errorf("invalid value for PlatformRequestResolutionTarget: %v", v) + } +} diff --git a/tests/mockserver/internal/sdk/models/components/platformrequestresponse.go b/tests/mockserver/internal/sdk/models/components/platformrequestresponse.go new file mode 100644 index 00000000..2c168309 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformrequestresponse.go @@ -0,0 +1,25 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +// PlatformRequestResponse - Single authorized request with the enclosing response's trace identifier. +type PlatformRequestResponse struct { + // Stored user or agent request, with optional resolution fields when available. + Request PlatformLimitIncreaseRequest `json:"request"` + // Trace identifier, distinct from the resource ID. + RequestID string `json:"request_id"` +} + +func (o *PlatformRequestResponse) GetRequest() PlatformLimitIncreaseRequest { + if o == nil { + return PlatformLimitIncreaseRequest{} + } + return o.Request +} + +func (o *PlatformRequestResponse) GetRequestID() string { + if o == nil { + return "" + } + return o.RequestID +} diff --git a/tests/mockserver/internal/sdk/models/components/platformrequestscope.go b/tests/mockserver/internal/sdk/models/components/platformrequestscope.go new file mode 100644 index 00000000..a032d93a --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformrequestscope.go @@ -0,0 +1,35 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" +) + +// PlatformRequestScope - Increase for the stored request month or an ongoing standing-rule increase. +type PlatformRequestScope string + +const ( + PlatformRequestScopePeriod PlatformRequestScope = "PERIOD" + PlatformRequestScopeOngoing PlatformRequestScope = "ONGOING" +) + +func (e PlatformRequestScope) ToPointer() *PlatformRequestScope { + return &e +} +func (e *PlatformRequestScope) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "PERIOD": + fallthrough + case "ONGOING": + *e = PlatformRequestScope(v) + return nil + default: + return fmt.Errorf("invalid value for PlatformRequestScope: %v", v) + } +} diff --git a/tests/mockserver/internal/sdk/models/components/platformrequeststatus.go b/tests/mockserver/internal/sdk/models/components/platformrequeststatus.go new file mode 100644 index 00000000..e6d3ad94 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformrequeststatus.go @@ -0,0 +1,38 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" +) + +// PlatformRequestStatus - Stored request state. +type PlatformRequestStatus string + +const ( + PlatformRequestStatusPending PlatformRequestStatus = "PENDING" + PlatformRequestStatusApproved PlatformRequestStatus = "APPROVED" + PlatformRequestStatusDenied PlatformRequestStatus = "DENIED" +) + +func (e PlatformRequestStatus) ToPointer() *PlatformRequestStatus { + return &e +} +func (e *PlatformRequestStatus) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "PENDING": + fallthrough + case "APPROVED": + fallthrough + case "DENIED": + *e = PlatformRequestStatus(v) + return nil + default: + return fmt.Errorf("invalid value for PlatformRequestStatus: %v", v) + } +} diff --git a/tests/mockserver/internal/sdk/models/components/platformskill.go b/tests/mockserver/internal/sdk/models/components/platformskill.go index 8397a899..a507f97f 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskill.go +++ b/tests/mockserver/internal/sdk/models/components/platformskill.go @@ -9,7 +9,7 @@ import ( type PlatformSkill struct { // Glean skill ID. - ID string `json:"id"` + SkillID string `json:"skill_id"` // Human-readable skill name. DisplayName string `json:"display_name"` // Human-readable skill description. @@ -18,7 +18,8 @@ type PlatformSkill struct { LatestVersion int64 `json:"latest_version"` // Latest minor version number for the skill. LatestMinorVersion int64 `json:"latest_minor_version"` - // Current skill status. + // The caller's effective activation. The owner sees the skill's stored status. Another caller sees their personal setting, or DISABLED when they have none. DRAFT is the stored draft state and is not set by update. Effective activation may also reflect workspace governance policy. + // Status PlatformSkillStatus `json:"status"` // Source category for the skill. Origin PlatformSkillOrigin `json:"origin"` @@ -36,17 +37,17 @@ func (p PlatformSkill) MarshalJSON() ([]byte, error) { } func (p *PlatformSkill) UnmarshalJSON(data []byte) error { - if err := utils.UnmarshalJSON(data, &p, "", false, []string{"id", "display_name", "description", "latest_version", "latest_minor_version", "status", "origin", "owner", "created_at", "updated_at"}); err != nil { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"skill_id", "display_name", "description", "latest_version", "latest_minor_version", "status", "origin", "owner", "created_at", "updated_at"}); err != nil { return err } return nil } -func (o *PlatformSkill) GetID() string { +func (o *PlatformSkill) GetSkillID() string { if o == nil { return "" } - return o.ID + return o.SkillID } func (o *PlatformSkill) GetDisplayName() string { diff --git a/tests/mockserver/internal/sdk/models/components/platformskillimportresponse.go b/tests/mockserver/internal/sdk/models/components/platformskillimportresponse.go index 262df2a7..796e0f2e 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskillimportresponse.go +++ b/tests/mockserver/internal/sdk/models/components/platformskillimportresponse.go @@ -3,7 +3,8 @@ package components type PlatformSkillImportResponse struct { - // Independently persisted skills in request order. + // Imported skills in request order. The import is atomic: either every source persists or none does. + // Skills []PlatformSkill `json:"skills"` // Platform-generated request ID for support correlation. RequestID string `json:"request_id"` diff --git a/tests/mockserver/internal/sdk/models/components/platformskillorigin.go b/tests/mockserver/internal/sdk/models/components/platformskillorigin.go index e0a00449..1afff274 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskillorigin.go +++ b/tests/mockserver/internal/sdk/models/components/platformskillorigin.go @@ -12,6 +12,7 @@ type PlatformSkillOrigin string const ( PlatformSkillOriginCustom PlatformSkillOrigin = "CUSTOM" + PlatformSkillOriginGithub PlatformSkillOrigin = "GITHUB" ) func (e PlatformSkillOrigin) ToPointer() *PlatformSkillOrigin { @@ -24,6 +25,8 @@ func (e *PlatformSkillOrigin) UnmarshalJSON(data []byte) error { } switch v { case "CUSTOM": + fallthrough + case "GITHUB": *e = PlatformSkillOrigin(v) return nil default: diff --git a/tests/mockserver/internal/sdk/models/components/platformskillslistresponse.go b/tests/mockserver/internal/sdk/models/components/platformskillslistresponse.go index 566d5351..55a8d69a 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskillslistresponse.go +++ b/tests/mockserver/internal/sdk/models/components/platformskillslistresponse.go @@ -4,7 +4,7 @@ package components type PlatformSkillsListResponse struct { // Skills available to the user. - Skills []PlatformSkill `json:"skills"` + Results []PlatformSkill `json:"results"` // Whether additional results are available. HasMore bool `json:"has_more"` // Cursor for the next page, or null when no more results are available. @@ -13,11 +13,11 @@ type PlatformSkillsListResponse struct { RequestID string `json:"request_id"` } -func (o *PlatformSkillsListResponse) GetSkills() []PlatformSkill { +func (o *PlatformSkillsListResponse) GetResults() []PlatformSkill { if o == nil { return []PlatformSkill{} } - return o.Skills + return o.Results } func (o *PlatformSkillsListResponse) GetHasMore() bool { diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreview.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreview.go index f7a467f1..85b419fd 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreview.go +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreview.go @@ -2,6 +2,10 @@ package components +import ( + "mockserver/internal/sdk/utils" +) + type PlatformSkillSourcePreview struct { // Skill name parsed from SKILL.md frontmatter. DisplayName string `json:"display_name"` @@ -19,6 +23,17 @@ type PlatformSkillSourcePreview struct { FileTree []string `json:"file_tree"` } +func (p PlatformSkillSourcePreview) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreview) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"display_name", "description", "source_url", "commit_sha", "main_content", "files", "file_tree"}); err != nil { + return err + } + return nil +} + func (o *PlatformSkillSourcePreview) GetDisplayName() string { if o == nil { return "" diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewfailure.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewfailure.go index 5a6c6fe8..92ed2f8b 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewfailure.go +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewfailure.go @@ -2,6 +2,10 @@ package components +import ( + "mockserver/internal/sdk/utils" +) + type PlatformSkillSourcePreviewFailure struct { // Resolved URL for the entry that could not be previewed. SourceURL string `json:"source_url"` @@ -11,6 +15,17 @@ type PlatformSkillSourcePreviewFailure struct { Detail string `json:"detail"` } +func (p PlatformSkillSourcePreviewFailure) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewFailure) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"source_url", "code", "detail"}); err != nil { + return err + } + return nil +} + func (o *PlatformSkillSourcePreviewFailure) GetSourceURL() string { if o == nil { return "" diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewfile.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewfile.go index 43503cfb..7622555e 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewfile.go +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewfile.go @@ -2,6 +2,10 @@ package components +import ( + "mockserver/internal/sdk/utils" +) + type PlatformSkillSourcePreviewFile struct { // Relative path within the skill bundle. Path string `json:"path"` @@ -9,6 +13,17 @@ type PlatformSkillSourcePreviewFile struct { Content string `json:"content"` } +func (p PlatformSkillSourcePreviewFile) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewFile) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"path", "content"}); err != nil { + return err + } + return nil +} + func (o *PlatformSkillSourcePreviewFile) GetPath() string { if o == nil { return "" diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewrequest.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewrequest.go deleted file mode 100644 index 506e0c09..00000000 --- a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewrequest.go +++ /dev/null @@ -1,39 +0,0 @@ -// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. - -package components - -import ( - "mockserver/internal/sdk/utils" -) - -type PlatformSkillSourcePreviewRequest struct { - // GitHub URL for a skill directory, SKILL.md file, or repository to inspect. - SourceURL string `json:"source_url"` - // Whether to stream repository scan progress using server-sent events. - Stream *bool `default:"false" json:"stream"` -} - -func (p PlatformSkillSourcePreviewRequest) MarshalJSON() ([]byte, error) { - return utils.MarshalJSON(p, "", false) -} - -func (p *PlatformSkillSourcePreviewRequest) UnmarshalJSON(data []byte) error { - if err := utils.UnmarshalJSON(data, &p, "", false, []string{"source_url"}); err != nil { - return err - } - return nil -} - -func (o *PlatformSkillSourcePreviewRequest) GetSourceURL() string { - if o == nil { - return "" - } - return o.SourceURL -} - -func (o *PlatformSkillSourcePreviewRequest) GetStream() *bool { - if o == nil { - return nil - } - return o.Stream -} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewresponse.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewresponse.go index 0607598d..597fec46 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewresponse.go +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewresponse.go @@ -2,6 +2,10 @@ package components +import ( + "mockserver/internal/sdk/utils" +) + type PlatformSkillSourcePreviewResponse struct { // Valid skills discovered at the source URL. Skills []PlatformSkillSourcePreview `json:"skills"` @@ -11,6 +15,17 @@ type PlatformSkillSourcePreviewResponse struct { RequestID string `json:"request_id"` } +func (p PlatformSkillSourcePreviewResponse) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewResponse) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"skills", "failures", "request_id"}); err != nil { + return err + } + return nil +} + func (o *PlatformSkillSourcePreviewResponse) GetSkills() []PlatformSkillSourcePreview { if o == nil { return []PlatformSkillSourcePreview{} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamerror.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamerror.go new file mode 100644 index 00000000..e1b0e86e --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamerror.go @@ -0,0 +1,76 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" + "mockserver/internal/sdk/utils" +) + +// PlatformSkillSourcePreviewStreamErrorType - Event type, also sent as the SSE `event` name. +type PlatformSkillSourcePreviewStreamErrorType string + +const ( + PlatformSkillSourcePreviewStreamErrorTypeError PlatformSkillSourcePreviewStreamErrorType = "ERROR" +) + +func (e PlatformSkillSourcePreviewStreamErrorType) ToPointer() *PlatformSkillSourcePreviewStreamErrorType { + return &e +} +func (e *PlatformSkillSourcePreviewStreamErrorType) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "ERROR": + *e = PlatformSkillSourcePreviewStreamErrorType(v) + return nil + default: + return fmt.Errorf("invalid value for PlatformSkillSourcePreviewStreamErrorType: %v", v) + } +} + +// PlatformSkillSourcePreviewStreamError - Terminal failure event carrying the failure as a problem detail. Most GitHub authorization failures return HTTP 422 before the stream opens. If authorization fails after the stream opens, `error.code` is `tools_unauthorized` and `authentication_suggestions` is present. +type PlatformSkillSourcePreviewStreamError struct { + // Event type, also sent as the SSE `event` name. + Type PlatformSkillSourcePreviewStreamErrorType `json:"type"` + // Error response following RFC 9457, extended with `code` and `documentation_url` for machine-readable classification and self-service remediation. + // + Error PlatformProblemDetail `json:"error"` + // Present only when `error.code` is `tools_unauthorized`. Names the GitHub action pack to authorize, with the same retry flow as the 422 response. + AuthenticationSuggestions []PlatformAuthenticationSuggestion `json:"authentication_suggestions,omitempty"` +} + +func (p PlatformSkillSourcePreviewStreamError) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewStreamError) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"type", "error"}); err != nil { + return err + } + return nil +} + +func (o *PlatformSkillSourcePreviewStreamError) GetType() PlatformSkillSourcePreviewStreamErrorType { + if o == nil { + return PlatformSkillSourcePreviewStreamErrorType("") + } + return o.Type +} + +func (o *PlatformSkillSourcePreviewStreamError) GetError() PlatformProblemDetail { + if o == nil { + return PlatformProblemDetail{} + } + return o.Error +} + +func (o *PlatformSkillSourcePreviewStreamError) GetAuthenticationSuggestions() []PlatformAuthenticationSuggestion { + if o == nil { + return nil + } + return o.AuthenticationSuggestions +} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamerrorserversentevent.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamerrorserversentevent.go new file mode 100644 index 00000000..548ebf7a --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamerrorserversentevent.go @@ -0,0 +1,43 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "mockserver/internal/sdk/utils" +) + +type PlatformSkillSourcePreviewStreamErrorServerSentEvent struct { + ID *string `json:"id,omitempty"` + event string `const:"ERROR" json:"event"` + // Terminal failure event carrying the failure as a problem detail. Most GitHub authorization failures return HTTP 422 before the stream opens. If authorization fails after the stream opens, `error.code` is `tools_unauthorized` and `authentication_suggestions` is present. + Data PlatformSkillSourcePreviewStreamError `json:"data"` +} + +func (p PlatformSkillSourcePreviewStreamErrorServerSentEvent) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewStreamErrorServerSentEvent) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"event", "data"}); err != nil { + return err + } + return nil +} + +func (o *PlatformSkillSourcePreviewStreamErrorServerSentEvent) GetID() *string { + if o == nil { + return nil + } + return o.ID +} + +func (o *PlatformSkillSourcePreviewStreamErrorServerSentEvent) GetEvent() string { + return "ERROR" +} + +func (o *PlatformSkillSourcePreviewStreamErrorServerSentEvent) GetData() PlatformSkillSourcePreviewStreamError { + if o == nil { + return PlatformSkillSourcePreviewStreamError{} + } + return o.Data +} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreameventserversentevent.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreameventserversentevent.go new file mode 100644 index 00000000..3451e409 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreameventserversentevent.go @@ -0,0 +1,178 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "errors" + "fmt" + "mockserver/internal/sdk/utils" +) + +type PlatformSkillSourcePreviewStreamEventServerSentEventType string + +const ( + PlatformSkillSourcePreviewStreamEventServerSentEventTypeScan PlatformSkillSourcePreviewStreamEventServerSentEventType = "SCAN" + PlatformSkillSourcePreviewStreamEventServerSentEventTypeProgress PlatformSkillSourcePreviewStreamEventServerSentEventType = "PROGRESS" + PlatformSkillSourcePreviewStreamEventServerSentEventTypeSkill PlatformSkillSourcePreviewStreamEventServerSentEventType = "SKILL" + PlatformSkillSourcePreviewStreamEventServerSentEventTypeResult PlatformSkillSourcePreviewStreamEventServerSentEventType = "RESULT" + PlatformSkillSourcePreviewStreamEventServerSentEventTypeError PlatformSkillSourcePreviewStreamEventServerSentEventType = "ERROR" +) + +// PlatformSkillSourcePreviewStreamEventServerSentEvent - A typed server-sent event. +type PlatformSkillSourcePreviewStreamEventServerSentEvent struct { + PlatformSkillSourcePreviewStreamScanServerSentEvent *PlatformSkillSourcePreviewStreamScanServerSentEvent `queryParam:"inline"` + PlatformSkillSourcePreviewStreamProgressServerSentEvent *PlatformSkillSourcePreviewStreamProgressServerSentEvent `queryParam:"inline"` + PlatformSkillSourcePreviewStreamSkillServerSentEvent *PlatformSkillSourcePreviewStreamSkillServerSentEvent `queryParam:"inline"` + PlatformSkillSourcePreviewStreamResultServerSentEvent *PlatformSkillSourcePreviewStreamResultServerSentEvent `queryParam:"inline"` + PlatformSkillSourcePreviewStreamErrorServerSentEvent *PlatformSkillSourcePreviewStreamErrorServerSentEvent `queryParam:"inline"` + + Type PlatformSkillSourcePreviewStreamEventServerSentEventType +} + +func CreatePlatformSkillSourcePreviewStreamEventServerSentEventScan(scan PlatformSkillSourcePreviewStreamScanServerSentEvent) PlatformSkillSourcePreviewStreamEventServerSentEvent { + typ := PlatformSkillSourcePreviewStreamEventServerSentEventTypeScan + + return PlatformSkillSourcePreviewStreamEventServerSentEvent{ + PlatformSkillSourcePreviewStreamScanServerSentEvent: &scan, + Type: typ, + } +} + +func CreatePlatformSkillSourcePreviewStreamEventServerSentEventProgress(progress PlatformSkillSourcePreviewStreamProgressServerSentEvent) PlatformSkillSourcePreviewStreamEventServerSentEvent { + typ := PlatformSkillSourcePreviewStreamEventServerSentEventTypeProgress + + return PlatformSkillSourcePreviewStreamEventServerSentEvent{ + PlatformSkillSourcePreviewStreamProgressServerSentEvent: &progress, + Type: typ, + } +} + +func CreatePlatformSkillSourcePreviewStreamEventServerSentEventSkill(skill PlatformSkillSourcePreviewStreamSkillServerSentEvent) PlatformSkillSourcePreviewStreamEventServerSentEvent { + typ := PlatformSkillSourcePreviewStreamEventServerSentEventTypeSkill + + return PlatformSkillSourcePreviewStreamEventServerSentEvent{ + PlatformSkillSourcePreviewStreamSkillServerSentEvent: &skill, + Type: typ, + } +} + +func CreatePlatformSkillSourcePreviewStreamEventServerSentEventResult(result PlatformSkillSourcePreviewStreamResultServerSentEvent) PlatformSkillSourcePreviewStreamEventServerSentEvent { + typ := PlatformSkillSourcePreviewStreamEventServerSentEventTypeResult + + return PlatformSkillSourcePreviewStreamEventServerSentEvent{ + PlatformSkillSourcePreviewStreamResultServerSentEvent: &result, + Type: typ, + } +} + +func CreatePlatformSkillSourcePreviewStreamEventServerSentEventError(errorT PlatformSkillSourcePreviewStreamErrorServerSentEvent) PlatformSkillSourcePreviewStreamEventServerSentEvent { + typ := PlatformSkillSourcePreviewStreamEventServerSentEventTypeError + + return PlatformSkillSourcePreviewStreamEventServerSentEvent{ + PlatformSkillSourcePreviewStreamErrorServerSentEvent: &errorT, + Type: typ, + } +} + +func (u *PlatformSkillSourcePreviewStreamEventServerSentEvent) UnmarshalJSON(data []byte) error { + + type discriminator struct { + Event string `json:"event"` + } + + dis := new(discriminator) + if err := json.Unmarshal(data, &dis); err != nil { + return fmt.Errorf("could not unmarshal discriminator: %w", err) + } + + switch dis.Event { + case "SCAN": + platformSkillSourcePreviewStreamScanServerSentEvent := new(PlatformSkillSourcePreviewStreamScanServerSentEvent) + if err := utils.UnmarshalJSON(data, &platformSkillSourcePreviewStreamScanServerSentEvent, "", true, nil); err != nil { + return fmt.Errorf("could not unmarshal `%s` into expected (Event == SCAN) type PlatformSkillSourcePreviewStreamScanServerSentEvent within PlatformSkillSourcePreviewStreamEventServerSentEvent: %w", string(data), err) + } + + u.PlatformSkillSourcePreviewStreamScanServerSentEvent = platformSkillSourcePreviewStreamScanServerSentEvent + u.Type = PlatformSkillSourcePreviewStreamEventServerSentEventTypeScan + return nil + case "PROGRESS": + platformSkillSourcePreviewStreamProgressServerSentEvent := new(PlatformSkillSourcePreviewStreamProgressServerSentEvent) + if err := utils.UnmarshalJSON(data, &platformSkillSourcePreviewStreamProgressServerSentEvent, "", true, nil); err != nil { + return fmt.Errorf("could not unmarshal `%s` into expected (Event == PROGRESS) type PlatformSkillSourcePreviewStreamProgressServerSentEvent within PlatformSkillSourcePreviewStreamEventServerSentEvent: %w", string(data), err) + } + + u.PlatformSkillSourcePreviewStreamProgressServerSentEvent = platformSkillSourcePreviewStreamProgressServerSentEvent + u.Type = PlatformSkillSourcePreviewStreamEventServerSentEventTypeProgress + return nil + case "SKILL": + platformSkillSourcePreviewStreamSkillServerSentEvent := new(PlatformSkillSourcePreviewStreamSkillServerSentEvent) + if err := utils.UnmarshalJSON(data, &platformSkillSourcePreviewStreamSkillServerSentEvent, "", true, nil); err != nil { + return fmt.Errorf("could not unmarshal `%s` into expected (Event == SKILL) type PlatformSkillSourcePreviewStreamSkillServerSentEvent within PlatformSkillSourcePreviewStreamEventServerSentEvent: %w", string(data), err) + } + + u.PlatformSkillSourcePreviewStreamSkillServerSentEvent = platformSkillSourcePreviewStreamSkillServerSentEvent + u.Type = PlatformSkillSourcePreviewStreamEventServerSentEventTypeSkill + return nil + case "RESULT": + platformSkillSourcePreviewStreamResultServerSentEvent := new(PlatformSkillSourcePreviewStreamResultServerSentEvent) + if err := utils.UnmarshalJSON(data, &platformSkillSourcePreviewStreamResultServerSentEvent, "", true, nil); err != nil { + return fmt.Errorf("could not unmarshal `%s` into expected (Event == RESULT) type PlatformSkillSourcePreviewStreamResultServerSentEvent within PlatformSkillSourcePreviewStreamEventServerSentEvent: %w", string(data), err) + } + + u.PlatformSkillSourcePreviewStreamResultServerSentEvent = platformSkillSourcePreviewStreamResultServerSentEvent + u.Type = PlatformSkillSourcePreviewStreamEventServerSentEventTypeResult + return nil + case "ERROR": + platformSkillSourcePreviewStreamErrorServerSentEvent := new(PlatformSkillSourcePreviewStreamErrorServerSentEvent) + if err := utils.UnmarshalJSON(data, &platformSkillSourcePreviewStreamErrorServerSentEvent, "", true, nil); err != nil { + return fmt.Errorf("could not unmarshal `%s` into expected (Event == ERROR) type PlatformSkillSourcePreviewStreamErrorServerSentEvent within PlatformSkillSourcePreviewStreamEventServerSentEvent: %w", string(data), err) + } + + u.PlatformSkillSourcePreviewStreamErrorServerSentEvent = platformSkillSourcePreviewStreamErrorServerSentEvent + u.Type = PlatformSkillSourcePreviewStreamEventServerSentEventTypeError + return nil + } + + return fmt.Errorf("could not unmarshal `%s` into any supported union types for PlatformSkillSourcePreviewStreamEventServerSentEvent", string(data)) +} + +func (u PlatformSkillSourcePreviewStreamEventServerSentEvent) MarshalJSON() ([]byte, error) { + if u.PlatformSkillSourcePreviewStreamScanServerSentEvent != nil { + return utils.MarshalJSON(u.PlatformSkillSourcePreviewStreamScanServerSentEvent, "", true) + } + + if u.PlatformSkillSourcePreviewStreamProgressServerSentEvent != nil { + return utils.MarshalJSON(u.PlatformSkillSourcePreviewStreamProgressServerSentEvent, "", true) + } + + if u.PlatformSkillSourcePreviewStreamSkillServerSentEvent != nil { + return utils.MarshalJSON(u.PlatformSkillSourcePreviewStreamSkillServerSentEvent, "", true) + } + + if u.PlatformSkillSourcePreviewStreamResultServerSentEvent != nil { + return utils.MarshalJSON(u.PlatformSkillSourcePreviewStreamResultServerSentEvent, "", true) + } + + if u.PlatformSkillSourcePreviewStreamErrorServerSentEvent != nil { + return utils.MarshalJSON(u.PlatformSkillSourcePreviewStreamErrorServerSentEvent, "", true) + } + + return nil, errors.New("could not marshal union type PlatformSkillSourcePreviewStreamEventServerSentEvent: all fields are null") +} + +func (o PlatformSkillSourcePreviewStreamEventServerSentEvent) GetEventEncoding(event string) (string, error) { + switch event { + case "SCAN": + return "application/json", nil + case "PROGRESS": + return "application/json", nil + case "SKILL": + return "application/json", nil + case "RESULT": + return "application/json", nil + case "ERROR": + return "application/json", nil + } + return "string", nil +} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamprogress.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamprogress.go new file mode 100644 index 00000000..20885b77 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamprogress.go @@ -0,0 +1,84 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" + "mockserver/internal/sdk/utils" +) + +// PlatformSkillSourcePreviewStreamProgressType - Event type, also sent as the SSE `event` name. +type PlatformSkillSourcePreviewStreamProgressType string + +const ( + PlatformSkillSourcePreviewStreamProgressTypeProgress PlatformSkillSourcePreviewStreamProgressType = "PROGRESS" +) + +func (e PlatformSkillSourcePreviewStreamProgressType) ToPointer() *PlatformSkillSourcePreviewStreamProgressType { + return &e +} +func (e *PlatformSkillSourcePreviewStreamProgressType) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "PROGRESS": + *e = PlatformSkillSourcePreviewStreamProgressType(v) + return nil + default: + return fmt.Errorf("invalid value for PlatformSkillSourcePreviewStreamProgressType: %v", v) + } +} + +// PlatformSkillSourcePreviewStreamProgress - One skill finished inspecting; names the skill in progress. +type PlatformSkillSourcePreviewStreamProgress struct { + // Event type, also sent as the SSE `event` name. + Type PlatformSkillSourcePreviewStreamProgressType `json:"type"` + // Number of skills inspected so far. + Completed int64 `json:"completed"` + // Number of skills to inspect. + Total int64 `json:"total"` + // Path of the skill being inspected. + CurrentSkill string `json:"current_skill"` +} + +func (p PlatformSkillSourcePreviewStreamProgress) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewStreamProgress) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"type", "completed", "total", "current_skill"}); err != nil { + return err + } + return nil +} + +func (o *PlatformSkillSourcePreviewStreamProgress) GetType() PlatformSkillSourcePreviewStreamProgressType { + if o == nil { + return PlatformSkillSourcePreviewStreamProgressType("") + } + return o.Type +} + +func (o *PlatformSkillSourcePreviewStreamProgress) GetCompleted() int64 { + if o == nil { + return 0 + } + return o.Completed +} + +func (o *PlatformSkillSourcePreviewStreamProgress) GetTotal() int64 { + if o == nil { + return 0 + } + return o.Total +} + +func (o *PlatformSkillSourcePreviewStreamProgress) GetCurrentSkill() string { + if o == nil { + return "" + } + return o.CurrentSkill +} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamprogressserversentevent.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamprogressserversentevent.go new file mode 100644 index 00000000..76ee67dd --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamprogressserversentevent.go @@ -0,0 +1,43 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "mockserver/internal/sdk/utils" +) + +type PlatformSkillSourcePreviewStreamProgressServerSentEvent struct { + ID *string `json:"id,omitempty"` + event string `const:"PROGRESS" json:"event"` + // One skill finished inspecting; names the skill in progress. + Data PlatformSkillSourcePreviewStreamProgress `json:"data"` +} + +func (p PlatformSkillSourcePreviewStreamProgressServerSentEvent) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewStreamProgressServerSentEvent) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"event", "data"}); err != nil { + return err + } + return nil +} + +func (o *PlatformSkillSourcePreviewStreamProgressServerSentEvent) GetID() *string { + if o == nil { + return nil + } + return o.ID +} + +func (o *PlatformSkillSourcePreviewStreamProgressServerSentEvent) GetEvent() string { + return "PROGRESS" +} + +func (o *PlatformSkillSourcePreviewStreamProgressServerSentEvent) GetData() PlatformSkillSourcePreviewStreamProgress { + if o == nil { + return PlatformSkillSourcePreviewStreamProgress{} + } + return o.Data +} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamresult.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamresult.go new file mode 100644 index 00000000..b3070c67 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamresult.go @@ -0,0 +1,65 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" + "mockserver/internal/sdk/utils" +) + +// PlatformSkillSourcePreviewStreamResultType - Event type, also sent as the SSE `event` name. +type PlatformSkillSourcePreviewStreamResultType string + +const ( + PlatformSkillSourcePreviewStreamResultTypeResult PlatformSkillSourcePreviewStreamResultType = "RESULT" +) + +func (e PlatformSkillSourcePreviewStreamResultType) ToPointer() *PlatformSkillSourcePreviewStreamResultType { + return &e +} +func (e *PlatformSkillSourcePreviewStreamResultType) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "RESULT": + *e = PlatformSkillSourcePreviewStreamResultType(v) + return nil + default: + return fmt.Errorf("invalid value for PlatformSkillSourcePreviewStreamResultType: %v", v) + } +} + +// PlatformSkillSourcePreviewStreamResult - Terminal success event carrying the fully assembled preview. +type PlatformSkillSourcePreviewStreamResult struct { + // Event type, also sent as the SSE `event` name. + Type PlatformSkillSourcePreviewStreamResultType `json:"type"` + Response PlatformSkillSourcePreviewResponse `json:"response"` +} + +func (p PlatformSkillSourcePreviewStreamResult) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewStreamResult) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"type", "response"}); err != nil { + return err + } + return nil +} + +func (o *PlatformSkillSourcePreviewStreamResult) GetType() PlatformSkillSourcePreviewStreamResultType { + if o == nil { + return PlatformSkillSourcePreviewStreamResultType("") + } + return o.Type +} + +func (o *PlatformSkillSourcePreviewStreamResult) GetResponse() PlatformSkillSourcePreviewResponse { + if o == nil { + return PlatformSkillSourcePreviewResponse{} + } + return o.Response +} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamresultserversentevent.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamresultserversentevent.go new file mode 100644 index 00000000..9320bc5f --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamresultserversentevent.go @@ -0,0 +1,43 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "mockserver/internal/sdk/utils" +) + +type PlatformSkillSourcePreviewStreamResultServerSentEvent struct { + ID *string `json:"id,omitempty"` + event string `const:"RESULT" json:"event"` + // Terminal success event carrying the fully assembled preview. + Data PlatformSkillSourcePreviewStreamResult `json:"data"` +} + +func (p PlatformSkillSourcePreviewStreamResultServerSentEvent) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewStreamResultServerSentEvent) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"event", "data"}); err != nil { + return err + } + return nil +} + +func (o *PlatformSkillSourcePreviewStreamResultServerSentEvent) GetID() *string { + if o == nil { + return nil + } + return o.ID +} + +func (o *PlatformSkillSourcePreviewStreamResultServerSentEvent) GetEvent() string { + return "RESULT" +} + +func (o *PlatformSkillSourcePreviewStreamResultServerSentEvent) GetData() PlatformSkillSourcePreviewStreamResult { + if o == nil { + return PlatformSkillSourcePreviewStreamResult{} + } + return o.Data +} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamscan.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamscan.go new file mode 100644 index 00000000..118e1273 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamscan.go @@ -0,0 +1,75 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" + "mockserver/internal/sdk/utils" +) + +// PlatformSkillSourcePreviewStreamScanType - Event type, also sent as the SSE `event` name. +type PlatformSkillSourcePreviewStreamScanType string + +const ( + PlatformSkillSourcePreviewStreamScanTypeScan PlatformSkillSourcePreviewStreamScanType = "SCAN" +) + +func (e PlatformSkillSourcePreviewStreamScanType) ToPointer() *PlatformSkillSourcePreviewStreamScanType { + return &e +} +func (e *PlatformSkillSourcePreviewStreamScanType) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "SCAN": + *e = PlatformSkillSourcePreviewStreamScanType(v) + return nil + default: + return fmt.Errorf("invalid value for PlatformSkillSourcePreviewStreamScanType: %v", v) + } +} + +// PlatformSkillSourcePreviewStreamScan - Repository scan started; names every skill path found. +type PlatformSkillSourcePreviewStreamScan struct { + // Event type, also sent as the SSE `event` name. + Type PlatformSkillSourcePreviewStreamScanType `json:"type"` + // Number of skill paths found in the scan. + Total int64 `json:"total"` + // Skill paths found in the scan. + SkillPaths []string `json:"skill_paths"` +} + +func (p PlatformSkillSourcePreviewStreamScan) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewStreamScan) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"type", "total", "skill_paths"}); err != nil { + return err + } + return nil +} + +func (o *PlatformSkillSourcePreviewStreamScan) GetType() PlatformSkillSourcePreviewStreamScanType { + if o == nil { + return PlatformSkillSourcePreviewStreamScanType("") + } + return o.Type +} + +func (o *PlatformSkillSourcePreviewStreamScan) GetTotal() int64 { + if o == nil { + return 0 + } + return o.Total +} + +func (o *PlatformSkillSourcePreviewStreamScan) GetSkillPaths() []string { + if o == nil { + return []string{} + } + return o.SkillPaths +} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamscanserversentevent.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamscanserversentevent.go new file mode 100644 index 00000000..f1b62054 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamscanserversentevent.go @@ -0,0 +1,43 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "mockserver/internal/sdk/utils" +) + +type PlatformSkillSourcePreviewStreamScanServerSentEvent struct { + ID *string `json:"id,omitempty"` + event string `const:"SCAN" json:"event"` + // Repository scan started; names every skill path found. + Data PlatformSkillSourcePreviewStreamScan `json:"data"` +} + +func (p PlatformSkillSourcePreviewStreamScanServerSentEvent) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewStreamScanServerSentEvent) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"event", "data"}); err != nil { + return err + } + return nil +} + +func (o *PlatformSkillSourcePreviewStreamScanServerSentEvent) GetID() *string { + if o == nil { + return nil + } + return o.ID +} + +func (o *PlatformSkillSourcePreviewStreamScanServerSentEvent) GetEvent() string { + return "SCAN" +} + +func (o *PlatformSkillSourcePreviewStreamScanServerSentEvent) GetData() PlatformSkillSourcePreviewStreamScan { + if o == nil { + return PlatformSkillSourcePreviewStreamScan{} + } + return o.Data +} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamskill.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamskill.go new file mode 100644 index 00000000..2be741fc --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamskill.go @@ -0,0 +1,65 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "encoding/json" + "fmt" + "mockserver/internal/sdk/utils" +) + +// PlatformSkillSourcePreviewStreamSkillType - Event type, also sent as the SSE `event` name. +type PlatformSkillSourcePreviewStreamSkillType string + +const ( + PlatformSkillSourcePreviewStreamSkillTypeSkill PlatformSkillSourcePreviewStreamSkillType = "SKILL" +) + +func (e PlatformSkillSourcePreviewStreamSkillType) ToPointer() *PlatformSkillSourcePreviewStreamSkillType { + return &e +} +func (e *PlatformSkillSourcePreviewStreamSkillType) UnmarshalJSON(data []byte) error { + var v string + if err := json.Unmarshal(data, &v); err != nil { + return err + } + switch v { + case "SKILL": + *e = PlatformSkillSourcePreviewStreamSkillType(v) + return nil + default: + return fmt.Errorf("invalid value for PlatformSkillSourcePreviewStreamSkillType: %v", v) + } +} + +// PlatformSkillSourcePreviewStreamSkill - One skill previewed; carries the previewed skill. +type PlatformSkillSourcePreviewStreamSkill struct { + // Event type, also sent as the SSE `event` name. + Type PlatformSkillSourcePreviewStreamSkillType `json:"type"` + Skill PlatformSkillSourcePreview `json:"skill"` +} + +func (p PlatformSkillSourcePreviewStreamSkill) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewStreamSkill) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"type", "skill"}); err != nil { + return err + } + return nil +} + +func (o *PlatformSkillSourcePreviewStreamSkill) GetType() PlatformSkillSourcePreviewStreamSkillType { + if o == nil { + return PlatformSkillSourcePreviewStreamSkillType("") + } + return o.Type +} + +func (o *PlatformSkillSourcePreviewStreamSkill) GetSkill() PlatformSkillSourcePreview { + if o == nil { + return PlatformSkillSourcePreview{} + } + return o.Skill +} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamskillserversentevent.go b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamskillserversentevent.go new file mode 100644 index 00000000..7b53e037 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformskillsourcepreviewstreamskillserversentevent.go @@ -0,0 +1,43 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "mockserver/internal/sdk/utils" +) + +type PlatformSkillSourcePreviewStreamSkillServerSentEvent struct { + ID *string `json:"id,omitempty"` + event string `const:"SKILL" json:"event"` + // One skill previewed; carries the previewed skill. + Data PlatformSkillSourcePreviewStreamSkill `json:"data"` +} + +func (p PlatformSkillSourcePreviewStreamSkillServerSentEvent) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillSourcePreviewStreamSkillServerSentEvent) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"event", "data"}); err != nil { + return err + } + return nil +} + +func (o *PlatformSkillSourcePreviewStreamSkillServerSentEvent) GetID() *string { + if o == nil { + return nil + } + return o.ID +} + +func (o *PlatformSkillSourcePreviewStreamSkillServerSentEvent) GetEvent() string { + return "SKILL" +} + +func (o *PlatformSkillSourcePreviewStreamSkillServerSentEvent) GetData() PlatformSkillSourcePreviewStreamSkill { + if o == nil { + return PlatformSkillSourcePreviewStreamSkill{} + } + return o.Data +} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillstatus.go b/tests/mockserver/internal/sdk/models/components/platformskillstatus.go index a218b760..d47da9c0 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskillstatus.go +++ b/tests/mockserver/internal/sdk/models/components/platformskillstatus.go @@ -7,7 +7,7 @@ import ( "fmt" ) -// PlatformSkillStatus - Current skill status. +// PlatformSkillStatus - The caller's effective activation. The owner sees the skill's stored status. Another caller sees their personal setting, or DISABLED when they have none. DRAFT is the stored draft state and is not set by update. Effective activation may also reflect workspace governance policy. type PlatformSkillStatus string const ( diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsyncresponse.go b/tests/mockserver/internal/sdk/models/components/platformskillsyncresponse.go index 773dec5b..cd8c8278 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskillsyncresponse.go +++ b/tests/mockserver/internal/sdk/models/components/platformskillsyncresponse.go @@ -3,23 +3,14 @@ package components type PlatformSkillSyncResponse struct { - // Synchronization status after a successful refresh. - SyncStatus PlatformSkillSyncResultStatus `json:"sync_status"` // Git commit SHA now associated with the skill. CommitSha string `json:"commit_sha"` // Whether this request created a new skill version. - Updated bool `json:"updated"` + IsUpdated bool `json:"is_updated"` // Platform-generated request ID for support correlation. RequestID string `json:"request_id"` } -func (o *PlatformSkillSyncResponse) GetSyncStatus() PlatformSkillSyncResultStatus { - if o == nil { - return PlatformSkillSyncResultStatus("") - } - return o.SyncStatus -} - func (o *PlatformSkillSyncResponse) GetCommitSha() string { if o == nil { return "" @@ -27,11 +18,11 @@ func (o *PlatformSkillSyncResponse) GetCommitSha() string { return o.CommitSha } -func (o *PlatformSkillSyncResponse) GetUpdated() bool { +func (o *PlatformSkillSyncResponse) GetIsUpdated() bool { if o == nil { return false } - return o.Updated + return o.IsUpdated } func (o *PlatformSkillSyncResponse) GetRequestID() string { diff --git a/tests/mockserver/internal/sdk/models/components/platformskillsyncresultstatus.go b/tests/mockserver/internal/sdk/models/components/platformskillsyncresultstatus.go deleted file mode 100644 index 93f6e9ed..00000000 --- a/tests/mockserver/internal/sdk/models/components/platformskillsyncresultstatus.go +++ /dev/null @@ -1,32 +0,0 @@ -// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. - -package components - -import ( - "encoding/json" - "fmt" -) - -// PlatformSkillSyncResultStatus - Synchronization status after a successful refresh. -type PlatformSkillSyncResultStatus string - -const ( - PlatformSkillSyncResultStatusUpToDate PlatformSkillSyncResultStatus = "UP_TO_DATE" -) - -func (e PlatformSkillSyncResultStatus) ToPointer() *PlatformSkillSyncResultStatus { - return &e -} -func (e *PlatformSkillSyncResultStatus) UnmarshalJSON(data []byte) error { - var v string - if err := json.Unmarshal(data, &v); err != nil { - return err - } - switch v { - case "UP_TO_DATE": - *e = PlatformSkillSyncResultStatus(v) - return nil - default: - return fmt.Errorf("invalid value for PlatformSkillSyncResultStatus: %v", v) - } -} diff --git a/tests/mockserver/internal/sdk/models/components/platformskillupdaterequest.go b/tests/mockserver/internal/sdk/models/components/platformskillupdaterequest.go index 16b5b625..1b120482 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskillupdaterequest.go +++ b/tests/mockserver/internal/sdk/models/components/platformskillupdaterequest.go @@ -3,7 +3,8 @@ package components type PlatformSkillUpdateRequest struct { - // New status for the skill. + // Activation to apply for the authenticated caller. For the owner, this updates the skill's stored status. For any other caller, it updates only that caller's setting. + // Status PlatformSkillUpdateStatus `json:"status"` } diff --git a/tests/mockserver/internal/sdk/models/components/platformskillupdatestatus.go b/tests/mockserver/internal/sdk/models/components/platformskillupdatestatus.go index d40a5b9f..46eaa67f 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskillupdatestatus.go +++ b/tests/mockserver/internal/sdk/models/components/platformskillupdatestatus.go @@ -7,7 +7,7 @@ import ( "fmt" ) -// PlatformSkillUpdateStatus - New status for the skill. +// PlatformSkillUpdateStatus - Activation to apply for the authenticated caller. For the owner, this updates the skill's stored status. For any other caller, it updates only that caller's setting. type PlatformSkillUpdateStatus string const ( diff --git a/tests/mockserver/internal/sdk/models/components/platformskillversionslistresponse.go b/tests/mockserver/internal/sdk/models/components/platformskillversionslistresponse.go index e6eac47b..cc6af7a3 100644 --- a/tests/mockserver/internal/sdk/models/components/platformskillversionslistresponse.go +++ b/tests/mockserver/internal/sdk/models/components/platformskillversionslistresponse.go @@ -4,7 +4,7 @@ package components type PlatformSkillVersionsListResponse struct { // Versions available for the skill. - Versions []PlatformSkillVersion `json:"versions"` + Results []PlatformSkillVersion `json:"results"` // Whether additional results are available. HasMore bool `json:"has_more"` // Cursor for the next page, or null when no more results are available. @@ -13,11 +13,11 @@ type PlatformSkillVersionsListResponse struct { RequestID string `json:"request_id"` } -func (o *PlatformSkillVersionsListResponse) GetVersions() []PlatformSkillVersion { +func (o *PlatformSkillVersionsListResponse) GetResults() []PlatformSkillVersion { if o == nil { return []PlatformSkillVersion{} } - return o.Versions + return o.Results } func (o *PlatformSkillVersionsListResponse) GetHasMore() bool { diff --git a/tests/mockserver/internal/sdk/models/components/platformusagesettingsresource.go b/tests/mockserver/internal/sdk/models/components/platformusagesettingsresource.go new file mode 100644 index 00000000..8b2b5764 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformusagesettingsresource.go @@ -0,0 +1,52 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "mockserver/internal/sdk/utils" + "time" +) + +// PlatformUsageSettingsResource - Workspace-wide usage settings. +type PlatformUsageSettingsResource struct { + // Settings for resolving limits across multiple memberships. + MultipleMembershipResolution *PlatformMultipleMembershipResolutionSettings `json:"multiple_membership_resolution,omitempty"` + // Settings that govern usage limit increase requests. + // + LimitIncreaseRequests *PlatformLimitIncreaseRequestSettings `json:"limit_increase_requests,omitempty"` + // ISO 8601 timestamp of the last settings update. + // + UpdatedAt *time.Time `json:"updated_at,omitempty"` +} + +func (p PlatformUsageSettingsResource) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformUsageSettingsResource) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, nil); err != nil { + return err + } + return nil +} + +func (o *PlatformUsageSettingsResource) GetMultipleMembershipResolution() *PlatformMultipleMembershipResolutionSettings { + if o == nil { + return nil + } + return o.MultipleMembershipResolution +} + +func (o *PlatformUsageSettingsResource) GetLimitIncreaseRequests() *PlatformLimitIncreaseRequestSettings { + if o == nil { + return nil + } + return o.LimitIncreaseRequests +} + +func (o *PlatformUsageSettingsResource) GetUpdatedAt() *time.Time { + if o == nil { + return nil + } + return o.UpdatedAt +} diff --git a/tests/mockserver/internal/sdk/models/components/platformusagesettingsresponse.go b/tests/mockserver/internal/sdk/models/components/platformusagesettingsresponse.go new file mode 100644 index 00000000..af32749b --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformusagesettingsresponse.go @@ -0,0 +1,27 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +// PlatformUsageSettingsResponse - Response envelope for usage settings operations. +type PlatformUsageSettingsResponse struct { + // Workspace-wide usage settings. + // + UsageSettings PlatformUsageSettingsResource `json:"usage_settings"` + // Opaque request identifier. + // + RequestID string `json:"request_id"` +} + +func (o *PlatformUsageSettingsResponse) GetUsageSettings() PlatformUsageSettingsResource { + if o == nil { + return PlatformUsageSettingsResource{} + } + return o.UsageSettings +} + +func (o *PlatformUsageSettingsResponse) GetRequestID() string { + if o == nil { + return "" + } + return o.RequestID +} diff --git a/tests/mockserver/internal/sdk/models/components/platformusagesettingsupdaterequestunion.go b/tests/mockserver/internal/sdk/models/components/platformusagesettingsupdaterequestunion.go new file mode 100644 index 00000000..10a76f27 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/components/platformusagesettingsupdaterequestunion.go @@ -0,0 +1,139 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package components + +import ( + "errors" + "fmt" + "mockserver/internal/sdk/utils" +) + +type PlatformUsageSettingsUpdateRequest2 struct { + // Settings for resolving limits across multiple memberships. + MultipleMembershipResolution *PlatformMultipleMembershipResolutionSettings `json:"multiple_membership_resolution,omitempty"` + // Settings that govern usage limit increase requests. + // + LimitIncreaseRequests PlatformLimitIncreaseRequestSettings `json:"limit_increase_requests"` +} + +func (p PlatformUsageSettingsUpdateRequest2) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformUsageSettingsUpdateRequest2) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"limit_increase_requests"}); err != nil { + return err + } + return nil +} + +func (o *PlatformUsageSettingsUpdateRequest2) GetMultipleMembershipResolution() *PlatformMultipleMembershipResolutionSettings { + if o == nil { + return nil + } + return o.MultipleMembershipResolution +} + +func (o *PlatformUsageSettingsUpdateRequest2) GetLimitIncreaseRequests() PlatformLimitIncreaseRequestSettings { + if o == nil { + return PlatformLimitIncreaseRequestSettings{} + } + return o.LimitIncreaseRequests +} + +type PlatformUsageSettingsUpdateRequest1 struct { + // Settings for resolving limits across multiple memberships. + MultipleMembershipResolution PlatformMultipleMembershipResolutionSettings `json:"multiple_membership_resolution"` + // Settings that govern usage limit increase requests. + // + LimitIncreaseRequests *PlatformLimitIncreaseRequestSettings `json:"limit_increase_requests,omitempty"` +} + +func (p PlatformUsageSettingsUpdateRequest1) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformUsageSettingsUpdateRequest1) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"multiple_membership_resolution"}); err != nil { + return err + } + return nil +} + +func (o *PlatformUsageSettingsUpdateRequest1) GetMultipleMembershipResolution() PlatformMultipleMembershipResolutionSettings { + if o == nil { + return PlatformMultipleMembershipResolutionSettings{} + } + return o.MultipleMembershipResolution +} + +func (o *PlatformUsageSettingsUpdateRequest1) GetLimitIncreaseRequests() *PlatformLimitIncreaseRequestSettings { + if o == nil { + return nil + } + return o.LimitIncreaseRequests +} + +type PlatformUsageSettingsUpdateRequestUnionType string + +const ( + PlatformUsageSettingsUpdateRequestUnionTypePlatformUsageSettingsUpdateRequest1 PlatformUsageSettingsUpdateRequestUnionType = "PlatformUsageSettingsUpdateRequest_1" + PlatformUsageSettingsUpdateRequestUnionTypePlatformUsageSettingsUpdateRequest2 PlatformUsageSettingsUpdateRequestUnionType = "PlatformUsageSettingsUpdateRequest_2" +) + +// PlatformUsageSettingsUpdateRequestUnion - Request body for updating workspace-wide usage settings. +type PlatformUsageSettingsUpdateRequestUnion struct { + PlatformUsageSettingsUpdateRequest1 *PlatformUsageSettingsUpdateRequest1 `queryParam:"inline"` + PlatformUsageSettingsUpdateRequest2 *PlatformUsageSettingsUpdateRequest2 `queryParam:"inline"` + + Type PlatformUsageSettingsUpdateRequestUnionType +} + +func CreatePlatformUsageSettingsUpdateRequestUnionPlatformUsageSettingsUpdateRequest1(platformUsageSettingsUpdateRequest1 PlatformUsageSettingsUpdateRequest1) PlatformUsageSettingsUpdateRequestUnion { + typ := PlatformUsageSettingsUpdateRequestUnionTypePlatformUsageSettingsUpdateRequest1 + + return PlatformUsageSettingsUpdateRequestUnion{ + PlatformUsageSettingsUpdateRequest1: &platformUsageSettingsUpdateRequest1, + Type: typ, + } +} + +func CreatePlatformUsageSettingsUpdateRequestUnionPlatformUsageSettingsUpdateRequest2(platformUsageSettingsUpdateRequest2 PlatformUsageSettingsUpdateRequest2) PlatformUsageSettingsUpdateRequestUnion { + typ := PlatformUsageSettingsUpdateRequestUnionTypePlatformUsageSettingsUpdateRequest2 + + return PlatformUsageSettingsUpdateRequestUnion{ + PlatformUsageSettingsUpdateRequest2: &platformUsageSettingsUpdateRequest2, + Type: typ, + } +} + +func (u *PlatformUsageSettingsUpdateRequestUnion) UnmarshalJSON(data []byte) error { + + var platformUsageSettingsUpdateRequest1 PlatformUsageSettingsUpdateRequest1 = PlatformUsageSettingsUpdateRequest1{} + if err := utils.UnmarshalJSON(data, &platformUsageSettingsUpdateRequest1, "", true, nil); err == nil { + u.PlatformUsageSettingsUpdateRequest1 = &platformUsageSettingsUpdateRequest1 + u.Type = PlatformUsageSettingsUpdateRequestUnionTypePlatformUsageSettingsUpdateRequest1 + return nil + } + + var platformUsageSettingsUpdateRequest2 PlatformUsageSettingsUpdateRequest2 = PlatformUsageSettingsUpdateRequest2{} + if err := utils.UnmarshalJSON(data, &platformUsageSettingsUpdateRequest2, "", true, nil); err == nil { + u.PlatformUsageSettingsUpdateRequest2 = &platformUsageSettingsUpdateRequest2 + u.Type = PlatformUsageSettingsUpdateRequestUnionTypePlatformUsageSettingsUpdateRequest2 + return nil + } + + return fmt.Errorf("could not unmarshal `%s` into any supported union types for PlatformUsageSettingsUpdateRequestUnion", string(data)) +} + +func (u PlatformUsageSettingsUpdateRequestUnion) MarshalJSON() ([]byte, error) { + if u.PlatformUsageSettingsUpdateRequest1 != nil { + return utils.MarshalJSON(u.PlatformUsageSettingsUpdateRequest1, "", true) + } + + if u.PlatformUsageSettingsUpdateRequest2 != nil { + return utils.MarshalJSON(u.PlatformUsageSettingsUpdateRequest2, "", true) + } + + return nil, errors.New("could not marshal union type PlatformUsageSettingsUpdateRequestUnion: all fields are null") +} diff --git a/tests/mockserver/internal/sdk/models/components/ugctype.go b/tests/mockserver/internal/sdk/models/components/ugctype.go index 3d7ab4b4..069786db 100644 --- a/tests/mockserver/internal/sdk/models/components/ugctype.go +++ b/tests/mockserver/internal/sdk/models/components/ugctype.go @@ -30,6 +30,7 @@ const ( UgcTypeSpreadsheetType UgcType = "SPREADSHEET_TYPE" UgcTypeInlineHTMLType UgcType = "INLINE_HTML_TYPE" UgcTypePodcastType UgcType = "PODCAST_TYPE" + UgcTypeVideoType UgcType = "VIDEO_TYPE" UgcTypeWorkflowsType UgcType = "WORKFLOWS_TYPE" ) @@ -82,6 +83,8 @@ func (e *UgcType) UnmarshalJSON(data []byte) error { fallthrough case "PODCAST_TYPE": fallthrough + case "VIDEO_TYPE": + fallthrough case "WORKFLOWS_TYPE": *e = UgcType(v) return nil diff --git a/tests/mockserver/internal/sdk/models/operations/platformadminusagerequestscreate.go b/tests/mockserver/internal/sdk/models/operations/platformadminusagerequestscreate.go new file mode 100644 index 00000000..d56734d1 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/operations/platformadminusagerequestscreate.go @@ -0,0 +1,27 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package operations + +import ( + "mockserver/internal/sdk/models/components" +) + +type PlatformAdminUsageRequestsCreateResponse struct { + HTTPMeta components.HTTPMetadata `json:"-"` + // The created editable-agent request. + PlatformRequestResponse *components.PlatformRequestResponse +} + +func (o *PlatformAdminUsageRequestsCreateResponse) GetHTTPMeta() components.HTTPMetadata { + if o == nil { + return components.HTTPMetadata{} + } + return o.HTTPMeta +} + +func (o *PlatformAdminUsageRequestsCreateResponse) GetPlatformRequestResponse() *components.PlatformRequestResponse { + if o == nil { + return nil + } + return o.PlatformRequestResponse +} diff --git a/tests/mockserver/internal/sdk/models/operations/platformadminusagerequestsget.go b/tests/mockserver/internal/sdk/models/operations/platformadminusagerequestsget.go new file mode 100644 index 00000000..f0a393e8 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/operations/platformadminusagerequestsget.go @@ -0,0 +1,39 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package operations + +import ( + "mockserver/internal/sdk/models/components" +) + +type PlatformAdminUsageRequestsGetRequest struct { + // Opaque request identifier; not an authorization grant. + RequestID string `pathParam:"style=simple,explode=false,name=request_id"` +} + +func (o *PlatformAdminUsageRequestsGetRequest) GetRequestID() string { + if o == nil { + return "" + } + return o.RequestID +} + +type PlatformAdminUsageRequestsGetResponse struct { + HTTPMeta components.HTTPMetadata `json:"-"` + // The authorized request in its current stored state. + PlatformRequestResponse *components.PlatformRequestResponse +} + +func (o *PlatformAdminUsageRequestsGetResponse) GetHTTPMeta() components.HTTPMetadata { + if o == nil { + return components.HTTPMetadata{} + } + return o.HTTPMeta +} + +func (o *PlatformAdminUsageRequestsGetResponse) GetPlatformRequestResponse() *components.PlatformRequestResponse { + if o == nil { + return nil + } + return o.PlatformRequestResponse +} diff --git a/tests/mockserver/internal/sdk/models/operations/platformadminusagerequestslist.go b/tests/mockserver/internal/sdk/models/operations/platformadminusagerequestslist.go new file mode 100644 index 00000000..b0a440eb --- /dev/null +++ b/tests/mockserver/internal/sdk/models/operations/platformadminusagerequestslist.go @@ -0,0 +1,69 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package operations + +import ( + "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/utils" +) + +type PlatformAdminUsageRequestsListRequest struct { + // Maximum page size; defaults to 20 and cannot exceed 100. + PageSize *int64 `default:"20" queryParam:"style=form,explode=true,name=page_size"` + // Opaque continuation bound to filters and current authorization. + Cursor *string `queryParam:"style=form,explode=true,name=cursor"` + // Optional structured filters on request status. + Filters []components.PlatformRequestFilter `queryParam:"serialization=json,name=filters"` +} + +func (p PlatformAdminUsageRequestsListRequest) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformAdminUsageRequestsListRequest) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, nil); err != nil { + return err + } + return nil +} + +func (o *PlatformAdminUsageRequestsListRequest) GetPageSize() *int64 { + if o == nil { + return nil + } + return o.PageSize +} + +func (o *PlatformAdminUsageRequestsListRequest) GetCursor() *string { + if o == nil { + return nil + } + return o.Cursor +} + +func (o *PlatformAdminUsageRequestsListRequest) GetFilters() []components.PlatformRequestFilter { + if o == nil { + return nil + } + return o.Filters +} + +type PlatformAdminUsageRequestsListResponse struct { + HTTPMeta components.HTTPMetadata `json:"-"` + // A bounded page of authorized requests. + PlatformRequestListResponse *components.PlatformRequestListResponseUnion +} + +func (o *PlatformAdminUsageRequestsListResponse) GetHTTPMeta() components.HTTPMetadata { + if o == nil { + return components.HTTPMetadata{} + } + return o.HTTPMeta +} + +func (o *PlatformAdminUsageRequestsListResponse) GetPlatformRequestListResponse() *components.PlatformRequestListResponseUnion { + if o == nil { + return nil + } + return o.PlatformRequestListResponse +} diff --git a/tests/mockserver/internal/sdk/models/operations/platformadminusagesettingsget.go b/tests/mockserver/internal/sdk/models/operations/platformadminusagesettingsget.go new file mode 100644 index 00000000..9325e1d5 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/operations/platformadminusagesettingsget.go @@ -0,0 +1,27 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package operations + +import ( + "mockserver/internal/sdk/models/components" +) + +type PlatformAdminUsageSettingsGetResponse struct { + HTTPMeta components.HTTPMetadata `json:"-"` + // Usage settings. + PlatformUsageSettingsResponse *components.PlatformUsageSettingsResponse +} + +func (o *PlatformAdminUsageSettingsGetResponse) GetHTTPMeta() components.HTTPMetadata { + if o == nil { + return components.HTTPMetadata{} + } + return o.HTTPMeta +} + +func (o *PlatformAdminUsageSettingsGetResponse) GetPlatformUsageSettingsResponse() *components.PlatformUsageSettingsResponse { + if o == nil { + return nil + } + return o.PlatformUsageSettingsResponse +} diff --git a/tests/mockserver/internal/sdk/models/operations/platformadminusagesettingsupdate.go b/tests/mockserver/internal/sdk/models/operations/platformadminusagesettingsupdate.go new file mode 100644 index 00000000..22133788 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/operations/platformadminusagesettingsupdate.go @@ -0,0 +1,27 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package operations + +import ( + "mockserver/internal/sdk/models/components" +) + +type PlatformAdminUsageSettingsUpdateResponse struct { + HTTPMeta components.HTTPMetadata `json:"-"` + // Updated usage settings. + PlatformUsageSettingsResponse *components.PlatformUsageSettingsResponse +} + +func (o *PlatformAdminUsageSettingsUpdateResponse) GetHTTPMeta() components.HTTPMetadata { + if o == nil { + return components.HTTPMetadata{} + } + return o.HTTPMeta +} + +func (o *PlatformAdminUsageSettingsUpdateResponse) GetPlatformUsageSettingsResponse() *components.PlatformUsageSettingsResponse { + if o == nil { + return nil + } + return o.PlatformUsageSettingsResponse +} diff --git a/tests/mockserver/internal/sdk/models/operations/platformskillscreate.go b/tests/mockserver/internal/sdk/models/operations/platformskillscreate.go index 7018793f..f5a35851 100644 --- a/tests/mockserver/internal/sdk/models/operations/platformskillscreate.go +++ b/tests/mockserver/internal/sdk/models/operations/platformskillscreate.go @@ -8,7 +8,7 @@ import ( type PlatformSkillsCreateResponse struct { HTTPMeta components.HTTPMetadata `json:"-"` - // Successful response. + // Skill created. PlatformSkillCreateResponse *components.PlatformSkillCreateResponse } diff --git a/tests/mockserver/internal/sdk/models/operations/platformskillscreateversion.go b/tests/mockserver/internal/sdk/models/operations/platformskillscreateversion.go index 554b0438..6a55d73d 100644 --- a/tests/mockserver/internal/sdk/models/operations/platformskillscreateversion.go +++ b/tests/mockserver/internal/sdk/models/operations/platformskillscreateversion.go @@ -28,7 +28,7 @@ func (o *PlatformSkillsCreateVersionRequest) GetBody() components.PlatformSkillV type PlatformSkillsCreateVersionResponse struct { HTTPMeta components.HTTPMetadata `json:"-"` - // Successful response. + // Skill version created. PlatformSkillVersionCreateResponse *components.PlatformSkillVersionCreateResponse } diff --git a/tests/mockserver/internal/sdk/models/operations/platformskillslist.go b/tests/mockserver/internal/sdk/models/operations/platformskillslist.go index 40f74199..2286c481 100644 --- a/tests/mockserver/internal/sdk/models/operations/platformskillslist.go +++ b/tests/mockserver/internal/sdk/models/operations/platformskillslist.go @@ -4,15 +4,27 @@ package operations import ( "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/utils" ) type PlatformSkillsListRequest struct { - // Maximum number of skills to return. - PageSize *int64 `queryParam:"style=form,explode=true,name=page_size"` + // Maximum number of skills to return. Defaults to 20. Maximum is 100. + PageSize *int64 `default:"20" queryParam:"style=form,explode=true,name=page_size"` // Opaque pagination cursor from a previous response. Cursor *string `queryParam:"style=form,explode=true,name=cursor"` } +func (p PlatformSkillsListRequest) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillsListRequest) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, nil); err != nil { + return err + } + return nil +} + func (o *PlatformSkillsListRequest) GetPageSize() *int64 { if o == nil { return nil diff --git a/tests/mockserver/internal/sdk/models/operations/platformskillslistversions.go b/tests/mockserver/internal/sdk/models/operations/platformskillslistversions.go index 3853971f..dcea3d13 100644 --- a/tests/mockserver/internal/sdk/models/operations/platformskillslistversions.go +++ b/tests/mockserver/internal/sdk/models/operations/platformskillslistversions.go @@ -4,17 +4,29 @@ package operations import ( "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/utils" ) type PlatformSkillsListVersionsRequest struct { // Glean skill ID. SkillID string `pathParam:"style=simple,explode=false,name=skill_id"` - // Maximum number of versions to return. - PageSize *int64 `queryParam:"style=form,explode=true,name=page_size"` + // Maximum number of versions to return. Defaults to 20. Maximum is 100. + PageSize *int64 `default:"20" queryParam:"style=form,explode=true,name=page_size"` // Opaque pagination cursor from a previous response. Cursor *string `queryParam:"style=form,explode=true,name=cursor"` } +func (p PlatformSkillsListVersionsRequest) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillsListVersionsRequest) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"skill_id"}); err != nil { + return err + } + return nil +} + func (o *PlatformSkillsListVersionsRequest) GetSkillID() string { if o == nil { return "" diff --git a/tests/mockserver/internal/sdk/models/operations/platformskillspreviewsource.go b/tests/mockserver/internal/sdk/models/operations/platformskillspreviewsource.go index a32c6102..a189b4a3 100644 --- a/tests/mockserver/internal/sdk/models/operations/platformskillspreviewsource.go +++ b/tests/mockserver/internal/sdk/models/operations/platformskillspreviewsource.go @@ -4,14 +4,42 @@ package operations import ( "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/types" + "mockserver/internal/sdk/utils" ) +type PlatformSkillsPreviewSourceRequest struct { + // GitHub URL for a skill directory, SKILL.md file, or repository to inspect. + SourceURL string `json:"source_url"` + stream *bool `const:"false" json:"stream"` +} + +func (p PlatformSkillsPreviewSourceRequest) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillsPreviewSourceRequest) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"source_url"}); err != nil { + return err + } + return nil +} + +func (o *PlatformSkillsPreviewSourceRequest) GetSourceURL() string { + if o == nil { + return "" + } + return o.SourceURL +} + +func (o *PlatformSkillsPreviewSourceRequest) GetStream() *bool { + return types.Bool(false) +} + type PlatformSkillsPreviewSourceResponse struct { HTTPMeta components.HTTPMetadata `json:"-"` // Successful response. PlatformSkillSourcePreviewResponse *components.PlatformSkillSourcePreviewResponse - // Successful response. - Res *string } func (o *PlatformSkillsPreviewSourceResponse) GetHTTPMeta() components.HTTPMetadata { @@ -27,10 +55,3 @@ func (o *PlatformSkillsPreviewSourceResponse) GetPlatformSkillSourcePreviewRespo } return o.PlatformSkillSourcePreviewResponse } - -func (o *PlatformSkillsPreviewSourceResponse) GetRes() *string { - if o == nil { - return nil - } - return o.Res -} diff --git a/tests/mockserver/internal/sdk/models/operations/platformskillspreviewsourcestream.go b/tests/mockserver/internal/sdk/models/operations/platformskillspreviewsourcestream.go new file mode 100644 index 00000000..f89eab8b --- /dev/null +++ b/tests/mockserver/internal/sdk/models/operations/platformskillspreviewsourcestream.go @@ -0,0 +1,58 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package operations + +import ( + "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/types" + "mockserver/internal/sdk/types/stream" + "mockserver/internal/sdk/utils" +) + +type PlatformSkillsPreviewSourceStreamRequest struct { + // GitHub URL for a skill directory, SKILL.md file, or repository to inspect. + SourceURL string `json:"source_url"` + stream *bool `const:"true" json:"stream"` +} + +func (p PlatformSkillsPreviewSourceStreamRequest) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformSkillsPreviewSourceStreamRequest) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, []string{"source_url"}); err != nil { + return err + } + return nil +} + +func (o *PlatformSkillsPreviewSourceStreamRequest) GetSourceURL() string { + if o == nil { + return "" + } + return o.SourceURL +} + +func (o *PlatformSkillsPreviewSourceStreamRequest) GetStream() *bool { + return types.Bool(true) +} + +type PlatformSkillsPreviewSourceStreamResponse struct { + HTTPMeta components.HTTPMetadata `json:"-"` + // Successful response. + PlatformSkillSourcePreviewStreamEventServerSentEvent *stream.EventStream[components.PlatformSkillSourcePreviewStreamEventServerSentEvent] +} + +func (o *PlatformSkillsPreviewSourceStreamResponse) GetHTTPMeta() components.HTTPMetadata { + if o == nil { + return components.HTTPMetadata{} + } + return o.HTTPMeta +} + +func (o *PlatformSkillsPreviewSourceStreamResponse) GetPlatformSkillSourcePreviewStreamEventServerSentEvent() *stream.EventStream[components.PlatformSkillSourcePreviewStreamEventServerSentEvent] { + if o == nil { + return nil + } + return o.PlatformSkillSourcePreviewStreamEventServerSentEvent +} diff --git a/tests/mockserver/internal/sdk/models/operations/platformusagerequestscreate.go b/tests/mockserver/internal/sdk/models/operations/platformusagerequestscreate.go new file mode 100644 index 00000000..87ac5644 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/operations/platformusagerequestscreate.go @@ -0,0 +1,27 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package operations + +import ( + "mockserver/internal/sdk/models/components" +) + +type PlatformUsageRequestsCreateResponse struct { + HTTPMeta components.HTTPMetadata `json:"-"` + // The created personal request. + PlatformRequestResponse *components.PlatformRequestResponse +} + +func (o *PlatformUsageRequestsCreateResponse) GetHTTPMeta() components.HTTPMetadata { + if o == nil { + return components.HTTPMetadata{} + } + return o.HTTPMeta +} + +func (o *PlatformUsageRequestsCreateResponse) GetPlatformRequestResponse() *components.PlatformRequestResponse { + if o == nil { + return nil + } + return o.PlatformRequestResponse +} diff --git a/tests/mockserver/internal/sdk/models/operations/platformusagerequestsget.go b/tests/mockserver/internal/sdk/models/operations/platformusagerequestsget.go new file mode 100644 index 00000000..3e3eb28e --- /dev/null +++ b/tests/mockserver/internal/sdk/models/operations/platformusagerequestsget.go @@ -0,0 +1,39 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package operations + +import ( + "mockserver/internal/sdk/models/components" +) + +type PlatformUsageRequestsGetRequest struct { + // Opaque personal request identifier; not an authorization grant. + RequestID string `pathParam:"style=simple,explode=false,name=request_id"` +} + +func (o *PlatformUsageRequestsGetRequest) GetRequestID() string { + if o == nil { + return "" + } + return o.RequestID +} + +type PlatformUsageRequestsGetResponse struct { + HTTPMeta components.HTTPMetadata `json:"-"` + // The authorized request in its current stored state. + PlatformRequestResponse *components.PlatformRequestResponse +} + +func (o *PlatformUsageRequestsGetResponse) GetHTTPMeta() components.HTTPMetadata { + if o == nil { + return components.HTTPMetadata{} + } + return o.HTTPMeta +} + +func (o *PlatformUsageRequestsGetResponse) GetPlatformRequestResponse() *components.PlatformRequestResponse { + if o == nil { + return nil + } + return o.PlatformRequestResponse +} diff --git a/tests/mockserver/internal/sdk/models/operations/platformusagerequestslist.go b/tests/mockserver/internal/sdk/models/operations/platformusagerequestslist.go new file mode 100644 index 00000000..21ce6d66 --- /dev/null +++ b/tests/mockserver/internal/sdk/models/operations/platformusagerequestslist.go @@ -0,0 +1,69 @@ +// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + +package operations + +import ( + "mockserver/internal/sdk/models/components" + "mockserver/internal/sdk/utils" +) + +type PlatformUsageRequestsListRequest struct { + // Maximum page size; defaults to 20 and cannot exceed 100. + PageSize *int64 `default:"20" queryParam:"style=form,explode=true,name=page_size"` + // Opaque continuation bound to filters and current authorization. + Cursor *string `queryParam:"style=form,explode=true,name=cursor"` + // Optional structured filters on request status. + Filters []components.PlatformRequestFilter `queryParam:"serialization=json,name=filters"` +} + +func (p PlatformUsageRequestsListRequest) MarshalJSON() ([]byte, error) { + return utils.MarshalJSON(p, "", false) +} + +func (p *PlatformUsageRequestsListRequest) UnmarshalJSON(data []byte) error { + if err := utils.UnmarshalJSON(data, &p, "", false, nil); err != nil { + return err + } + return nil +} + +func (o *PlatformUsageRequestsListRequest) GetPageSize() *int64 { + if o == nil { + return nil + } + return o.PageSize +} + +func (o *PlatformUsageRequestsListRequest) GetCursor() *string { + if o == nil { + return nil + } + return o.Cursor +} + +func (o *PlatformUsageRequestsListRequest) GetFilters() []components.PlatformRequestFilter { + if o == nil { + return nil + } + return o.Filters +} + +type PlatformUsageRequestsListResponse struct { + HTTPMeta components.HTTPMetadata `json:"-"` + // A bounded page of authorized requests. + PlatformRequestListResponse *components.PlatformRequestListResponseUnion +} + +func (o *PlatformUsageRequestsListResponse) GetHTTPMeta() components.HTTPMetadata { + if o == nil { + return components.HTTPMetadata{} + } + return o.HTTPMeta +} + +func (o *PlatformUsageRequestsListResponse) GetPlatformRequestListResponse() *components.PlatformRequestListResponseUnion { + if o == nil { + return nil + } + return o.PlatformRequestListResponse +} diff --git a/tests/mockserver/internal/sdk/optionalnullable/optionalnullable.go b/tests/mockserver/internal/sdk/optionalnullable/optionalnullable.go index bdf1155c..6d3eff53 100644 --- a/tests/mockserver/internal/sdk/optionalnullable/optionalnullable.go +++ b/tests/mockserver/internal/sdk/optionalnullable/optionalnullable.go @@ -248,3 +248,29 @@ func AsOptionalNullable(v reflect.Value) (OptionalNullableInterface, bool) { } return nil, false } + +var optionalNullableInterfaceType = reflect.TypeOf((*OptionalNullableInterface)(nil)).Elem() + +// IsOptionalNullableType reports whether typ is an OptionalNullable[T] type. +// It is the type-level counterpart to AsOptionalNullable, for reflection-based +// code that only has a reflect.Type (e.g. when deciding how to decode into a +// zero value). +func IsOptionalNullableType(typ reflect.Type) bool { + return typ != nil && + typ.Kind() == reflect.Map && + typ.Key().Kind() == reflect.Bool && + typ.Elem().Kind() == reflect.Ptr && + typ.Implements(optionalNullableInterfaceType) +} + +// FromReflect is the reflection-based counterpart to From: it returns a new +// OptionalNullable value of type typ (which must satisfy IsOptionalNullableType) +// set to the value innerPtr points at. innerPtr must be assignable to typ's +// element type (*T); pass a nil *T to set the value to null. +func FromReflect(typ reflect.Type, innerPtr reflect.Value) reflect.Value { + m := reflect.MakeMapWithSize(typ, 1) + key := reflect.New(typ.Key()).Elem() + key.SetBool(true) + m.SetMapIndex(key, innerPtr) + return m +} diff --git a/tests/mockserver/internal/sdk/optionalnullable/optionalnullable_test.go b/tests/mockserver/internal/sdk/optionalnullable/optionalnullable_test.go index 52fb11f9..cfddc167 100644 --- a/tests/mockserver/internal/sdk/optionalnullable/optionalnullable_test.go +++ b/tests/mockserver/internal/sdk/optionalnullable/optionalnullable_test.go @@ -1857,3 +1857,96 @@ func TestAsOptionalNullable(t *testing.T) { assert.Equal(t, "test", value) }) } + +func TestIsOptionalNullableType(t *testing.T) { + t.Parallel() + tests := []struct { + name string + typ reflect.Type + want bool + }{ + { + name: "OptionalNullable of scalar", + typ: reflect.TypeOf(OptionalNullable[string]{}), + want: true, + }, + { + name: "OptionalNullable of pointer", + typ: reflect.TypeOf(OptionalNullable[*int]{}), + want: true, + }, + { + name: "OptionalNullable of slice", + typ: reflect.TypeOf(OptionalNullable[[]string]{}), + want: true, + }, + { + name: "plain string map", + typ: reflect.TypeOf(map[string]string{}), + want: false, + }, + { + name: "bool-keyed map with non-pointer values", + typ: reflect.TypeOf(map[bool]string{}), + want: false, + }, + { + name: "bool-keyed pointer map without the interface method", + typ: reflect.TypeOf(map[bool]*string{}), + want: false, + }, + { + name: "non-map type", + typ: reflect.TypeOf(""), + want: false, + }, + { + name: "pointer to OptionalNullable", + typ: reflect.TypeOf(&OptionalNullable[string]{}), + want: false, + }, + { + name: "nil type", + typ: nil, + want: false, + }, + } + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + t.Parallel() + assert.Equal(t, tt.want, IsOptionalNullableType(tt.typ)) + }) + } +} + +func TestFromReflect(t *testing.T) { + t.Parallel() + typ := reflect.TypeOf(OptionalNullable[string]{}) + + t.Run("with value", func(t *testing.T) { + t.Parallel() + inner := reflect.New(reflect.TypeOf("")) + inner.Elem().SetString("hello") + + got, ok := FromReflect(typ, inner).Interface().(OptionalNullable[string]) + require.True(t, ok) + assert.True(t, got.IsSet()) + assert.False(t, got.IsNull()) + v, set := got.Get() + require.True(t, set) + require.NotNil(t, v) + assert.Equal(t, "hello", *v) + assert.Equal(t, From(ptrFrom("hello")), got) + }) + + t.Run("with nil pointer sets null", func(t *testing.T) { + t.Parallel() + nilPtr := reflect.Zero(typ.Elem()) + + got, ok := FromReflect(typ, nilPtr).Interface().(OptionalNullable[string]) + require.True(t, ok) + assert.True(t, got.IsSet()) + assert.True(t, got.IsNull()) + assert.Equal(t, From[string](nil), got) + }) +} diff --git a/tests/mockserver/internal/sdk/utils/json.go b/tests/mockserver/internal/sdk/utils/json.go index e5aafa7b..6ec0f844 100644 --- a/tests/mockserver/internal/sdk/utils/json.go +++ b/tests/mockserver/internal/sdk/utils/json.go @@ -13,6 +13,7 @@ import ( "time" "unsafe" + "mockserver/internal/sdk/optionalnullable" "mockserver/internal/sdk/types" "github.com/ericlagergren/decimal" @@ -306,6 +307,25 @@ func marshalValue(v interface{}, tag reflect.StructTag) (json.RawMessage, error) return []byte("null"), nil } + // optionalnullable.OptionalNullable[T] must be unwrapped here rather than + // delegated to its own MarshalJSON, so tag-driven wire formats on the field + // (e.g. bigint:"string", decimal:"number") reach the inner value. The + // stored *T is redispatched as-is so pointer-receiver marshalers on T + // stay reachable. + if optionalnullable.IsOptionalNullableType(typ) { + for _, key := range val.MapKeys() { + if key.Bool() { + if inner := val.MapIndex(key); !inner.IsNil() { + if _, innerVal := dereferencePointers(inner.Type(), inner); innerVal.IsValid() { + return marshalValue(inner.Interface(), tag) + } + } + break + } + } + return []byte("null"), nil + } + if implementsJSONMarshaler(v) { return json.Marshal(v) } @@ -410,6 +430,9 @@ func handleDefaultConstValue(tagValue string, val interface{}, tag reflect.Struc } typ := dereferenceTypePointer(reflect.TypeOf(val)) + if optionalnullable.IsOptionalNullableType(typ) { + typ = dereferenceTypePointer(typ.Elem()) + } switch typ { case reflect.TypeOf(time.Time{}): return []byte(fmt.Sprintf(`"%s"`, tagValue)) @@ -511,6 +534,27 @@ func unmarshalValue(value json.RawMessage, v reflect.Value, tag reflect.StructTa return nil } case reflect.Map: + // optionalnullable.OptionalNullable[T] is unwrapped like on the marshal + // side, so tag-driven wire formats reach the inner value. A JSON null + // never gets this far: it is handled at the top of this function, where + // the wrapper's own UnmarshalJSON records the explicit null state. + if optionalnullable.IsOptionalNullableType(typ) { + innerPtr := reflect.New(typ.Elem().Elem()) + + if err := unmarshalValue(value, innerPtr, tag); err != nil { + return err + } + + if v.Kind() == reflect.Ptr { + if v.IsNil() { + v.Set(reflect.New(typ)) + } + v = v.Elem() + } + v.Set(optionalnullable.FromReflect(typ, innerPtr)) + return nil + } + if bytes.Equal(value, []byte("null")) || !isComplexValueType(dereferenceTypePointer(typ.Elem())) { if v.CanAddr() { return json.Unmarshal(value, v.Addr().Interface()) diff --git a/tests/test_admin_usage.py b/tests/test_admin_usage.py new file mode 100644 index 00000000..cd05e939 --- /dev/null +++ b/tests/test_admin_usage.py @@ -0,0 +1,83 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from glean.api_client import Glean, models +import os +from tests.test_client import create_test_http_client + + +def test_admin_usage_platform_admin_usage_settings_get(): + test_http_client = create_test_http_client("platform-admin-usage-settings-get") + + with Glean( + server_url=os.getenv("TEST_SERVER_URL", "http://localhost:18080"), + client=test_http_client, + api_token=os.getenv("GLEAN_API_TOKEN", "value"), + ) as glean: + assert glean is not None + + res = glean.admin.usage.get_settings() + assert res is not None + + +def test_admin_usage_platform_admin_usage_settings_update(): + test_http_client = create_test_http_client("platform-admin-usage-settings-update") + + with Glean( + server_url=os.getenv("TEST_SERVER_URL", "http://localhost:18080"), + client=test_http_client, + api_token=os.getenv("GLEAN_API_TOKEN", "value"), + ) as glean: + assert glean is not None + + res = glean.admin.usage.update_settings( + request={ + "limit_increase_requests": { + "business_justification": models.BusinessJustification.REQUIRED, + }, + } + ) + assert res is not None + + +def test_admin_usage_platform_admin_usage_requests_create(): + test_http_client = create_test_http_client("platform-admin-usage-requests-create") + + with Glean( + server_url=os.getenv("TEST_SERVER_URL", "http://localhost:18080"), + client=test_http_client, + api_token=os.getenv("GLEAN_API_TOKEN", "value"), + ) as glean: + assert glean is not None + + res = glean.admin.usage.create_limit_increase_request( + agent_id="", client_id="" + ) + assert res is not None + + +def test_admin_usage_platform_admin_usage_requests_list(): + test_http_client = create_test_http_client("platform-admin-usage-requests-list") + + with Glean( + server_url=os.getenv("TEST_SERVER_URL", "http://localhost:18080"), + client=test_http_client, + api_token=os.getenv("GLEAN_API_TOKEN", "value"), + ) as glean: + assert glean is not None + + res = glean.admin.usage.list_limit_increase_requests(page_size=20) + assert res is not None + + +def test_admin_usage_platform_admin_usage_requests_get(): + test_http_client = create_test_http_client("platform-admin-usage-requests-get") + + with Glean( + server_url=os.getenv("TEST_SERVER_URL", "http://localhost:18080"), + client=test_http_client, + api_token=os.getenv("GLEAN_API_TOKEN", "value"), + ) as glean: + assert glean is not None + + res = glean.admin.usage.get_limit_increase_request(request_id="{request_id}") + assert res is not None diff --git a/tests/test_entities.py b/tests/test_entities.py index b6c97f06..1dac6d8f 100644 --- a/tests/test_entities.py +++ b/tests/test_entities.py @@ -52,10 +52,11 @@ def test_entities_people(): assert glean is not None res = glean.client.entities.read_people( + fallback_to_authenticated_identity=False, obfuscated_ids=[ "abc123", "abc456", - ] + ], ) assert res is not None diff --git a/tests/test_messages.py b/tests/test_messages.py index 132005ec..636f01d3 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.GCHAT, timestamp_millis=558834, ) assert res is not None diff --git a/tests/test_skills.py b/tests/test_skills.py index 63587d5a..1c854370 100644 --- a/tests/test_skills.py +++ b/tests/test_skills.py @@ -34,7 +34,7 @@ def test_skills_platform_skills_list(): ) as glean: assert glean is not None - res = glean.skills.list() + res = glean.skills.list(page_size=20) assert res is not None @@ -115,7 +115,7 @@ def test_skills_platform_skills_list_versions(): ) as glean: assert glean is not None - res = glean.skills.list_versions(skill_id="") + res = glean.skills.list_versions(skill_id="", page_size=20) assert res is not None @@ -176,7 +176,7 @@ def test_skills_platform_skills_preview_source(): assert glean is not None res = glean.skills.preview_source( - source_url="https://github.com/anthropics/skills", stream=False + source_url="https://github.com/anthropics/skills" ) assert res is not None diff --git a/tests/test_summarize.py b/tests/test_summarize.py index cac8e978..1a308526 100644 --- a/tests/test_summarize.py +++ b/tests/test_summarize.py @@ -18,12 +18,12 @@ def test_summarize_summarize(): res = glean.client.documents.summarize( document_specs=[ { - "ugc_type": models.DocumentSpecUgcType1.SHORTCUTS, - "content_id": 602763, + "ugc_type": models.DocumentSpecUgcType2.ARTIFACTS, + "ugc_id": "", }, { - "ugc_type": models.DocumentSpecUgcType1.SHORTCUTS, - "content_id": 602763, + "ugc_type": models.DocumentSpecUgcType2.ARTIFACTS, + "ugc_id": "", }, ] ) diff --git a/tests/test_usage.py b/tests/test_usage.py new file mode 100644 index 00000000..15e14c7d --- /dev/null +++ b/tests/test_usage.py @@ -0,0 +1,47 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" + +from glean.api_client import Glean +import os +from tests.test_client import create_test_http_client + + +def test_usage_platform_usage_requests_create(): + test_http_client = create_test_http_client("platform-usage-requests-create") + + with Glean( + server_url=os.getenv("TEST_SERVER_URL", "http://localhost:18080"), + client=test_http_client, + api_token=os.getenv("GLEAN_API_TOKEN", "value"), + ) as glean: + assert glean is not None + + res = glean.usage.create_limit_increase_request(client_id="") + assert res is not None + + +def test_usage_platform_usage_requests_list(): + test_http_client = create_test_http_client("platform-usage-requests-list") + + with Glean( + server_url=os.getenv("TEST_SERVER_URL", "http://localhost:18080"), + client=test_http_client, + api_token=os.getenv("GLEAN_API_TOKEN", "value"), + ) as glean: + assert glean is not None + + res = glean.usage.list_limit_increase_requests(page_size=20) + assert res is not None + + +def test_usage_platform_usage_requests_get(): + test_http_client = create_test_http_client("platform-usage-requests-get") + + with Glean( + server_url=os.getenv("TEST_SERVER_URL", "http://localhost:18080"), + client=test_http_client, + api_token=os.getenv("GLEAN_API_TOKEN", "value"), + ) as glean: + assert glean is not None + + res = glean.usage.get_limit_increase_request(request_id="{request_id}") + assert res is not None