diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock index 5587955b..2b90cdb5 100644 --- a/.speakeasy/gen.lock +++ b/.speakeasy/gen.lock @@ -1,19 +1,19 @@ lockVersion: 2.0.0 id: 2d045ec7-2ebb-4f4d-ad25-40953b132161 management: - docChecksum: a0fa9ebdce4c9ca7549f9dce826a2169 + docChecksum: 96c7f58782c479be9d01e672f4e1896e docVersion: 1.0.0 - speakeasyVersion: 1.761.1 - generationVersion: 2.879.6 - releaseVersion: 2.4.5 - configChecksum: f6852fb59e3bcc9a7750210521f2c2d4 + speakeasyVersion: 1.763.6 + generationVersion: 2.884.13 + releaseVersion: 2.4.7 + configChecksum: c43f0f203b291067c934034351c7f55b repoURL: https://github.com/mistralai/client-python.git installationURL: https://github.com/mistralai/client-python.git published: true persistentEdits: - generation_id: bcab0c88-1877-4209-a77d-49b4681f030e - pristine_commit_hash: 56d30233849b5a3cb3d207e646ee849c77835f70 - pristine_tree_hash: 3feb3429dfead0d0228262509f23a6c5e9c9c7a2 + generation_id: 20a111e0-4460-4e9f-a244-c024f0db9cd1 + pristine_commit_hash: 8b079c23ee4d603974156f6cf7568878c39a4cb9 + pristine_tree_hash: c20b64fba0f8471688502f9d39a78f2b6c60eeb8 features: python: acceptHeaders: 3.0.0 @@ -21,15 +21,15 @@ features: additionalProperties: 1.0.1 configurableModuleName: 0.2.0 constsAndDefaults: 1.0.7 - core: 6.0.21 - customCodeRegions: 0.1.1 + core: 6.0.22 + customCodeRegions: 0.1.2 defaultEnabledRetries: 0.2.0 deprecations: 3.0.2 downloadStreams: 1.0.1 enumUnions: 0.1.1 - envVarSecurityUsage: 0.3.2 - errors: 3.3.5 - examples: 3.0.3 + envVarSecurityUsage: 0.3.3 + errors: 3.3.6 + examples: 3.0.4 flatRequests: 1.0.1 flattening: 3.1.1 globalSecurity: 3.0.7 @@ -43,14 +43,14 @@ features: nullables: 1.0.2 openEnums: 1.0.4 operationTimeout: 0.3.1 - pagination: 3.0.9 + pagination: 3.0.10 responseFormat: 1.1.0 - retries: 3.0.4 + retries: 3.0.5 sdkHooks: 1.2.1 serverEvents: 1.0.15 serverEventsSentinels: 0.1.0 serverIDs: 3.0.0 - unions: 3.1.4 + unions: 3.1.5 uploadStreams: 1.0.0 trackedFiles: .gitattributes: @@ -64,7 +64,7 @@ trackedFiles: deleted: true USAGE.md: id: 3aed33ce6e6f - last_write_checksum: sha1:d172deb3ee1630f16b279de22aec1f8f68d7565f + last_write_checksum: sha1:a301895a264e69dc11007de5f8c7c2e675cbdf5b pristine_git_object: 9d32240a60c8885479c95388bb81c8024b5604ff docs/errors/httpvalidationerror.md: id: 7fe2e5327e07 @@ -340,8 +340,8 @@ trackedFiles: pristine_git_object: d0784e66112b8f79036d1acff2a7fc242058e4a0 docs/models/authenticationconfiguration.md: id: b470496ac0ad - last_write_checksum: sha1:650e1e889d037f79a87c8ab0a679e245c2ddbb4b - pristine_git_object: 6644875efdc48b462a98193b391dc23e1f31b2c3 + last_write_checksum: sha1:0ea76a9e5fb98d46a27be52d95a0195fa9ee2df0 + pristine_git_object: cdd1e55fed41e8bc8914e90f912d9cc4a04920f1 docs/models/authorization.md: id: dec4d9809e25 last_write_checksum: sha1:6bf766a7b49ca2b706bb4eb88ba2d56406e06e1e @@ -440,7 +440,7 @@ trackedFiles: pristine_git_object: 5bcec6a085b8fe921efb44ab5f040faf99cff7a3 docs/models/chatcompletionrequest.md: id: adffe90369d0 - last_write_checksum: sha1:3e240059856e4445d9b76934806b172021174889 + last_write_checksum: sha1:09207e72df2645b7923b375778ddc7273e44af07 pristine_git_object: ad1b3d3912f04750172ebb0c5776215b716b96f9 docs/models/chatcompletionrequestmessage.md: id: 3f5e170d418c @@ -464,7 +464,7 @@ trackedFiles: pristine_git_object: a0465ffbfc5558628953e03fbc53b80bbdc8649b docs/models/chatcompletionstreamrequest.md: id: cf8f29558a68 - last_write_checksum: sha1:0d243eb67aa8e905e88463d9b745bda2030d415c + last_write_checksum: sha1:c93c7401cedf4030f38002cef2c89515a6441d64 pristine_git_object: 7288c818d03f0c672d99a2c61ea19cce4fd39654 docs/models/chatcompletionstreamrequestmessage.md: id: 053a98476cd2 @@ -562,6 +562,18 @@ trackedFiles: id: 9370e1ccd3d5 last_write_checksum: sha1:31a490471292a397e7e7526f2f724fcb743e65d1 pristine_git_object: 6c6da1bd74aa8c67cc40307a88ffac1db1957f3a + docs/models/clientcapabilities.md: + id: e1f291b21fc8 + last_write_checksum: sha1:4647f66510f48e7c2199a8c3c50f7e664fbbb485 + pristine_git_object: 236bb0c43de9d7de80cc85e48b1f1fe9b13daaec + docs/models/clienttaskscapability.md: + id: addb004fe61a + last_write_checksum: sha1:0e28bfef73308db54d12e8ce6e6f4a82a8513990 + pristine_git_object: 9008ba6146d9d870f151453b4fa8dc007177b1b4 + docs/models/clienttasksrequestscapability.md: + id: ee000ce4eb5e + last_write_checksum: sha1:1bf8b73e26543deb358fd8b3395858d902312953 + pristine_git_object: 8dac48a4c3041a3c7c84fe0edecde794a81ebbb6 docs/models/codeinterpretertool.md: id: f009740c6e54 last_write_checksum: sha1:a2114d61a98a48b4365a77c0c75c06ca834367ad @@ -638,14 +650,34 @@ trackedFiles: id: 19b9e48a3c2e last_write_checksum: sha1:6e199c756ce35e2bff3b67df5d97b4520518b271 pristine_git_object: c87093846ca27940a08318fb090c60ce56a00651 + docs/models/connectionconfigtype.md: + id: 3b346ef828ff + last_write_checksum: sha1:e3077c8da9145cce4b4b92688308c97aa9a05a19 + pristine_git_object: 8db3ea6401a0ff1ee19824726704ec21c3953b85 docs/models/connectioncredentials.md: id: 1aa13b29ae25 last_write_checksum: sha1:1fbc7ca6daa21f093853cda8385fd63b031bb653 pristine_git_object: 7e89239996c86952aa3ddf7520c0a73858b31725 + docs/models/connectionpreference.md: + id: be469697273b + last_write_checksum: sha1:f59d85167c69837a67f05e190a8efdd2feaa723f + pristine_git_object: e069233ff9f42a6b13e356985e3bc3819128b970 docs/models/connector.md: id: cbf7c2c53983 - last_write_checksum: sha1:933fcdfbded00c65d36e46d6b2e18e56540802fe - pristine_git_object: 29f8ad0771bf8da6999345b78322001c3821a6ca + last_write_checksum: sha1:7694fec24017b429b23d5b42f29a2d66d6f8aa50 + pristine_git_object: 45aafa1e2d539276d23688d6b36c503650ecb454 + docs/models/connectoractivatefororganizationv1request.md: + id: 3a15b69f7e51 + last_write_checksum: sha1:ae29bb24fdf11ccf8c08e2a1a2909d55d4cbaf6c + pristine_git_object: 40469996995ac4e446584780ac77981a0a5c67bc + docs/models/connectoractivateforuserv1request.md: + id: a4645ace44a1 + last_write_checksum: sha1:c4302c00ee924529d626c75ecb9374b416bcb028 + pristine_git_object: bdf73b8aca4293b69ef96f3c72f0acbf5d7546b7 + docs/models/connectoractivateforworkspacev1request.md: + id: da9da37e67ba + last_write_checksum: sha1:c7b677341c095afaac4adaeacd9e7337307e3174 + pristine_git_object: e4dbaf1dbf5632919eb3cc8fac7aa67ceee01e1c docs/models/connectorauthenticationheader.md: id: bb5e842caa63 last_write_checksum: sha1:7c721f916ed1ce2d4155734bb8190e11de6bf4ac @@ -670,6 +702,18 @@ trackedFiles: id: 10c159720bae last_write_checksum: sha1:e86b1952360e4f41550603b9dc16fddeff6127e7 pristine_git_object: 310cdcde0039e9fdb4faa53644265a6a614d9b20 + docs/models/connectordeactivatefororganizationv1request.md: + id: c4310041f3ab + last_write_checksum: sha1:a1ae31f8e5b836d9300ff4e64ecc2a11c9db7a7f + pristine_git_object: 1fd64004b3bd61e1ff3f789566bc3e587f2e2cf8 + docs/models/connectordeactivateforuserv1request.md: + id: 72bcb9fcabe5 + last_write_checksum: sha1:02be33e6a0ed87d60d7e8130c80e85426b2f1db7 + pristine_git_object: 992603b0f86d60714acded1498c661d170b0e40a + docs/models/connectordeactivateforworkspacev1request.md: + id: 42c92923f1ae + last_write_checksum: sha1:f4f8dbfde3ca68ae68028ddce150dc9761bf3a24 + pristine_git_object: 15033f293dcbb35daef48119419bedd779d8f06a docs/models/connectordeleteorganizationcredentialsv1request.md: id: 922f5267f2c0 last_write_checksum: sha1:23af2d809a20c093ece79bcd1e6ebc551be4b368 @@ -696,8 +740,8 @@ trackedFiles: pristine_git_object: 7d6b94ff09be0d4bf2f062fa039551ab0735fc13 docs/models/connectorgetv1request.md: id: 844c1f489684 - last_write_checksum: sha1:e36ac8ff28ee258340868f8aa4f3172ed3b82ef3 - pristine_git_object: c45148b97aad128744e0e6ccebb00bf22d400eff + last_write_checksum: sha1:446e9132766caec5d1ab49c2654696c571deef53 + pristine_git_object: 35a6f39334ffa87c7ada3ce89e7fe7b9ee612d3d docs/models/connectorlistorganizationcredentialsv1request.md: id: cc1870566c72 last_write_checksum: sha1:633bb13df6fa25f746a9aa905da3f3beb75ff91a @@ -718,10 +762,18 @@ trackedFiles: id: c7f5827917c6 last_write_checksum: sha1:dfe772567d14a0552eec2e53ebf9c1ed6c39ab3e pristine_git_object: 573869b2483b15da829b25e1863652680deb6a36 + docs/models/connectorlocale.md: + id: fe553a89ff06 + last_write_checksum: sha1:3bddb7128d7cf99124a07054d3a6e8c90d22755b + pristine_git_object: c2e7cf5b57f2c7d764e46633eeeebb73a9329422 + docs/models/connectorprotocol.md: + id: a140d41a5740 + last_write_checksum: sha1:e856a50288aefdb1adc2c803a3a6d280b31892ed + pristine_git_object: 77d2845854756c3025aabef138c2a160758e0816 docs/models/connectorsqueryfilters.md: id: d6fb981cad1e - last_write_checksum: sha1:3a33088e1e9332318aff437fba7d01239d417d84 - pristine_git_object: aea47e14f02b61dbbd726bc11f6197b6854bb358 + last_write_checksum: sha1:01782d52446d8e7e53c72094b2ff86b6fe600ee4 + pristine_git_object: 37c19e7a9d2c4bb41a77a8c13936024c9d218d08 docs/models/connectortool.md: id: 1c640bab9aeb last_write_checksum: sha1:ab4ad137330bda6699043da2337aea477c33241e @@ -750,6 +802,10 @@ trackedFiles: id: fdbeb5fee83e last_write_checksum: sha1:9082d8f0cfe9f950d129971b152d37f936f7aaea pristine_git_object: db9cc9b4c4379865ad15292c5385dce864b5935b + docs/models/consumertype.md: + id: d7e5c7974261 + last_write_checksum: sha1:4012cffe5553431d50539a9e4663a935b5cb00cb + pristine_git_object: 9ac4df3f4993e81c99ddfcb91c0b32b04730da7f docs/models/contentchunk.md: id: d2d3a32080cd last_write_checksum: sha1:b253e4b802adb5b66d896bfc6245ac4d21a0c67c @@ -888,8 +944,8 @@ trackedFiles: pristine_git_object: 2e81d26d19950ef6c1bc7186b8497e1f739e8f0b docs/models/createconnectorrequest.md: id: 7a0ef9d82658 - last_write_checksum: sha1:f28eb17d562ab9b881f4c0c640f0b16163ada6dc - pristine_git_object: 111c460a711c1d971a300afda6afe4da608e6d21 + last_write_checksum: sha1:fbc8c1928dfbd1a63792caa0e790685b99643b21 + pristine_git_object: eb14f58529e50cb58388f0d8b8b0f438640d7145 docs/models/createdatasetrecordrequest.md: id: e2c8a858a8e6 last_write_checksum: sha1:6848c7398d763f7a046dbb41cda8bc33cbb98230 @@ -936,8 +992,28 @@ trackedFiles: pristine_git_object: a72676719b90a7b840a2b21d043c61bdf83ce294 docs/models/createlibraryrequest.md: id: 8935b2ed9d13 - last_write_checksum: sha1:14480a2eb03a9e5076a866a21bff0dfd80bb585d - pristine_git_object: 07ff97d0cbaf4f3e260cce4b80fcbd637cc6b488 + last_write_checksum: sha1:1bc8b8f3827425b63bf25b6662d959274f266679 + pristine_git_object: fd94c1caf6dbe31da9b0494879027cba9dbbb6c3 + docs/models/createsearchindexinforequest.md: + id: 886f7c48f467 + last_write_checksum: sha1:b36cd8692b7b93f54560de1bc1cb323e466365b1 + pristine_git_object: 64b22aa43173f98dd98cafb7e26c6b63b12a117c + docs/models/createsearchindexinforequestindex.md: + id: 846e92f3d7f2 + last_write_checksum: sha1:abb7ce51a4a6f86ab5b5e7e6cf484b4061fa7022 + pristine_git_object: 42d99fcb5ef07be40f6d7f34dd08dd56165a69ca + docs/models/createsearchindexinforequeststatus.md: + id: 79a895401c56 + last_write_checksum: sha1:8388b45338b7744a8da74f019c0552eb1172cdaa + pristine_git_object: 1e477acc2610b127f09ced4748e72d5886812b3e + docs/models/createvespaschemarequest.md: + id: 5d582f9abac3 + last_write_checksum: sha1:f760192840beb2436d5505ea2d095501956a08be + pristine_git_object: 3098a2b9dc2ca9c592fce287daae7e5b6a6ed974 + docs/models/createvespasearchindexinforequest.md: + id: a34bf5ca3f0b + last_write_checksum: sha1:562b8ae886bafa4ae587b724007ff3a6205dd20b + pristine_git_object: 0bd47c383aa7df413c1a63dfaeec09582b7bd8d6 docs/models/credentialscreateorupdate.md: id: b2a0e87b0a91 last_write_checksum: sha1:6b778120a84c08601b4f2fbba368d3454204d939 @@ -1084,8 +1160,8 @@ trackedFiles: pristine_git_object: afdcca834da74cc33711b1aa229f5ccf66eceefd docs/models/document.md: id: cd1d2a444370 - last_write_checksum: sha1:c10641b02547bedcc982b8997097083dfc562598 - pristine_git_object: 42c639a6a9b235ab4c754286486fa7e8872a0e7e + last_write_checksum: sha1:7aeb84c1a0efa2b3bf15808714405fe29b930296 + pristine_git_object: ff0238ea7afcba3ef690a303574f74744ba31ecd docs/models/documentlibrarytool.md: id: 68083b0ef8f3 last_write_checksum: sha1:76b9f47c399915a338abe929cb10c1b37282eadf @@ -1106,6 +1182,10 @@ trackedFiles: id: 48437d297408 last_write_checksum: sha1:5f9294355929d66834c52c67990ba36a7f81387d pristine_git_object: 9dbfbe5074de81b9fcf6f5bae8a0423fb2c82f71 + docs/models/elicitationcapability.md: + id: bc87da9c6248 + last_write_checksum: sha1:8654e0b4df9d2fb9cbf283b3dc519317337fe5b2 + pristine_git_object: c2f8fab6ac866c2e1f9cd4f51c1255b95a0e24b3 docs/models/embeddedresource.md: id: f7ea3888f520 last_write_checksum: sha1:8f0869b4403767c45c464cdd7b6c640994c65ab9 @@ -1138,6 +1218,10 @@ trackedFiles: id: 066e154e4d43 last_write_checksum: sha1:cc98abdb803d374146f58a6811c9e3f2b58ff5f3 pristine_git_object: 8bc9e8c6bd3fdc8bd5a28edb381c662e74c86e72 + docs/models/encryptedpatchvalue.md: + id: 8fdf9deac4d8 + last_write_checksum: sha1:e13686983658d34b32ecd1111e8c974cd1ed0944 + pristine_git_object: 1d5988b426d619813a1b34e19b2654b6a1593492 docs/models/entitytype.md: id: 130a2f7038b0 last_write_checksum: sha1:506be1dd51ec1f429246390757cbc0676677bd82 @@ -1182,6 +1266,10 @@ trackedFiles: id: 16660f92d7d1 last_write_checksum: sha1:fa22e53a929291e6b057283482ca7871fb6d2062 pristine_git_object: efe4bbb058c168ad531be27cc135f09464d0da13 + docs/models/expression.md: + id: 84d49a7056b1 + last_write_checksum: sha1:8f871b9f64754b138edaabbd8f64895376694881 + pristine_git_object: d7de83a9d4fad318d2e30f7718bf9b529a367158 docs/models/failure.md: id: 3f79c7d64eac last_write_checksum: sha1:344f1cea9b786a399a0dd974d4df010714031b2a @@ -1434,6 +1522,22 @@ trackedFiles: id: ac9de7c67a5f last_write_checksum: sha1:40fa492321f18e77792d49cb9142b0293be7ffe3 pristine_git_object: 6b03369064e2bb2fedffa606d8bff20d9fceae00 + docs/models/getschedulesv1workflowsschedulesgetrequest.md: + id: ee97a7eb1a05 + last_write_checksum: sha1:07207cb74124d3e2085d26c5c609f0bef3b6ad54 + pristine_git_object: d510c27db9c7b0b495a578c0caee3428a3794e1a + docs/models/getschedulesv1workflowsschedulesgetresponse.md: + id: b6b4b4eebe6e + last_write_checksum: sha1:07a546ef6090188411e55380341fa6fc6377c752 + pristine_git_object: 20adb3c0077a2a281efa4f44701eb6572f61760a + docs/models/getschedulesv1workflowsschedulesgetstatus.md: + id: a6a5de21aca0 + last_write_checksum: sha1:62ce31cbd6d3ad06ee26ad32def445ed6b2dad89 + pristine_git_object: 312db2cd5d8796e2b899a9fd5dac38841e1b0383 + docs/models/getschedulev1workflowsschedulesscheduleidgetrequest.md: + id: 52b58a6705e8 + last_write_checksum: sha1:d4af59b2276baf70a151680d2276c71a6944fe43 + pristine_git_object: e681e674a011fcd31373c4885c862717a04a6b6f docs/models/getsignedurlresponse.md: id: 5539e5d7c3d4 last_write_checksum: sha1:7198474f48bfba6d47326cd436e4a00a8ba70ce3 @@ -1664,8 +1768,12 @@ trackedFiles: pristine_git_object: 2a091c8ac8bfb57bfada1ce173c75543c9431fd0 docs/models/jsonpatchappend.md: id: 5d68c9614b70 - last_write_checksum: sha1:c1d5ac89195b6712b8a4b61450450a4f9b0e910e - pristine_git_object: 684cc896b4ba80ba1bbc278e119fc9fc1dbbf924 + last_write_checksum: sha1:e6e0a45d6be613281a10b369fc686e8e0d56ff9f + pristine_git_object: 903d6c71854e89340b7508c735fe2251720cd364 + docs/models/jsonpatchappendvalue.md: + id: a822d0b58ec8 + last_write_checksum: sha1:832c839f2cb2e065c731efddf86112bb7efdb6e5 + pristine_git_object: 551cafe15bd959b9d4db9a809b9c7393ae134c65 docs/models/jsonpatchpayloadresponse.md: id: fb6daf532ebb last_write_checksum: sha1:b896fa130e63bfc0831bb8067669df89a8342314 @@ -1776,8 +1884,12 @@ trackedFiles: pristine_git_object: 6febc058425bb38857c391ee4c40d600858e6058 docs/models/librariesdocumentslistv1request.md: id: 7b5756e50d64 - last_write_checksum: sha1:2605b7972a3d7b4f73ab8052be4bf740f44f6f6f - pristine_git_object: 44f6300115853053214639982516a60b3268e778 + last_write_checksum: sha1:b01fbfcbdb622ba35e52cfd0884d75d7ef5a192b + pristine_git_object: 6149336fc296c6ff3c61e4f61f36fe4c33c8c465 + docs/models/librariesdocumentspatchv1request.md: + id: 2815453b5023 + last_write_checksum: sha1:0ded124e8b094e78b404d1a1cdc1e7b5cffef555 + pristine_git_object: 511aee46a2ed2db98101c10d69288732807b0132 docs/models/librariesdocumentsreprocessv1request.md: id: 1b8bf57b3f0a last_write_checksum: sha1:8528785c1b4ae18d6ec6f261d29d5daac0d420a3 @@ -1796,8 +1908,12 @@ trackedFiles: pristine_git_object: 6e1e04c39c15a85d96710f8d3a8ed11a22412816 docs/models/librarieslistv1request.md: id: eb6047c126d3 - last_write_checksum: sha1:7bd4a00dfe54162bd3c315ca0ab2990133969390 - pristine_git_object: 37352ee1277aa9576da968ce44b0ffda772715f7 + last_write_checksum: sha1:dd42520f540d9e5c1820d517be4e4a894475ece1 + pristine_git_object: 5efdb897a19d6ad920a031472ba88098c4f80630 + docs/models/librariespatchv1request.md: + id: a5c8a22e9d7c + last_write_checksum: sha1:fc18a3c812d877f8bd47f6a34bbc3d29e5420519 + pristine_git_object: 4764808653f0d841f87e58ca71ec9549f2c1af1f docs/models/librariessharecreatev1request.md: id: 99e7bb8f7fed last_write_checksum: sha1:f37578c7882eab83cca3cb2aaf1ac17b9a21934c @@ -1816,8 +1932,8 @@ trackedFiles: pristine_git_object: c5c142db7aaa49990135c21eabde43b8c0fdf756 docs/models/library.md: id: e8ec114dd107 - last_write_checksum: sha1:5434149d101255cb5135f8726acdcfb29c4381bd - pristine_git_object: a07d3afac18faccb504c51f1a54cf5addc3faab3 + last_write_checksum: sha1:9331e004d3587e261e9f7496525dc698db37db3f + pristine_git_object: 5b9aa658712ffad94a9c2b7f1595d1c232868870 docs/models/listbatchjobsresponse.md: id: e03025d58630 last_write_checksum: sha1:de42c9396546fc8487d0bd6ed15b4076599fa83f @@ -1918,22 +2034,62 @@ trackedFiles: id: e25e2392c4c9 last_write_checksum: sha1:647413204680efd677ce7746101b74e2ad7d59d5 pristine_git_object: 6daecdd1eb31ad2d80400b4eb9032f635f0bc889 + docs/models/logicalexpression.md: + id: f222e869e12b + last_write_checksum: sha1:cec26b10026b2245d92356fbe81cece3645de577 + pristine_git_object: 675368e79b0723713a27064cc56814c951d91616 + docs/models/logicalexpressiontype.md: + id: 61eee1af8d4c + last_write_checksum: sha1:7e78778f1a304d226f752ebb6d023654ced7866b + pristine_git_object: 0d3c1f78c1c8cc90a466d876b2d54f156d8ba7d9 + docs/models/mcpprompt.md: + id: c6eeb6a6a719 + last_write_checksum: sha1:321ce6a140536a8582632d937f498b2fd8006a7b + pristine_git_object: b68d0046a0c236a5471f03e5edb892c8dde2c2a0 + docs/models/mcpresource.md: + id: 643d9dfa9a7b + last_write_checksum: sha1:44be038071e200307677b355dfe5b54d574a6ece + pristine_git_object: ac3d92a8fbdeb583d38d7da18ed839235452219a + docs/models/mcpserverauthenticationrequirement.md: + id: 7540ae50c0bb + last_write_checksum: sha1:37c7585e48212e64bc1794f6f853b1ce5071c09e + pristine_git_object: a3824be670aba370256208b6f4f0faf95af40ece + docs/models/mcpservercard.md: + id: ff9347d08f2f + last_write_checksum: sha1:36600ab72bc9050bccc4c5999ce4add9df67526d + pristine_git_object: ebc72b07a50aef53b94c6df9e643d673368db54d + docs/models/mcpservercardmeta.md: + id: c2f4503daa2f + last_write_checksum: sha1:4ec024c2276b28ce39e7345a414726bdcddd72b4 + pristine_git_object: 52345bcfc5cdff0d1c81609a0ade92f34c27526a docs/models/mcpservericon.md: id: 0b20f03adab8 last_write_checksum: sha1:d66113a4b0486f144b1f73f423559360ec751631 pristine_git_object: b0ae7da069119f7477ffa5ad756f353f56f213f1 + docs/models/mcpserverremote.md: + id: 56a47d36028f + last_write_checksum: sha1:36df87e25d5f271cf3602e91a8b5279ddfeda66d + pristine_git_object: 1c7c4de3ccfbe7f5b1f576ae1090362bab2f1e8a + docs/models/mcpserverremoteheader.md: + id: 23d6af542948 + last_write_checksum: sha1:640a69c9758c7d3b5fbe1a1563fa80a0fe978982 + pristine_git_object: a3966a54fe6f51dff8cf85bf501ecd6c4ef47c69 + docs/models/mcpserverremotetype.md: + id: 1347827838d3 + last_write_checksum: sha1:2d1f8c2455bf84877adbcd6807ec3e06e6bb1f99 + pristine_git_object: ea4585b6aa78fb82a8abbce90caec84cee2a08d9 + docs/models/mcpserverrepository.md: + id: 5440c78d09c6 + last_write_checksum: sha1:e5979de6f7ebdeb6f3b539ea952f6c415cb9a1b5 + pristine_git_object: 16fbdd189465350a09846ab3e84699d181faffed docs/models/mcptool.md: id: f809e227a108 last_write_checksum: sha1:90833e29c750ca8452cec010f91e451ead93049c pristine_git_object: 006802b47caa662f9087357bf7fea45141b76788 docs/models/mcptoolmeta.md: id: 271159bcac6f - last_write_checksum: sha1:f88fc0a6c65c02b9fd6945a9db0b5704eed79c9e - pristine_git_object: 23e8b64c9584f1ef5f2ad56b70d5b57732159608 - docs/models/mcpuitoolmeta.md: - id: 95390caf0719 - last_write_checksum: sha1:e40fd3d493e32bb28fdb0ffc8fa7acb79acc1d30 - pristine_git_object: c09b29ad40fd96b944f7f9bf320b3a67bd587d5b + last_write_checksum: sha1:6734ae688b3c505c94d7b78753085ff18b7aab22 + pristine_git_object: 723f40b1d16eefd324872a0837aa805e1a7dc930 docs/models/messageentries.md: id: 9af3a27b862b last_write_checksum: sha1:a3eb6e37b780644313738f84e6c5ac653b4686bc @@ -2166,6 +2322,10 @@ trackedFiles: id: 592cf80526b8 last_write_checksum: sha1:e72a2238fe984cc4fa0d2522b462aa9ad247af78 pristine_git_object: 7ed17a697771f10febe2b893f092865b09dc04c7 + docs/models/partialscheduledefinition.md: + id: f5bb5dc0cf18 + last_write_checksum: sha1:a0a8d6c43c0231c0e2061de78f5b6e9e233e7c23 + pristine_git_object: e66ee671440d90abcd15860144e6826f5835110b docs/models/pauseschedulev1workflowsschedulesscheduleidpausepostrequest.md: id: 56f6ceab8262 last_write_checksum: sha1:3b5c8e341c685a7f4b2789a9d051eef54ff8cfda @@ -2200,12 +2360,24 @@ trackedFiles: pristine_git_object: fae3c1ca4ba2c2ddb3b7de401ecdc8d56dcc7740 docs/models/processingstatus.md: id: 06047222d2ff - last_write_checksum: sha1:fd2f5d605c6e5f8aa86461e8442c50db3fbea07d - pristine_git_object: 514caa50e524ae5afab802b8394cb27189b2bfbe + last_write_checksum: sha1:81a11724ad214bab81874167854e6cbcb55a6cc0 + pristine_git_object: 1d472b881d684f47ac76edff663ab5fc84581e10 docs/models/processstatus.md: id: "336054835357" last_write_checksum: sha1:43253d2ef4badf3a5e8e5981becfb558c934359a pristine_git_object: 68313743c4d926b2cb29037d0e59a2f9d8d25f1c + docs/models/promptargument.md: + id: 5e744dafa422 + last_write_checksum: sha1:4b7a10005ef27e91c191ab71e76c8ba0eff789aa + pristine_git_object: a8dfdb05a8c424e1e8eee8f44c088de33e8e733c + docs/models/prompts.md: + id: 012697edbda4 + last_write_checksum: sha1:23f02f4461cdaf64ef729ef7dc0395d40f9f5020 + pristine_git_object: 9fe855977ada9474260e8d81d3258faf17393f4b + docs/models/promptscapability.md: + id: a100a874f118 + last_write_checksum: sha1:0f3a7d98fff0ae0b7ddfaedeaa5116cad73c0115 + pristine_git_object: 50ffae2b2ae976f4b21c67eefef9ea1bb1d8fcd9 docs/models/prompttokensdetails.md: id: 1391892fce0a last_write_checksum: sha1:4a82fc483f090e4fc09d19a3f2c0f2a2e022cf3f @@ -2214,6 +2386,10 @@ trackedFiles: id: abfb51fdf794 last_write_checksum: sha1:9be30607f8c895958f33b5be25fc1b8b4cb3d328 pristine_git_object: 59de7076ce05ff71ba4bd5f22112459f4500bf4d + docs/models/publicconnectionconfig.md: + id: e05a024f162c + last_write_checksum: sha1:ab9dd73817a606e22c4d526910771158070e0e4e + pristine_git_object: 56c9ee8ea7ec86a54854cb4f3513646f182b58d0 docs/models/querydefinition.md: id: 4831b7e558f9 last_write_checksum: sha1:f4983c0963906b3eda13c69e2852b08d662dd744 @@ -2294,6 +2470,10 @@ trackedFiles: id: 8857ab6025c4 last_write_checksum: sha1:5634447d01c483713dad3d6d39df182007e6181b pristine_git_object: b710cc1f394e04ecc93c9fc6daddddec366254ad + docs/models/requiresconfirmation.md: + id: 68573b1b41ed + last_write_checksum: sha1:2d0a6d67c74253551cccf3015d599b9557ba5ad1 + pristine_git_object: e7f1e4a653cd7dc5d7f9d9ee4a8661867bea3368 docs/models/resetinvocationbody.md: id: 4063ca65ac51 last_write_checksum: sha1:94c7cd498cba13d4da784c4be76ddbb5b1b64cd9 @@ -2310,6 +2490,18 @@ trackedFiles: id: 1086204e8a19 last_write_checksum: sha1:f1a1c228a16e8e99cd5ff04622455e080418dd6d pristine_git_object: 074c573e64e98cbaf177fde279364f26df04a2bf + docs/models/resources.md: + id: 322aa690f06f + last_write_checksum: sha1:2e0ea1407b59e79451a8521a39ccc06bd5414ce4 + pristine_git_object: cf19612e7e17a683f426678b095b18767e292034 + docs/models/resourcescapability.md: + id: 1efecd9117de + last_write_checksum: sha1:a12afb871ba44408288f3f2ce67428747236286e + pristine_git_object: bbd256d08f16e9a966c107f8eccd762eae70e3b9 + docs/models/resourcetype.md: + id: 4607729e43a1 + last_write_checksum: sha1:241a059f01662088222612170681caed2c01d812 + pristine_git_object: 047f96bb17bfabb811b0315c71c03f373fcc2bfa docs/models/resourcevisibility.md: id: 891d464e9c47 last_write_checksum: sha1:cb0eaebe4e984ab4d999745a142868d2359ab8e4 @@ -2374,10 +2566,18 @@ trackedFiles: id: 2af79e204ed6 last_write_checksum: sha1:10354a9bcbe03a498848de9874b3163cde0fcc05 pristine_git_object: d722e7654427a013da70deb45f1bdb65b55add30 + docs/models/rootscapability.md: + id: 7cc1a16f90b4 + last_write_checksum: sha1:65f29860fb46023e6feb61ed5775d4fef4774a92 + pristine_git_object: f025431df291c6ab11241b2adfd33e5b915488c5 docs/models/sampletype.md: id: 0e09775cd9d3 last_write_checksum: sha1:b77964a7b39ec1b74f70925a39c30b23fad6ac43 pristine_git_object: 31f26c3c2869a453306fff5b062b40e95aa5f19a + docs/models/samplingcapability.md: + id: 79e8183fdc88 + last_write_checksum: sha1:47d5699c46cf60ba3bee396002f1cedfd6f6a9b3 + pristine_git_object: b05fb678df66c767211f42e2d2afeaee72396ac6 docs/models/scalarmetric.md: id: e23b9b990914 last_write_checksum: sha1:272bcac17d958e6d045be0e78ad80aa710d35bb7 @@ -2392,8 +2592,8 @@ trackedFiles: pristine_git_object: 4166bef5ded04c323f5644b80305ed5bb4159fb4 docs/models/scheduledefinition.md: id: 5a795fa1c041 - last_write_checksum: sha1:cbe6e2f2ebaf6bb52be56ffbca6b9d966fdbc2e3 - pristine_git_object: 7d0509f6263ae04d3eb99b65cef0b85adf71aeae + last_write_checksum: sha1:75666aa609a516ed239cfc0f76d8e87df9ebcb5b + pristine_git_object: 93c587409c628018888caa634db7117d86f56c37 docs/models/scheduledefinitionoutput.md: id: e5f8d9d43716 last_write_checksum: sha1:a41e2d99be8b57984e9db632fb17af0212b51e60 @@ -2442,26 +2642,54 @@ trackedFiles: id: e7cb0de862bc last_write_checksum: sha1:d8e860c666fe6b152d3944e9182e90be539c3ce2 pristine_git_object: 9474c1109d62fc5f7ff0bae32d386d54951d7fa2 + docs/models/searchindexresponse.md: + id: 37a2b2687f02 + last_write_checksum: sha1:909f3b19d495ee5e42aa6d7863058496bc58d589 + pristine_git_object: ce6087ec22b4569314dd2d2b596d08c3a183bfd9 + docs/models/searchindexresponseindex.md: + id: 328fcf6e4d24 + last_write_checksum: sha1:2665208de61f9db51eff5018a2a987d2dcc23b9b + pristine_git_object: 3093f4d48f8e527a37a7875bf91356ebaa6cc0b3 + docs/models/searchindexresponsestatus.md: + id: 78dbf9d2a629 + last_write_checksum: sha1:794e6f89be8778c11490fa69bdca3925819e4862 + pristine_git_object: c2200101050e96907f3b4b0d4ea8128ba36328d1 docs/models/security.md: id: 452e4d4eb67a last_write_checksum: sha1:45b7b8881a6560a468153662d61b99605a492edf pristine_git_object: 2e0839d06f821dd97780dc22f202dedf23e4efe1 + docs/models/servercapabilities.md: + id: b798bbcef1a4 + last_write_checksum: sha1:47016476abe0ff79522675df70d5983e354d0b0f + pristine_git_object: 4faca72ea83255c4a31423588a83aa8a183f2b39 + docs/models/serverlocale.md: + id: ea9d0dfa3104 + last_write_checksum: sha1:dd9c7f8896f6085cfbdc127e8fea40d592d748cd + pristine_git_object: a26fcf11b8de7e49375108d2cd775a2b8524440f + docs/models/servertaskscapability.md: + id: 6868e7f8ea87 + last_write_checksum: sha1:817dea2b0064c094f794d1b5ae0d64bbea8c02e9 + pristine_git_object: 9554996dc3f83f1ad3602c12812c4d451e798645 + docs/models/servertasksrequestscapability.md: + id: e4a1bc46b776 + last_write_checksum: sha1:4b65e7809ee82055dc1fedb6885eff2469cd0092 + pristine_git_object: 65c8593c38a0bf6a435223d352e848ea0f88e83a docs/models/shareenum.md: id: 53a713500576 last_write_checksum: sha1:de5c59ca89596a3b28134a9f7318fed3b3e6af02 pristine_git_object: d471b7c3c6700146dc02e20d3aa6205a5025d134 docs/models/sharing.md: id: 9f1e88417a87 - last_write_checksum: sha1:876fd514d08a6987646bf0fec636bf3fef89155b - pristine_git_object: fc718632594e04c682c6d6a3931a94d8b1fd4059 + last_write_checksum: sha1:723c9e8222979149c54d86e1f5bb2c07b5d2963a + pristine_git_object: 922506d31484d7ff3dbd24a696191452222054df docs/models/sharingdelete.md: id: 165cac179416 - last_write_checksum: sha1:1a0b3c95f4b56173510e234d7a76df85c593f360 - pristine_git_object: 1dcec0950c7fcd264ea9369c24244b54ba2bcfbf + last_write_checksum: sha1:ea12c9bfd1f065b9afd882d067d6b50f673c34ae + pristine_git_object: e6e0732bbb1b31e53ea7c4ccd4dad3aa80ccbc19 docs/models/sharingrequest.md: id: cd53ce3913a5 - last_write_checksum: sha1:380d0621a0a8ec9cd4be2b53a6e326b8c9c3d201 - pristine_git_object: 21b8ec1f74c1f903aa087cd3b4d13918c0ea9dad + last_write_checksum: sha1:90a59e17eba146ddc5ccceedc76b65df8235ee31 + pristine_git_object: e92318f812f8fbe66f9a258b68daa38cd1819bbf docs/models/signaldefinition.md: id: 4627d2840cb7 last_write_checksum: sha1:3606a41b67a27350c22aa2bf234d8a8696b23404 @@ -2486,6 +2714,10 @@ trackedFiles: id: 38c985ca6ede last_write_checksum: sha1:f82ac07d517e89bfa8044eebff6f9f7aa56f6c77 pristine_git_object: f65d7924388b842863deddb0e52d4376f2e28925 + docs/models/skipconfirmation.md: + id: 1bf623cd7bb3 + last_write_checksum: sha1:e514f325543c209b0d86b9a445f2c8696f171cfd + pristine_git_object: 48eade7acba08e0189f7405636d67dd0284b8ab6 docs/models/source.md: id: 6541ef7b41e7 last_write_checksum: sha1:00d43797d0155945ec39d4aff068a3ac7bad5ad5 @@ -2570,6 +2802,18 @@ trackedFiles: id: d8cd08c55c3c last_write_checksum: sha1:3ef23d504527602f2d0789d2cfb1a6629115f41a pristine_git_object: 8321a3090910115b586be900bcf23da5baf4c245 + docs/models/taskselicitationcapability.md: + id: e17695a516ab + last_write_checksum: sha1:fc3c19832d82da18d181fbd3a4a519bf4d49e003 + pristine_git_object: f2f3ef81a6731774e867a760c8e9993363c49e57 + docs/models/taskssamplingcapability.md: + id: 93ab84d49981 + last_write_checksum: sha1:cf477e6505da76a158f5c618c7a11fd29439f493 + pristine_git_object: 805d857462acba218480633e4092373f692ae1c2 + docs/models/taskstoolscapability.md: + id: f22fb61bcf93 + last_write_checksum: sha1:7ce2f2029c59001775b44be264b09866e2019569 + pristine_git_object: cd60fe49ca0eaa9e68ff6f75af94953f454a1da1 docs/models/tasksupport.md: id: 58be1f1aef25 last_write_checksum: sha1:2005c0e15f36bd315c17688daa4dd9a8c260b009 @@ -2710,6 +2954,10 @@ trackedFiles: id: 0c47c08eaa46 last_write_checksum: sha1:1af09b39f042e21e47ac09f73301ca9bbb521029 pristine_git_object: 8d385132baca782d1a7ec0d586136a29751f6ec8 + docs/models/toolexecutionconfiguration.md: + id: 24c733cfd29b + last_write_checksum: sha1:41b2d1a96b02852ee366092e9d78194370ed0881 + pristine_git_object: 04981b892381cddd436a5392569a22e2f089b1bf docs/models/toolexecutiondeltaevent.md: id: f2fc876ef7c6 last_write_checksum: sha1:ae1462a9b5cb56002b41f477ce262cb64ccf2f4e @@ -2758,6 +3006,10 @@ trackedFiles: id: f0522d2d3c93 last_write_checksum: sha1:783769c0200baa1b6751327aa3e009fa83da72ee pristine_git_object: 5c76091fbd2c8e0d768921fab19c7b761df73411 + docs/models/toolproperties.md: + id: 02fc3247a741 + last_write_checksum: sha1:9e9d42579412eecb812839ce507788c80ce17533 + pristine_git_object: d85fd8214553575469384250e546e766c9c9aa9c docs/models/toolreferencechunk.md: id: 10414b39b7b3 last_write_checksum: sha1:ea3bdfc83177c6b7183ad51fddb2d15aee0f0729 @@ -2766,10 +3018,14 @@ trackedFiles: id: c2210d74792a last_write_checksum: sha1:368add3ac6df876bc85bb4968de840ac578ae623 pristine_git_object: 999f7c34885015a687c4213d067b144f1585c946 - docs/models/tooltype.md: - id: 5e2ddf7b3863 - last_write_checksum: sha1:3aa9c92e9872fe75032e53e311bf050dbab51e98 - pristine_git_object: 2a64e130e526f8d99e623e7cbc0c7add82d8fab0 + docs/models/tools.md: + id: b78ed2931856 + last_write_checksum: sha1:93076309072b74f5653721c2d66a6acaab093c47 + pristine_git_object: 2f9decd63f1b3ffb8aeb13afe92858ca1a9931ec + docs/models/toolscapability.md: + id: 959506df839b + last_write_checksum: sha1:dd4e8ecca8e44f2f57a12c74a8ecdeb1de34081e + pristine_git_object: 7bde4735f551fb52bf8a6321dc070417cbb9a96a docs/models/trainingfile.md: id: 4039958e8930 last_write_checksum: sha1:d02543c2d1446e56501f2ac358a09669b0077648 @@ -2810,14 +3066,10 @@ trackedFiles: id: 69a13554b554 last_write_checksum: sha1:d969f462034ed356f2c8713b601ee7d873d4ce07 pristine_git_object: 77bd0ddcf8a1d95707fa9e041de3a47bb9e7f56d - docs/models/turbinetoollocale.md: - id: 57197dc9a955 - last_write_checksum: sha1:8ec2a585bfc0f5dca7bbad5fe143d21b9e5f6cb8 - pristine_git_object: 283dd339629448669557acf2d6eda10dea735421 - docs/models/turbinetoolmeta.md: - id: f99b41288e88 - last_write_checksum: sha1:092cd9ae293706419a86fd69c490cbc6587965d3 - pristine_git_object: 2f61a2c4d8be1634ccbb1ef0adacde0c6722a9bd + docs/models/turbinemeta.md: + id: 1f7f944fef63 + last_write_checksum: sha1:38dd2a9a68f8b938dbf6c3c43470e5986204bf08 + pristine_git_object: d5e48e38eaa3c247c6e09b25c9d4a15790937715 docs/models/unarchivemodelresponse.md: id: a690f43df567 last_write_checksum: sha1:5c9d4b78c92d30bb4835cb724d1ea22a19bf5327 @@ -2840,8 +3092,8 @@ trackedFiles: pristine_git_object: cf590a2fc7f58707855eb0bda2d4b8460bfea800 docs/models/updateconnectorrequest.md: id: 40e38d9c7c2a - last_write_checksum: sha1:03a8cd1c8d6415b26cdf592534ba09c022a5414e - pristine_git_object: 335588eac79ddbd851ead9950f3681f7dda90ee3 + last_write_checksum: sha1:5c78fcc8ea7aff991588911d5f9bd7e568d77495 + pristine_git_object: 7a267df3d91de7d9cd97c3d53b6fae75509cf8c8 docs/models/updatedatasetrecordpayloadrequest.md: id: ada11a6c544f last_write_checksum: sha1:220ce1184c9f6b6c6d1e5cdf2dc18197778f7af2 @@ -2872,8 +3124,8 @@ trackedFiles: pristine_git_object: 8cf62617303949d2633773af0268447befb04af2 docs/models/updatedocumentrequest.md: id: ee4e094a6aa7 - last_write_checksum: sha1:09171d42fdac0060276af58c5f036cb5714709d3 - pristine_git_object: dd06dd4b43b72ee73faf0bb2d39edf22889c0780 + last_write_checksum: sha1:33a21ce8b03db36d05ec02f7f3fdc5d5ab95f344 + pristine_git_object: 5a3c93afc4a894134e45c2b333b23d6c3a30207b docs/models/updateinvocationbody.md: id: d8b3b9cca5ae last_write_checksum: sha1:0fed6d77626ec76d3584e8d38b97ee228218a390 @@ -2910,6 +3162,10 @@ trackedFiles: id: fef8641b24c8 last_write_checksum: sha1:4c9532d96f40fc0b406e3c8e34b40d2b457963bf pristine_git_object: c675adeffe4da132426b8002b45d4c290bdd97bc + docs/models/updateschedulev1workflowsschedulesscheduleidpatchrequest.md: + id: 0146d71cfe07 + last_write_checksum: sha1:944b765fd6ed75e9939cf93cc3947d130cd55f91 + pristine_git_object: 68ffe15a622ad79f1581a52624efffb33fc0d5ba docs/models/updatevoicev1audiovoicesvoiceidpatchrequest.md: id: 0b7dfc68573f last_write_checksum: sha1:53d5d07d53d184d68b57185d251c8d68ff3cf4d4 @@ -2950,26 +3206,34 @@ trackedFiles: id: 304bdf06ef8b last_write_checksum: sha1:1f297f34069668f6107f2c0389606efe413ff5a8 pristine_git_object: 5bcea5b5d12e72222720af2c014d64ec4bdfee4a - docs/models/visibility.md: - id: 69ecc096de1e - last_write_checksum: sha1:30226db515dbfeef9316552cf871cf6882f597d2 - pristine_git_object: 924f2bdd9bcaa0bc59ba7a28733ce53fa968f822 + docs/models/vespaschemaresponse.md: + id: 989810d8633d + last_write_checksum: sha1:96ff3c52987ca630d03822936dfa792f928473c4 + pristine_git_object: 1cb7277be00681b0f1fbe6bc2e83317242d56152 + docs/models/vespasearchindexinforesponse.md: + id: 4e902564cfe0 + last_write_checksum: sha1:8744908c4282bb2be98b8eb3ac92a86d10587f7c + pristine_git_object: 16272fce2395ef0834eabb12fdb661fb72ca7d2e + docs/models/voiceappearance.md: + id: e481147d8fb2 + last_write_checksum: sha1:f8c3f4bcd91547d767c4b22fb85099c2fe97ac6f + pristine_git_object: b77de4c82ba355cb414c7f7f2e0ed641ddd74035 docs/models/voicecreaterequest.md: id: 1014a6e8d549 - last_write_checksum: sha1:2eba4e618f2767df9ca52b8b352e3060e9d0f04e - pristine_git_object: e9a3b3a14963b63e3b5555912bfe2c2f5ad6c67b + last_write_checksum: sha1:7592cabbf9ad8e0a8bbe1d69b4537dc82a7f7e37 + pristine_git_object: 775da22b80af35b840c127f1843790b135887a8e docs/models/voicelistresponse.md: id: 8226f91596b3 last_write_checksum: sha1:5d4dc06036e1c8267fe736ae23c53104853850dd pristine_git_object: d2d40dffd0bcda10a2266c95ac951e8242209f6e docs/models/voiceresponse.md: id: f6523df1521d - last_write_checksum: sha1:92c959e003170588fa6fa7d9d0bd33207fbaf49e - pristine_git_object: 3ec6d5407d0e7bde20488c2831dc3fe962696eee + last_write_checksum: sha1:becedca881e793f4d0b0768ef6d4f22a99628f61 + pristine_git_object: a907372e03797206112f04c3faac9b586effd4a6 docs/models/voiceupdaterequest.md: id: 7fbbdd315066 - last_write_checksum: sha1:8a1883407eff51f9e81fa3024af0d9fab016b2ca - pristine_git_object: 924b5f477dd97f8fe417de63b5d7b744616b2fc4 + last_write_checksum: sha1:19026b7852f3382a6dc9ed22ad7411e6ed53624a + pristine_git_object: ec2913dd40628817196c911acaa5558b3efd0314 docs/models/wandbintegration.md: id: ba1f7fe1b1a3 last_write_checksum: sha1:ef35648cec304e58ccd804eafaebe9547d78ddcf @@ -2998,6 +3262,26 @@ trackedFiles: id: a88b03086ce2 last_write_checksum: sha1:7046dd6a11770b56c36e22af07552e28c6cf36f0 pristine_git_object: a534ad34da32c4d8eb93f055e1bbf128c5df7e8a + docs/models/workflowbulkarchiverequest.md: + id: 149f8cc52a93 + last_write_checksum: sha1:429200327e31c36c2524bb9952577548d8cbe4b3 + pristine_git_object: 2c9b934189dc8f4fd1748c6a8e4c0dc4bcc1e8fa + docs/models/workflowbulkarchiveresponse.md: + id: 5d83f540f3bf + last_write_checksum: sha1:d967e75915950b95cc0cc7938ebb79f9d9bfeb61 + pristine_git_object: ce1999f3d2fb7f0ef7cdf5b6d9e326ae7deb71fc + docs/models/workflowbulkerror.md: + id: 616c78c4a5ba + last_write_checksum: sha1:c55cf5e9350a7aee18c06707f2ce0b332b8c5397 + pristine_git_object: d8e34f4e593067e4b9cb7b8b22ba1be589d667dd + docs/models/workflowbulkunarchiverequest.md: + id: 976175ec8e9a + last_write_checksum: sha1:bc1aa33c225ff70f46b0ac86251ca5a983eebdd1 + pristine_git_object: 0e5342cf3d28ae5804931aa242e3b8c9335f29d4 + docs/models/workflowbulkunarchiveresponse.md: + id: bb49d41e85a0 + last_write_checksum: sha1:d773d6bdc784ac4a1b61775ae64cea77d3c86aa1 + pristine_git_object: 8b139b752d94dc52594e12465e15797244cbb4df docs/models/workflowcodedefinition.md: id: 16ce7d540f36 last_write_checksum: sha1:96703471ed4249c118cd0d2563182f9300e3bfc9 @@ -3136,8 +3420,8 @@ trackedFiles: pristine_git_object: f85563cedae6cb209614fc97ecf6dd94ef810172 docs/models/workflowschedulelistresponse.md: id: 4c425808aa60 - last_write_checksum: sha1:d8e8aad7a91d7f8e398f7716109d436df6c4fc86 - pristine_git_object: 7142185b8081d076cb3b8fcd592234d49e3e0e5a + last_write_checksum: sha1:76a8376715ccad83ebe039f64b757617229d65c0 + pristine_git_object: b642854646f5ac2e7a0f680de8387f504a9374ab docs/models/workflowschedulepauserequest.md: id: 3a6d7adc379a last_write_checksum: sha1:97b3dc2321f62497cea5f13b54c5b1d049d855d1 @@ -3150,6 +3434,10 @@ trackedFiles: id: ef0b813976ad last_write_checksum: sha1:2da7d2a8519fe915554fdcebc25915ad11fbb203 pristine_git_object: 96d7ced717099cc1bbff4ac38d60e7552e9c6204 + docs/models/workflowscheduleupdaterequest.md: + id: 0eed547c9a4b + last_write_checksum: sha1:d71e300642a6ef23687318f53c8fe32b38320a0f + pristine_git_object: 24357f65c73cc9ace2a51eb549434c40333dea9c docs/models/workflowtaskfailedattributes.md: id: 7f329c44d7fb last_write_checksum: sha1:432c70ec990e81e2de79c14efbbb6161b60e1b3e @@ -3188,11 +3476,11 @@ trackedFiles: pristine_git_object: daa637fafd39b03b9d6c0b627047be1142f060cc docs/sdks/accesses/README.md: id: 2ea167c2eff2 - last_write_checksum: sha1:663516c8c94ca324b938a5d5bd1196663cb1de88 - pristine_git_object: 51051e2f8def9bfd6032617530ba9bead989404f + last_write_checksum: sha1:c9daf160ffc706a9be9e2e86855d97227fc25373 + pristine_git_object: 3acf0566daa202fbc8c3c182ff9405d9812a38bd docs/sdks/agents/README.md: id: 5965d8232fd8 - last_write_checksum: sha1:962df50ddc8aa1f501ad596313ee590ba704ff8a + last_write_checksum: sha1:2081b3728e940846431a2cc28b6090d87a786e87 pristine_git_object: f02ea6cd7f7405763edb09dcece22e65028e8fbb docs/sdks/batchjobs/README.md: id: a3b8043c6336 @@ -3200,7 +3488,7 @@ trackedFiles: pristine_git_object: b9655075680d5046d4b10d10de77d6b7b2ccea23 docs/sdks/betaagents/README.md: id: 5df79b1612d8 - last_write_checksum: sha1:6d14ffeace9a068f45ed9c62ee6663dc3768239f + last_write_checksum: sha1:40233bb8dbec401f8ce02c054b60640cabd400f7 pristine_git_object: b936538c54d38e52a67ffdb8c65ec35999197a3a docs/sdks/campaigns/README.md: id: 18dcc3c717ca @@ -3208,7 +3496,7 @@ trackedFiles: pristine_git_object: d5d7e4d4681811419874f58c294cb59688e595aa docs/sdks/chat/README.md: id: 393193527c2c - last_write_checksum: sha1:839bc022bed585cd691c403333f68ed8b68d1a8c + last_write_checksum: sha1:428f1bd7d271cd6b7edd6251295a5f240e648c5b pristine_git_object: 54b9f02913409dd73b0a0f36f7eab4f7fbcf5791 docs/sdks/chatcompletionevents/README.md: id: 6965539e0525 @@ -3220,11 +3508,11 @@ trackedFiles: pristine_git_object: dc0f4984380b5b137266421e87a1505af5260e89 docs/sdks/connectors/README.md: id: 7633a87d946d - last_write_checksum: sha1:f4c8a2ee577cae1b8b1e9551bb873bf34fe0f403 - pristine_git_object: 753c1cf3974ff3be77dc3b401d27ec5c0ef8bced + last_write_checksum: sha1:6eeacf2ed1c525cf329bb03ad4d3de1404de7398 + pristine_git_object: 4a0d8a935163a762071352b0d731ed0272018ddc docs/sdks/conversations/README.md: id: e22a9d2c5424 - last_write_checksum: sha1:d0a4e55b1f1c9acc6e9b7cf5925faf930a911d26 + last_write_checksum: sha1:68ede193fd35a89ab226aa92a92edaecf1eebb1a pristine_git_object: 63cd80a4a655a5c139be79239b0787c3f90cdea9 docs/sdks/datasets/README.md: id: deb5d90f4faf @@ -3236,8 +3524,8 @@ trackedFiles: pristine_git_object: 941b5538a57b3b693914d6b0d2acad2e8bb47611 docs/sdks/documents/README.md: id: 9758e88a0a9d - last_write_checksum: sha1:c3ee7c987ddaa856fa0a2f1040a2592edb0b82f1 - pristine_git_object: 2efbc3488ec4b4b6bc5d30d9ae1b5a344a0fe79b + last_write_checksum: sha1:7f1540110547b0ddb1350dc24422bb94bdf3bdd8 + pristine_git_object: 2a4787d0bb340be626208900ab7d72c2232792eb docs/sdks/embeddings/README.md: id: 15b5b04486c1 last_write_checksum: sha1:4a279bf9bcd84a9878ef979c78b8b75af3d52f02 @@ -3256,11 +3544,11 @@ trackedFiles: pristine_git_object: 3c8424419bae5c7e6e47b4cb23e35064531a8345 docs/sdks/files/README.md: id: e576d7a117f0 - last_write_checksum: sha1:45265e774720742cde1c76c8be294983bf4fc77a + last_write_checksum: sha1:ca90e32b21837a12b2e0f248b2e6160864e01d21 pristine_git_object: 246707073e9dee115d30b20a01bf728dcb43efd7 docs/sdks/fim/README.md: id: 499b227bf6ca - last_write_checksum: sha1:be2db0822c83cec2cfe2b5424d4b08db06d1c63c + last_write_checksum: sha1:b4aa3bc3243a20f339c9f9aab0365ed0456d7808 pristine_git_object: 7bf8908378c764c58cca2eddc6a4a97574c3709f docs/sdks/finetuningjobs/README.md: id: 03d609f6ebdd @@ -3276,8 +3564,8 @@ trackedFiles: pristine_git_object: 34d167398ac81ce78d50c1498c01f4c74917ce7f docs/sdks/libraries/README.md: id: df9a982905a3 - last_write_checksum: sha1:3cd3aef0294fb5b421a2b64baa7a53cfc1ad4f31 - pristine_git_object: 08606189680228ca4f4d30b6fc626c2d0c4b9287 + last_write_checksum: sha1:99d5c4e9c4c2689385bedf9da1930df89649c995 + pristine_git_object: 863cb9f410ff082cd09bb04bc52b0e2628804289 docs/sdks/metrics/README.md: id: a8545d964e21 last_write_checksum: sha1:0c559bd570e162c994c6125058f3712e24bc576b @@ -3300,24 +3588,28 @@ trackedFiles: pristine_git_object: 7ed914205115222f7ade5a656541af0dba64ff28 docs/sdks/schedules/README.md: id: 2f28c809a225 - last_write_checksum: sha1:cb4f7d988d25d87b8c18443c6cf64b5cb31146df - pristine_git_object: 7bf59931141869fc2797586fb6cdcb8adb9f0b7b + last_write_checksum: sha1:310601597370d883f38db8901ffbf99fd0875caa + pristine_git_object: 6b0e5f0e31f7de2eb5ac105c6406abb5d59e1cb6 + docs/sdks/searchindexes/README.md: + id: b58e7a6ab4f1 + last_write_checksum: sha1:129ef4c1ef14a615ee58a2d8c313b02cc0f0993e + pristine_git_object: 471bba59a2e12f24b8bad96850b25b566cba29da docs/sdks/speech/README.md: id: d5924688d48c last_write_checksum: sha1:7128863f5b445f343d4fde121c78de3a8ee4cc11 pristine_git_object: 7cd76ff4dc2354a55ae8b7bf08fbe46cf20ab081 docs/sdks/transcriptions/README.md: id: 089cf94ecf47 - last_write_checksum: sha1:15d118796f147bc5b0bf4146ba39bfa9edfbc996 + last_write_checksum: sha1:548786cb29e8500574afaaa771a5184c81fe2ebc pristine_git_object: 97703c9b4dc942385ee04ae96cbd100c3f632a17 docs/sdks/voices/README.md: id: 4f1a657c8f68 - last_write_checksum: sha1:88be1b4df915b0c4f50f2a54f2c7e93ffd5a5263 - pristine_git_object: 49b8533f85e2c6bf70ff1ea296136f4d18cb8348 + last_write_checksum: sha1:4f1b6512c334d5d43b30cba4438550508290c780 + pristine_git_object: da59de379ecf8390439ebd64ab7b2d6dfa1f25df docs/sdks/workflows/README.md: id: 80c76ce944c0 - last_write_checksum: sha1:807551c827dd5936819393e88ff2160839bd01fc - pristine_git_object: 4575977672501a047dcd701dc471e2694d13d294 + last_write_checksum: sha1:f6f15706b9b4ac1b4f88fba3cac7396d69151691 + pristine_git_object: 0fcb9b8b8a15f262abc31e031a16f8da09ad95f2 docs/sdks/workflowsevents/README.md: id: 514b42269280 last_write_checksum: sha1:34971ab6eef89b115d78375a85142f3d2612f431 @@ -3348,80 +3640,80 @@ trackedFiles: pristine_git_object: 036d44b8cfc51599873bd5c401a6aed30450536c src/mistralai/client/_version.py: id: cc807b30de19 - last_write_checksum: sha1:6b2772cd63b60cddf4ea95d94cfc44f81a878a73 - pristine_git_object: 9f9ae8c6224af17b3e22410b33f5a5ad37389e33 + last_write_checksum: sha1:f490e14fedec9dd2bab194b7f29af94a779d9b08 + pristine_git_object: 1a977e80189b69ec4cd5fc17f2bf384da665fba2 src/mistralai/client/accesses.py: id: 76fc53bfcf59 - last_write_checksum: sha1:de197fbbfea8bc95f44b4e7ee1b39e68fdde8bc7 - pristine_git_object: 5d859a399cb62144f5e47ae879407907427d56fc + last_write_checksum: sha1:5f1fbb7eb973dd8bcbe33bf0b303d4df3bf2ad36 + pristine_git_object: 90aef2e7e73f5880ec4f55fa054cf6b5d3cc082b src/mistralai/client/agents.py: id: e946546e3eaa - last_write_checksum: sha1:02f7e2c669dba9f1d29f41bc6427357e9d04be5c - pristine_git_object: 1bcd8c54f685630c8248243b7dbf0ad5a8aa6082 + last_write_checksum: sha1:9f2793ced88646b66736d46e98f004cbd4c57224 + pristine_git_object: 86c31b3ec549caadbf9c1576e09a0205f6374934 src/mistralai/client/audio.py: id: 7a8ed2e90d61 last_write_checksum: sha1:b9dc19b4b6070baf7d8937907b8665e9f0e36afd pristine_git_object: 597954e4facba105cee62d92ea6b8c68555f63dd src/mistralai/client/basesdk.py: id: 7518c67b81ea - last_write_checksum: sha1:321a95c38231ed5126753702e6368a85a1af1667 - pristine_git_object: 4a27eb2ff362dd6189abfde2c8f739b70deab192 + last_write_checksum: sha1:0544004f28ec429df8ab994c361f384b6159740d + pristine_git_object: b305e63e3a40f1b9ba5833f0d7d692c090f9eea2 src/mistralai/client/batch.py: id: cffe114c7ac7 last_write_checksum: sha1:b452983f67b33f26e1faa60fdbbb171cb1877224 pristine_git_object: 7e36fd0d73ebeb873f74f4109896a6cf3bb7d2ba src/mistralai/client/batch_jobs.py: id: 3423fec25840 - last_write_checksum: sha1:89deea7e036f775d7d0551ef7edd550a7903ccfb - pristine_git_object: 2bf50fd3dc54ca084c026c97cac055f75d4a885a + last_write_checksum: sha1:ea2bb05997e8dd9e7bf487afa563da93ac813c29 + pristine_git_object: 456e285bb0c318c8d1023cc7c5d2f4d3d296c25a src/mistralai/client/beta.py: id: 981417f45147 last_write_checksum: sha1:1f6972862310651111b52027dd8b4c5519adadfd pristine_git_object: f9bbb5aed59e7f9505e4bba2ee9c0190d51cf626 src/mistralai/client/beta_agents.py: id: b64ad29b7174 - last_write_checksum: sha1:307dd8e2fd0e8bda707894118ce9b89d329e7964 - pristine_git_object: 64baf53b7d7757a35324c0b3b86544167f331b16 + last_write_checksum: sha1:152f183dc93b2069b570ce75bba970a9771a7c0b + pristine_git_object: 3c0661b6e85979ebf8f2ae7c399f13877eb4732d src/mistralai/client/campaigns.py: id: 9e64fcf4e60e - last_write_checksum: sha1:8d4471059539934a69b9fa1f98b4cf35f1db61ab - pristine_git_object: c9f28794e32130e6ef92127316815772c6a04c71 + last_write_checksum: sha1:f75467fa874163b43ee118b29202c6e00c683d9a + pristine_git_object: 460b0b5a958748cc3e3662783e9cb8d64542aee0 src/mistralai/client/chat.py: id: 7eba0f088d47 - last_write_checksum: sha1:e8b8b2e745117b6d78402148121c9f5229694066 - pristine_git_object: 9deff9a0d2091c706146eb903834a354c5432ec8 + last_write_checksum: sha1:1a257686a6a246b8d39fba8cf44650a9ebb36567 + pristine_git_object: 74a9221a6f16ff66282bc59ff3b2349b384bc1de src/mistralai/client/chat_completion_events.py: id: 1813f339625b - last_write_checksum: sha1:785474540b9ddc3d3e9c7ec5011e2f25519bc8c2 - pristine_git_object: af4124f0c3e71e3f335f4c0b54d36a0b2dddcbb6 + last_write_checksum: sha1:4ecfd5b487a648345908ffffe746cc21447bc0ab + pristine_git_object: ef737912cebee0cc9d39ea3f18f4a28dadfb3bfb src/mistralai/client/classifiers.py: id: 26e773725732 - last_write_checksum: sha1:d057b735d057147e1341953dd696fbc7110611ec - pristine_git_object: ddb2d0b1abaff5f267320779bf9ae64d5ae0adf3 + last_write_checksum: sha1:d635ba5307bb64ade27134a1ae979e610a6d2f80 + pristine_git_object: 36329ea6180905b8ea4607d5a5aa83e297a7bdee src/mistralai/client/connectors.py: id: 39da03126050 - last_write_checksum: sha1:16a6fe8ffbf14828b1b930d7dda7a001d4780ea4 - pristine_git_object: 793c9f8ae726f86fc82de044e8a09b6931bb2592 + last_write_checksum: sha1:44bf2225202d7e5b7d95b62fa1d4f072ed9e2efb + pristine_git_object: dc8df3e853ded5dc3f4c51daefb00a8a6723344f src/mistralai/client/conversations.py: id: 40692a878064 - last_write_checksum: sha1:501da7474cc0bc6fd627150f15870dd3acf70235 - pristine_git_object: a30f8b05f9735464ac53b612cdfe139e5469b8b4 + last_write_checksum: sha1:c6f4ab6903aa74f88d267552c01d79b4ca08534d + pristine_git_object: 8f61fbfad9d79ea0ea4dafc4187c2212adacf154 src/mistralai/client/datasets.py: id: e5a6ae2a2d85 - last_write_checksum: sha1:fdd59e77aa9d19e64ab31cb949ea3565392c3113 - pristine_git_object: 437b42fdc5354378e822b38172bb5ee769355425 + last_write_checksum: sha1:7c4c9dfda1e50a003f9fb857fd96904d0e49a778 + pristine_git_object: 078bb18baa9ace9066204d5c554d647ecd4ce420 src/mistralai/client/deployments.py: id: a874b267fcb9 - last_write_checksum: sha1:5b62dd6436ce4914de7fbf0abc0819734eb08136 - pristine_git_object: 26e9c5658068de85878942b444538e0e58f706f5 + last_write_checksum: sha1:0291107482b2d9c2a3bf0a7e0933d1fc43b1f3fe + pristine_git_object: 086e95a2162256db07d919c98a8dc5029627a17c src/mistralai/client/documents.py: id: bcc17286c31c - last_write_checksum: sha1:27beb1104b009c5237d37f11e11b589fadf3838b - pristine_git_object: 2a555d3e3d34afe673de231bd1fcadb8fc36b59b + last_write_checksum: sha1:a436f5d0055f4ab5b29f4b8c2e8222f9e697c63e + pristine_git_object: a3c8b07bd32689a8cf5d092d0964f3839937f8ac src/mistralai/client/embeddings.py: id: f9c17258207e - last_write_checksum: sha1:737e09a794867ea7242fb7c9e09cdff5f837fbf4 - pristine_git_object: 64337b4f3f56f084ed47a3f1f17a999a868db2c3 + last_write_checksum: sha1:8dcf1cbbc7233bd6e0c3fd10decb2d88ccaa046b + pristine_git_object: 17eb9a57bb170bee55f26f11c54b8c9a4255ede2 src/mistralai/client/errors/__init__.py: id: 0b2db51246df last_write_checksum: sha1:0032f4eb3501c71fafb8f68113a8c80e677311a4 @@ -3452,56 +3744,56 @@ trackedFiles: pristine_git_object: 25b87255a51021079f8ba5cc60b43509e12f9a4d src/mistralai/client/events.py: id: ac9b961cc70d - last_write_checksum: sha1:b250b6454555bb436cbc194e732c72982af23d94 - pristine_git_object: 3a4c47224be925a5701c88f9cf363e61bc1afd7f + last_write_checksum: sha1:ec68974ad398b02201aa10ca5e10443196aa33ca + pristine_git_object: 4ebb6505f0c8aa342f6daad6eaf73c92cff300fe src/mistralai/client/executions.py: id: 974004d347a2 - last_write_checksum: sha1:bc0b48a037c85cc0411dc16f59da9481510c0469 - pristine_git_object: e4b9f90b0d985710715421cf68320a8dd0585a19 + last_write_checksum: sha1:b9558bb68c97db073706f9a2c53afbbc8049990c + pristine_git_object: aa22f09ebdc95526314bf5ba0c86cb9e48ed9f42 src/mistralai/client/fields.py: id: 862335210b20 - last_write_checksum: sha1:c200568ed4ad334849643bd85f19edc258877ff2 - pristine_git_object: 17441ca699fd8fb22701a0e59411d3ebd292f049 + last_write_checksum: sha1:1af13d8200df61b54b0e1f0a679feb76484c6bd0 + pristine_git_object: 5e701da99d523c222454a291e64f47ada989f0e0 src/mistralai/client/files.py: id: f12df4b2ce43 - last_write_checksum: sha1:076c1f6435398d29491e1dcdaecab760e9f4a0a1 - pristine_git_object: e4549c75f5b5c21e8025383cce66737e0b1a96f6 + last_write_checksum: sha1:bcb7a967ddb7bb16896e8b0ef0af56c39f1d3ff9 + pristine_git_object: 5f8396f5d8c37b638bcd8a7be1c97b85bc1b2f95 src/mistralai/client/fim.py: id: 217bea5d701d - last_write_checksum: sha1:4fdaa4ccd058e700e510c63a5397e5c28fa4e923 - pristine_git_object: d25f79b193237ef5d3b55921837882c8dd9dd30f + last_write_checksum: sha1:b4c816932351b1b0bafbc453dd838192b2d7a515 + pristine_git_object: d868bcff5dc5b90f0468dd097f60b1bb90e9a95c src/mistralai/client/fine_tuning.py: id: 5d5079bbd54e last_write_checksum: sha1:fe1f774df4436cc9c2e54ed01a48db573eb813cd pristine_git_object: df6bc5643a13294ddfbeecc6ae84d00cd7199bed src/mistralai/client/fine_tuning_jobs.py: id: fa1ea246e0b2 - last_write_checksum: sha1:18c53b380f2524d2dcca63ad014b1adb2dd682a0 - pristine_git_object: a6bf93a320939857513d85a8f5ecb1b5a47d8533 + last_write_checksum: sha1:b42ebedc6f7461b0a74393aa907f6d9a94ca91e1 + pristine_git_object: 708cc5371593055fc8410fabd933249f309acdfe src/mistralai/client/httpclient.py: id: 3e46bde74327 last_write_checksum: sha1:0f4ecc805be1dc3d6e0ca090f0feb7d988f6eb9d pristine_git_object: 544af7f87d6b7097935290bebd08e30e5f485672 src/mistralai/client/ingestion_pipeline_configurations.py: id: f5a994272058 - last_write_checksum: sha1:b34f23cf74285c410c1258be40b37c2c3b652a73 - pristine_git_object: adef39f9953d4c6e59c1288c7e6deb2cdd75ad60 + last_write_checksum: sha1:5eff8e1b8dbfd396ff87e48c2af4b2c7a79d9814 + pristine_git_object: dfd139bab111a55b24b508feaf64ee67a564204b src/mistralai/client/judges.py: id: b6024a41ecb4 - last_write_checksum: sha1:a5c33a8bc46f6f3d435827a2a701016a428cc83c - pristine_git_object: 52c8899eb8c8ec092be454aca929012a62fec337 + last_write_checksum: sha1:a4f3d12d778a58e8d10a41753c4a992c20bdd86b + pristine_git_object: 187eed0d36bc641177fa077aa529c4ec51422e78 src/mistralai/client/libraries.py: id: d43a5f78045f - last_write_checksum: sha1:db5cab2f824979cfe953e31f465c30fa322a4cff - pristine_git_object: 928c1ea8a79f1f838a6ea4c7a23826f5bdb82445 + last_write_checksum: sha1:555755528cb5283aa561c7eee818102b4ef75dbe + pristine_git_object: 3076d09c7582f18d197208178a88520e4bc9220e src/mistralai/client/metrics.py: id: 937cb03f8130 - last_write_checksum: sha1:491be33059fb0bbccff73b2a3bb0a66fb7a5ba9b - pristine_git_object: 60597c40f00705b4758827fb7d119f33ae2ad1b9 + last_write_checksum: sha1:0a529a333e416df4907837b24006bca6f462de9c + pristine_git_object: d3814d6b3d2fd548b9ae7f97a1f4d27592ca97bf src/mistralai/client/models/__init__.py: id: e0e8dad92725 - last_write_checksum: sha1:c072eedd54264d94cc39317fd40433adf40f6fa9 - pristine_git_object: ab36240c66a1da2d58318b7155af6a803e2e1e13 + last_write_checksum: sha1:faadf02f5775b34350ab65f02e0b5ae349caecc8 + pristine_git_object: 6121091ffd2225c3180502e373308c810e465ba5 src/mistralai/client/models/activitytaskcompletedattributesresponse.py: id: 8174941767cc last_write_checksum: sha1:b5246e203765ba0532a6a65d391bdd237ab2c891 @@ -3696,8 +3988,8 @@ trackedFiles: pristine_git_object: fb8b79723f3f0f4485c0c6bb1c52b0a5db2fa1fe src/mistralai/client/models/authenticationconfiguration.py: id: 97b5056c29fb - last_write_checksum: sha1:95b12ce07e5656f40d1fcf4566af5336f5279cf3 - pristine_git_object: 84f665915ad716ce97cd9219f59ffa9cefc68bbd + last_write_checksum: sha1:e8465381456454f427238fc42a60305b3e5f55d9 + pristine_git_object: 79c6964176ebff18657b02abd16985737e6eef35 src/mistralai/client/models/authurlresponse.py: id: a2b468c87a8a last_write_checksum: sha1:8ffc0c770c51d7b0cb49770e6829486d0cb82741 @@ -3834,6 +4126,18 @@ trackedFiles: id: 4000b05e3b8d last_write_checksum: sha1:1d639da446bf3e2df7576f4320b0d0e2dbdfff8d pristine_git_object: 5d1d1f8f3adad438f83619f61e3e396aa3b65d15 + src/mistralai/client/models/clientcapabilities.py: + id: b2ad660c5c9b + last_write_checksum: sha1:9e9ab4cfed5487f3ba336de7465efcbe7891fdcb + pristine_git_object: 772711601752ec07d571befea5b51a30abed1650 + src/mistralai/client/models/clienttaskscapability.py: + id: 83aeca444b21 + last_write_checksum: sha1:1aac7c99f18f0449acbe46ab38e0012f7a4b1862 + pristine_git_object: 5256c3d502a7de1b6509031ee8c0ceea2df53479 + src/mistralai/client/models/clienttasksrequestscapability.py: + id: 26148da505a0 + last_write_checksum: sha1:ecdb0a3954e6cd3ddd4dd49ba1d3844cf2ff54e2 + pristine_git_object: 38b9d6b12e9cc278fa882c95b25bd1de848c7fae src/mistralai/client/models/codeinterpretertool.py: id: 950cd8f4ad49 last_write_checksum: sha1:248d6e6c1906303f03eb4f29429227a7d39679a2 @@ -3874,14 +4178,34 @@ trackedFiles: id: be202ea0d5a6 last_write_checksum: sha1:fe9420a42d598d1a6ae15ff0d35bbfad4f56e7b8 pristine_git_object: 3b99a69322ac18cfda3df0d4726d218063092ae0 + src/mistralai/client/models/connectionconfigtype.py: + id: 52923bfd57d3 + last_write_checksum: sha1:c515a281111d65a4acf890c2683a891d352a652c + pristine_git_object: 9ad1bee185be3830d587d428b83f2bdd626ac341 src/mistralai/client/models/connectioncredentials.py: id: 2f4a79b452fb last_write_checksum: sha1:2183abeb08ce54a985d531baac5f67b84f42417d pristine_git_object: de461057f967b4dbd746cc82321fbed4afbdf145 + src/mistralai/client/models/connectionpreference.py: + id: 6b9389ac91e6 + last_write_checksum: sha1:94c03c3e8ac45245baec8db480cfa162794b0dd8 + pristine_git_object: 953ef17cbecfa6983a722b151b966c72f74cf476 src/mistralai/client/models/connector.py: id: 1a4facac922d - last_write_checksum: sha1:dc5989fda6b4a5f49e2e5febae8ebf8ddfc5b33a - pristine_git_object: 9d8b600032db4f260a96140433bce3f7e4c21f3a + last_write_checksum: sha1:5b8d7f5c6f97a2f8478ddfdd093a74b60d53da34 + pristine_git_object: ce9e083744d2682451378528aafd90c439748bfd + src/mistralai/client/models/connector_activate_for_organization_v1op.py: + id: 9b35397dd5cc + last_write_checksum: sha1:310d5c74ef6b89e604e94bec61efa51f853e7c88 + pristine_git_object: 1b0ec3b0bda16c406d70a8a8e97cbb92ee427f51 + src/mistralai/client/models/connector_activate_for_user_v1op.py: + id: 6bf45c78cfea + last_write_checksum: sha1:a821db048f3e675f4593d0355c1e361c49311e42 + pristine_git_object: e30126d48d593fc5c240fd58b98fbf6aba314caf + src/mistralai/client/models/connector_activate_for_workspace_v1op.py: + id: b6392712ddaf + last_write_checksum: sha1:b361b01a898a446d2ed9a953c8cfc95812341a9e + pristine_git_object: 00fe6699d18db79d9943dc55775eb337b3ad2846 src/mistralai/client/models/connector_call_tool_v1op.py: id: 7948899b3068 last_write_checksum: sha1:c4388ac1594641c36f97daaedcf42b0e94753be7 @@ -3898,6 +4222,18 @@ trackedFiles: id: 7795b085704b last_write_checksum: sha1:70bffd65c359d4c295b0f4a419d5a783d50e03ea pristine_git_object: 43b3c1dc6576d9d9260a220097f52b51029e205a + src/mistralai/client/models/connector_deactivate_for_organization_v1op.py: + id: 850bece829b0 + last_write_checksum: sha1:b9dc305c9bc09d5979d650b5734d86eb416e23fd + pristine_git_object: 4c5c5458e79a3fcabf1b608895364e5aee21a536 + src/mistralai/client/models/connector_deactivate_for_user_v1op.py: + id: 1df4227a54f7 + last_write_checksum: sha1:8d2b440ae4983f8b43b9dd7fed5c97a5cd9c17a5 + pristine_git_object: 5d998877241cc05f2e67e6b28b8a349f18d866ef + src/mistralai/client/models/connector_deactivate_for_workspace_v1op.py: + id: d82c1a5321cc + last_write_checksum: sha1:5edfc695ffd5acfc57f2a08af655b609ffbdb05d + pristine_git_object: 9f02d887f7be47f64fdbb0d00f7e2d3be2f23517 src/mistralai/client/models/connector_delete_organization_credentials_v1op.py: id: aab3a70dbbc5 last_write_checksum: sha1:a53123b18f8dd5a33e777741ab44aac0d5ed64ee @@ -3924,8 +4260,8 @@ trackedFiles: pristine_git_object: e0c4146d4621eec51f6961f85de95088e7480c08 src/mistralai/client/models/connector_get_v1op.py: id: 73ca3a446dcc - last_write_checksum: sha1:74ce85c377be5d7f86506d8a8d97249708c246b8 - pristine_git_object: 780afac9281bf78c4263c7bd32faa04a718695d2 + last_write_checksum: sha1:7afd047c7e74eb418365d79a25c79ec566e72992 + pristine_git_object: beb27872de7204b10e5a28789f817b2cdb629a77 src/mistralai/client/models/connector_list_organization_credentials_v1op.py: id: a52ee058feab last_write_checksum: sha1:2abf099d7a6ea68134d38c3a95dfec08d37e9ed9 @@ -3958,10 +4294,18 @@ trackedFiles: id: 7dc7ec295301 last_write_checksum: sha1:8af4bd44caa8ad09180139e7e8a68052c16dce11 pristine_git_object: 85366bb6acaa0724a907803c689a2caeb431bf7b + src/mistralai/client/models/connectorlocale.py: + id: f987f5207d2e + last_write_checksum: sha1:650dd62ffecf5940c5b9c43e561059244ae1e09d + pristine_git_object: 373e9e848b4df211f646c289b864b3a3d66b4954 + src/mistralai/client/models/connectorprotocol.py: + id: c35853b1b79f + last_write_checksum: sha1:96327799b7a691122ca8f742afb5bb85574ff580 + pristine_git_object: 042f23524ba8f38cf01956945611158deeb8937a src/mistralai/client/models/connectorsqueryfilters.py: id: 3b9fc81aa726 - last_write_checksum: sha1:399567eb362a40f1225f7d8adb820aabc6b9df99 - pristine_git_object: f10d689771d50077bc35193a39a94672a9f09ac2 + last_write_checksum: sha1:ab7df6cf281f7bea870663783924d113309348fa + pristine_git_object: 860caf43e0a61363933058d72819e03f4be86477 src/mistralai/client/models/connectortool.py: id: 41ca596b44f8 last_write_checksum: sha1:0306b9a607d59afe042aac018df6e2bc0cff0d8a @@ -3982,6 +4326,10 @@ trackedFiles: id: 86730e16aa67 last_write_checksum: sha1:fae6e84b040a1c8bcb25b94041f990525529472a pristine_git_object: 8c92f2f8d4c25eac7f3c95e0ae425942829390d0 + src/mistralai/client/models/consumertype.py: + id: d18230da2fdd + last_write_checksum: sha1:4fc648452051b1dc9ef496b54e75d18396807158 + pristine_git_object: ac091e5e905d0985ce7286389f46c308c53ebb82 src/mistralai/client/models/contentchunk.py: id: c007f5ee0325 last_write_checksum: sha1:b921b03b4c1e300b0e3f51ea9eadd4d7c4b7a0ea @@ -4060,8 +4408,8 @@ trackedFiles: pristine_git_object: b3957df9ef369ecc1746ee3efd1b463bc10b4be7 src/mistralai/client/models/createconnectorrequest.py: id: 3da192d6491a - last_write_checksum: sha1:21ab6824e52ffb3bd2f97a97b4521188d6725f02 - pristine_git_object: 18060ca33206509d6443e306b8e505c9698ea9c6 + last_write_checksum: sha1:dcee72a62388e53c2f924f50f90bad947a757591 + pristine_git_object: ac732104d885e1658bd729d1732a2ca12b027cd7 src/mistralai/client/models/createdatasetrecordrequest.py: id: 9455e38a8c31 last_write_checksum: sha1:df3e8d7425500f23101c25267738e617eeb2d467 @@ -4092,8 +4440,20 @@ trackedFiles: pristine_git_object: 7c30aa5ffde4e23ce9ebcb0d67a0e1a3c875c698 src/mistralai/client/models/createlibraryrequest.py: id: 1c489bec2f53 - last_write_checksum: sha1:0d98f058dc61560790d2bde49026dd631845218b - pristine_git_object: e0357e9252a4911292e5dce370c808350b6da0ec + last_write_checksum: sha1:ebee21e3ac561b490513d6ebcb79efea070e1597 + pristine_git_object: 2bbb1e18c3ee495db44df95e47046b6f1285e54e + src/mistralai/client/models/createsearchindexinforequest.py: + id: 3f424a7063b0 + last_write_checksum: sha1:84c436749a4f6268ac8cbb4d52879e33f4052859 + pristine_git_object: f527f72dfeaa0e4374f64e9aad1ed4a786c68f63 + src/mistralai/client/models/createvespaschemarequest.py: + id: d44c0c466535 + last_write_checksum: sha1:048cbca6e8aad11561e9a42a5a8b0a31f50a0ca6 + pristine_git_object: cac99bc3735d8be742a5aa12a65cf40a7ba974d3 + src/mistralai/client/models/createvespasearchindexinforequest.py: + id: "866143560866" + last_write_checksum: sha1:553b15776ecaf0d3a58f0c99459429f60a51215e + pristine_git_object: 50006d38bb822c1cb5eb90ed8e8f577184dc2cc2 src/mistralai/client/models/credentialscreateorupdate.py: id: 9927546f2487 last_write_checksum: sha1:e31d3c7fc19e2a7fb49d07cb6f85c5ea73aabb98 @@ -4236,8 +4596,8 @@ trackedFiles: pristine_git_object: 2955dc485bbf1017a728cb0562baf948083e1b13 src/mistralai/client/models/document.py: id: fbbf7428328c - last_write_checksum: sha1:bc290f10562aaf9c24bd14ab3d2a31e62f535042 - pristine_git_object: 8d1aea883e579ff1677949573f43dddc362bd35d + last_write_checksum: sha1:3cdd40229b126132d3eb60505cd1d635325a8372 + pristine_git_object: c04512c130ee295c80548a2215b0f6bb428667bc src/mistralai/client/models/documentlibrarytool.py: id: 3eb3c218f457 last_write_checksum: sha1:a84295aba7b9e7f70b68f279934d1a5ca0817f77 @@ -4250,6 +4610,10 @@ trackedFiles: id: 4309807f6048 last_write_checksum: sha1:f45ecef78fb4412dc76ce54478fe536df0259048 pristine_git_object: f7a99ff81ee01d256052920405ca4788d3a47f75 + src/mistralai/client/models/elicitationcapability.py: + id: 63a9b5cfa2f2 + last_write_checksum: sha1:dc5d41705df6540b421fe0bacb10a11696d6a526 + pristine_git_object: 128084365172f50fc5b4f3f2f6453a1b216d9731 src/mistralai/client/models/embeddedresource.py: id: 94a23f656f72 last_write_checksum: sha1:50375363269d68edd3ea1c0a31ba08c8bf9bd160 @@ -4278,6 +4642,10 @@ trackedFiles: id: b51ec296cc92 last_write_checksum: sha1:ea907f86b00323d99df37f7ff45d582aace798e7 pristine_git_object: 4a39d0295f9069ae9f749cf21dab450eaf145d19 + src/mistralai/client/models/encryptedpatchvalue.py: + id: 311803d1f28e + last_write_checksum: sha1:bd3ab363a2924b69a7f1efd03a10d0d0f6b4f31b + pristine_git_object: 970bd59b8458d0f30fb2826cf3ee027a1e4237dd src/mistralai/client/models/entitytype.py: id: 62d6a6a13288 last_write_checksum: sha1:015e2db9e8e5a3e4ce58442ccedaf86c66239dde @@ -4400,8 +4768,8 @@ trackedFiles: pristine_git_object: fe62d6ddc1187e1177ac834a85bd4e1b6a86ee52 src/mistralai/client/models/filtergroup.py: id: dbc0c34fbc2f - last_write_checksum: sha1:f900312cfcea2b2a341d83e95ca2fce3e467fa03 - pristine_git_object: 4e9815b7387904b071645a9a4682a4ffbf23d488 + last_write_checksum: sha1:73aaf6de90f9be6913af8379535bc5ad999ab878 + pristine_git_object: 3439df66779c46b66a48f4c3792c51af16f958c7 src/mistralai/client/models/filterpayload.py: id: 56757b849f7a last_write_checksum: sha1:1d9a513f9c5a33c5ae249fb4926dd70eeb5e02e5 @@ -4542,6 +4910,14 @@ trackedFiles: id: 60463c59ff01 last_write_checksum: sha1:a851312a3e0c91273ad444c6e2cc81c8c541c9cd pristine_git_object: d9b6758f1622c76ad41092f4dbb9c6cf392b299c + src/mistralai/client/models/get_schedule_v1_workflows_schedules_schedule_id_getop.py: + id: cb775bc63ffd + last_write_checksum: sha1:29edc18fcca86b478702fa9ab632c93e63868a11 + pristine_git_object: d22d0515070d71858367cacdca0e2b83ee2a4cc0 + src/mistralai/client/models/get_schedules_v1_workflows_schedules_getop.py: + id: b5f0210eca23 + last_write_checksum: sha1:cf881ab5d08e4f97c4482522949059251406d4a8 + pristine_git_object: 62f8ece293aa947f86bc09938bbcd1ff6429edb9 ? src/mistralai/client/models/get_similar_chat_completion_events_v1_observability_chat_completion_events_event_id_similar_events_getop.py : id: d651bdc06c1b last_write_checksum: sha1:25331ac322d230cb7d9fc2a6aff2d7db561fdf2f @@ -4736,8 +5112,8 @@ trackedFiles: pristine_git_object: d4242f11b063f795b8d677abdd8c19ab0419a0b7 src/mistralai/client/models/jsonpatchappend.py: id: 61801f21f4b0 - last_write_checksum: sha1:f0400cf42fa6c776042487285cf18c1970e17ad6 - pristine_git_object: 7181ddac1956f1c29b815231f30c3405d4f50754 + last_write_checksum: sha1:6418ac32a97e99eea86df63204f560a0926f17e7 + pristine_git_object: 185f7bb72350361dbf9817a9480824720f5ee339 src/mistralai/client/models/jsonpatchpayloadresponse.py: id: 1b39f46f529f last_write_checksum: sha1:1d2a8b1039cef824f0e030804a72a0325c413a10 @@ -4844,8 +5220,12 @@ trackedFiles: pristine_git_object: 857dfbe60c57af8b0fa6655a049ed336d70fb941 src/mistralai/client/models/libraries_documents_list_v1op.py: id: 756f26de3cbe - last_write_checksum: sha1:565872ef17a53cc9751fa2c8fc1267dac2d01e76 - pristine_git_object: afc474cbe6c571ac36fe0800d4c1e5ffd07eb207 + last_write_checksum: sha1:3c0fc8976932ac7c537a7a0183e87a6505a84336 + pristine_git_object: 57e2736b9994d071455b95bfe349c3bef60eac87 + src/mistralai/client/models/libraries_documents_patch_v1op.py: + id: 31b2201bbfe2 + last_write_checksum: sha1:625739e50a05c7164436063994869e725ab48972 + pristine_git_object: 0ae4efaf7cc7a05f1150a266b8d10d52341ef32a src/mistralai/client/models/libraries_documents_reprocess_v1op.py: id: dbbeb02fc336 last_write_checksum: sha1:bd5013cb1581dd13642ce7edf1e701f5b0c967c4 @@ -4864,8 +5244,12 @@ trackedFiles: pristine_git_object: 7a51d6053aa2cf2e6524a80487fe9549eec3dfa1 src/mistralai/client/models/libraries_list_v1op.py: id: 2d9b1b4deeb0 - last_write_checksum: sha1:1c99dd9165c57ca19d94daf81f31c378125d280b - pristine_git_object: cac06dadbb33c7bf28b276b4c51f569a885ac44e + last_write_checksum: sha1:0c0958ecc928ba180cc265c4b0558eb62db3edb3 + pristine_git_object: 328ac72c2e09158a7e31a445370a4dc2ccc46aef + src/mistralai/client/models/libraries_patch_v1op.py: + id: 2b189be3c57a + last_write_checksum: sha1:6df3bb4ff0c163061963bbf1db9a8c239bfbaa68 + pristine_git_object: 2fbaea6755cad1b0106320a9a058fb02c48edcc6 src/mistralai/client/models/libraries_share_create_v1op.py: id: feaacfd46dd3 last_write_checksum: sha1:cdb7e60f1aceb2c7aa54fe2b9ba5dafc2bb70995 @@ -4884,8 +5268,8 @@ trackedFiles: pristine_git_object: 54b0ab708c665ccb841b1c8d0f2748c390850506 src/mistralai/client/models/library.py: id: 028a34b08f9c - last_write_checksum: sha1:82eb895302f95f3f1a1adf85070027e22ab22350 - pristine_git_object: 0e09cfaa14040397a37ac72810521fb14fe6562f + last_write_checksum: sha1:b15f423354d9f938b6f39cc8ab19095f3203d74f + pristine_git_object: 4ec8604c50da4154796b4267bb639cc4d377f6e6 src/mistralai/client/models/list_deployments_v1_workflows_deployments_getop.py: id: 0c6586ffcab0 last_write_checksum: sha1:c7d7be66560be5bb813316f958a3fecdf7813156 @@ -4962,22 +5346,54 @@ trackedFiles: id: 72a73946b20e last_write_checksum: sha1:18a2d1aeb07ed9d84a1854bb7186e5d32783cb58 pristine_git_object: 4e2ff2f6869517202f4f0c435ce4a6435c5cc571 + src/mistralai/client/models/logicalexpression.py: + id: 48d46c10b453 + last_write_checksum: sha1:4be5e5411b84d61ed53b72140e2914b94902995f + pristine_git_object: 1b87693c0db77be8767af91cc72e80d58a342dab + src/mistralai/client/models/mcpprompt.py: + id: eac4133413b2 + last_write_checksum: sha1:003b0a3bf0f7af4db962697e1604510710709983 + pristine_git_object: fd5fb0d87df899d59d59aa60b2d8becd8a76610b + src/mistralai/client/models/mcpresource.py: + id: 4922063d1d29 + last_write_checksum: sha1:0544a1c3fd247ea67bbc7924700ce9255252dffe + pristine_git_object: 77df58571236b984cc69580f930ac646af44f8dd + src/mistralai/client/models/mcpserverauthenticationrequirement.py: + id: 688772457c1d + last_write_checksum: sha1:befc1fa9206fa19cd320977a89eba6d96ef7bf54 + pristine_git_object: 280315a719d6f5a8183db03b7235871437b467f9 + src/mistralai/client/models/mcpservercard.py: + id: 3d8e787f97f3 + last_write_checksum: sha1:1a947e8f9af8d234f3fae2be377b71b19a819f81 + pristine_git_object: 3e66b9540418cfd6987e4da70f1252b90d1c5382 + src/mistralai/client/models/mcpservercardmeta.py: + id: 0f095765c6aa + last_write_checksum: sha1:34c452143cdda5cfc07b165f6c00bc055c308eb6 + pristine_git_object: daf592f9dc9bece6cefc5a5d3cb2ca5b82bbecae src/mistralai/client/models/mcpservericon.py: id: a5b508a322d7 last_write_checksum: sha1:0dd9bac0684864bf6264ddded7f27c8c88b804f5 pristine_git_object: 293ab37505a1098241631dd83435a0e91d073551 + src/mistralai/client/models/mcpserverremote.py: + id: b20e4512dbe2 + last_write_checksum: sha1:93a620a8c955a788e554453a19bbbcdbfcc7f7d0 + pristine_git_object: 9099207c8e71c1b643641599e2a135a21ba4017a + src/mistralai/client/models/mcpserverremoteheader.py: + id: adaf8d89cbcb + last_write_checksum: sha1:5bf69acdb3aedc19f151d898579d951129c252ca + pristine_git_object: efd1c1fd6c8e896c617ef73d06379a5cafd9aca9 + src/mistralai/client/models/mcpserverrepository.py: + id: 431ce897e113 + last_write_checksum: sha1:670c22c827a6ade10a46f69a21efa01b96cf1b25 + pristine_git_object: eb564992db641642325f55c68cce7355c393d58d src/mistralai/client/models/mcptool.py: id: 5a696c8478cb last_write_checksum: sha1:c4b180a023664313dea583377b79bf53f0f93262 pristine_git_object: 908ff8ce20773a4ca1fd80e47a588acc9ba401af src/mistralai/client/models/mcptoolmeta.py: id: 07cf1c0762c9 - last_write_checksum: sha1:01af35e36f16d4ab4318633b6d773550c8403108 - pristine_git_object: edbf39a9b4c066ea495471cf6ff21b08d8a390a6 - src/mistralai/client/models/mcpuitoolmeta.py: - id: 7c54fb6157a9 - last_write_checksum: sha1:a115ada5e6c22925919160a88a8358c16129bce2 - pristine_git_object: 287192a67a4fe1c22a209996db9b9e8df1a93359 + last_write_checksum: sha1:f47fde183bd997563b1e522125220b31317aba7a + pristine_git_object: ddd7771b2cea71e052b47fec85644f67ce3ce16c src/mistralai/client/models/messageentries.py: id: e13f9009902b last_write_checksum: sha1:43aebdc9eaecc8341298dc6b281d0d57edf4e9e6 @@ -5158,6 +5574,10 @@ trackedFiles: id: d64678967bf0 last_write_checksum: sha1:693e9b575e0da721b15363db1e381d19f8766efb pristine_git_object: a60640aae96b54f7f8e7561029fda45a165007c4 + src/mistralai/client/models/partialscheduledefinition.py: + id: ce1ded792ff5 + last_write_checksum: sha1:e4f50d9cb285dade8dc732547f03908e0b1a9834 + pristine_git_object: 1120dd141a1f7ddadcf0cbe578078496c9287236 src/mistralai/client/models/pause_schedule_v1_workflows_schedules_schedule_id_pause_postop.py: id: "53799174e259" last_write_checksum: sha1:0d12062b4884937e8100490414a29842da524c5f @@ -5188,12 +5608,20 @@ trackedFiles: pristine_git_object: 614f481174e58eb7ba28cae5238b532d1d66ef9c src/mistralai/client/models/processingstatus.py: id: 28146eaecfcf - last_write_checksum: sha1:a3e3ebeae169441cf430c302c9fe278de79ce215 - pristine_git_object: 7e93308f4cf6af8f968e93f20765c41694b8fad9 + last_write_checksum: sha1:4c053b54f4e154e016b1592dfe1de70bfd3699c3 + pristine_git_object: 73308b4658b84ad4a064b3ce18fd96eaeccdd918 src/mistralai/client/models/processstatus.py: id: "0205512146e6" last_write_checksum: sha1:22ad3d5fc80fbf3f83db61512e7bc79295c5fc91 pristine_git_object: 15bdce2056f2f642096fbbdb2ac32ce1e5b8c9cf + src/mistralai/client/models/promptargument.py: + id: 52e5c885f761 + last_write_checksum: sha1:a71c2398080cb96acf20772e3c9436910c5a5b22 + pristine_git_object: 1f73b59f3e5cd74b8b87f70017c3b6704adaa1a2 + src/mistralai/client/models/promptscapability.py: + id: 15c552f53adf + last_write_checksum: sha1:c10ebeb4958239272315cb603e6039182875419a + pristine_git_object: f4ddf63ed454b2c10120b958bda8e859e8909a83 src/mistralai/client/models/prompttokensdetails.py: id: e6be33f2cd2d last_write_checksum: sha1:aa71bf6de6316b8754fb18f897b30051a2d4c70e @@ -5202,6 +5630,10 @@ trackedFiles: id: 545ab7f24523 last_write_checksum: sha1:5256ee8833f1e44717f19b6d2ee3aeff6dbe2dc4 pristine_git_object: 42e943a6f63dcfcfcfc3e994080e318c21a5e619 + src/mistralai/client/models/publicconnectionconfig.py: + id: 03c2460e04ac + last_write_checksum: sha1:faea37686e78fd3cc8a74371a3004d59ca57f4e9 + pristine_git_object: 94fd670836c95c432fd71f1f7dfc16323b50ee24 src/mistralai/client/models/query_workflow_execution_v1_workflows_executions_execution_id_queries_postop.py: id: 73826dbd3f5b last_write_checksum: sha1:5105618697e031bae45cf9f6d7c5227d9c08f155 @@ -5282,6 +5714,14 @@ trackedFiles: id: 4251cc3c7797 last_write_checksum: sha1:fad9dd6a100450397ee358842a31804c3552ca06 pristine_git_object: 890c5be1de611379c12d1525d596bc284e0e197d + src/mistralai/client/models/resourcescapability.py: + id: d109cd5fe17d + last_write_checksum: sha1:b7ebd5ed1b64ee944b0d8534ce1e1bffb3b545fd + pristine_git_object: 39bd1a0b7b48462199d1a7e3cc5351679a78295a + src/mistralai/client/models/resourcetype.py: + id: 58cbbc423f90 + last_write_checksum: sha1:05bedc14374e61522f42d1e655017ecffd6bc9ad + pristine_git_object: 435c917c25e30c6c329dc41a6ee8d7c731fa06f2 src/mistralai/client/models/resourcevisibility.py: id: b5819dd5f981 last_write_checksum: sha1:3c7e91baa8c8a0bb2ba55a6b7c14db04350278d7 @@ -5318,10 +5758,18 @@ trackedFiles: id: e41c04cf7422 last_write_checksum: sha1:e953cc08f43a7a4b8f143830e5308eb26d44f8ac pristine_git_object: ff36ebd72389228752297c1c9ec80deb7557430d + src/mistralai/client/models/rootscapability.py: + id: f1514b6dd416 + last_write_checksum: sha1:55eaee162031944b1a3d334cd2084ca39261de9f + pristine_git_object: 37b25d65f2bff9c8018bce9f82f9e918fd6bca76 src/mistralai/client/models/sampletype.py: id: a9309422fed7 last_write_checksum: sha1:86a61340a647696f6c35a82d945509b1c85aa6f7 pristine_git_object: dfec7cce1e22ab607b6a9e947fa940284426086d + src/mistralai/client/models/samplingcapability.py: + id: 0a7af0cc3968 + last_write_checksum: sha1:dc1c3d442c31adb176fd0d12a5963c850594eb15 + pristine_git_object: 46aa3be5192d2e9ea8cd81c5f078fc90f0d522a6 src/mistralai/client/models/scalarmetric.py: id: ae8eb1017da6 last_write_checksum: sha1:c85c3825e8f60eac8776e912425ed4f43b387ad6 @@ -5332,8 +5780,8 @@ trackedFiles: pristine_git_object: 2cb179eb22e9ac10e820ed276187cd863fc7a440 src/mistralai/client/models/scheduledefinition.py: id: 6ea58a356f77 - last_write_checksum: sha1:a394dee8c49c4a6c6ede7e27ca256a3c376e137b - pristine_git_object: 5810229349e4b84c88458fa729b4b1bce4d761cc + last_write_checksum: sha1:4102a73a034dc19c4ea209104a5531ab4bba9b11 + pristine_git_object: 3c018552dc5b883cc92ced39d4646fc6f13a1da2 src/mistralai/client/models/scheduledefinitionoutput.py: id: 69dc15b9a0d6 last_write_checksum: sha1:4dd8612486768de992731c044cb13b4c52f4622a @@ -5378,26 +5826,46 @@ trackedFiles: id: f96acbcd45f7 last_write_checksum: sha1:539caf622ef9e7579fdc82e7986dcc3a2aedae53 pristine_git_object: 8b9b10b51fe76de43895168df11e5bbcdfc29a62 + src/mistralai/client/models/searchindexresponse.py: + id: 054688d20a3b + last_write_checksum: sha1:6da75c25bd5104344915f4a3ab62ec1eb80e2a5e + pristine_git_object: 0e62aa32470e5f4d4b7fe892a8017a0d6a573e7c src/mistralai/client/models/security.py: id: c2ca0e2a36b7 last_write_checksum: sha1:28496d4ff921e8c2186072aad170c65836a4b8f8 pristine_git_object: 36b129533187283e4fdf53a67019b379b1e251fa + src/mistralai/client/models/servercapabilities.py: + id: 9e5832ea005a + last_write_checksum: sha1:88d632a3dc3e8fd328633278be15d0338f275559 + pristine_git_object: ccfbf932fc59fbd6289b78135114386a476e12e2 + src/mistralai/client/models/serverlocale.py: + id: 5b70fcb88050 + last_write_checksum: sha1:0e6898c0280308f4f17845826dbc110ff7e83f10 + pristine_git_object: 1b73a7494ee64f538c4374998a4e9de0825664e2 + src/mistralai/client/models/servertaskscapability.py: + id: fff9567cb403 + last_write_checksum: sha1:48c88c31c5b7928c7be018155863c0576db1b4c5 + pristine_git_object: 7d2c2927401f5c3c2fdca2980c00c174c1e94741 + src/mistralai/client/models/servertasksrequestscapability.py: + id: 23cc8415f619 + last_write_checksum: sha1:a57769f03d442fc70e5f448ee65876d1a2fff093 + pristine_git_object: 2568507f11f1450dd4419e5dca7d38c9a6ebfcd9 src/mistralai/client/models/shareenum.py: id: a0e2a7a16bf8 last_write_checksum: sha1:15a84d57ceeb74cfb37275f714954e42d8e9b3ba pristine_git_object: 08ffeb7e46fbbc28b7c93ef2aa4a49aff7c0d35e src/mistralai/client/models/sharing.py: id: 324f5ac27249 - last_write_checksum: sha1:b67aa68e320269e0f6da9da23ed35cd1c41f2879 - pristine_git_object: efa16203021055e1f704b2fd3683eeee0a49ba07 + last_write_checksum: sha1:287adc1c670f242ce722c20bd182f6313fa2b372 + pristine_git_object: 4260f1751826195f574a6b84bfdbd4d55b0a617f src/mistralai/client/models/sharingdelete.py: id: f5ecce372e06 - last_write_checksum: sha1:f993f4cc819a14985a70a31af7896115ee80af8a - pristine_git_object: 3472a50637d4582fa8945ec70b57ed12de88b99d + last_write_checksum: sha1:87b3c6e270147260b011eb3d705f84b0fbac1938 + pristine_git_object: 67399831d1f1ff7d7173ea5bf120b114caba6a06 src/mistralai/client/models/sharingrequest.py: id: 2439b732dfae - last_write_checksum: sha1:05e36cba36203bcc579a3b02538aed570cf22352 - pristine_git_object: 7c2d435c363bcd98aba97e120954ec1357524e34 + last_write_checksum: sha1:7439e7d30b6cb676f1edfa86148e4b5e3a8065a6 + pristine_git_object: 94de31c1d2072adfc838e0684cb3573d93df6f8a src/mistralai/client/models/signal_workflow_execution_v1_workflows_executions_execution_id_signals_postop.py: id: 16c54f54e60f last_write_checksum: sha1:57437b8a9d284f7e77459c319908ad0b8db33720 @@ -5466,6 +5934,18 @@ trackedFiles: id: 297e8905d5af last_write_checksum: sha1:e5695ca0ebdb0f02f3a0c527015df154a0c52b7f pristine_git_object: d480a219e935aaea91adc320de0003b562c0bbb5 + src/mistralai/client/models/taskselicitationcapability.py: + id: 19504f19f5f3 + last_write_checksum: sha1:2905488ab1c27912fda77ae08f649956ad8d442e + pristine_git_object: 768f36f1ac7497218c45f823de2662af399cd3db + src/mistralai/client/models/taskssamplingcapability.py: + id: fe3e6aaee007 + last_write_checksum: sha1:e6450ffcec733c2969b3de8873515fe74673576a + pristine_git_object: e051fd75ee3e87be6da8f51a30d0eee12b3b5814 + src/mistralai/client/models/taskstoolscapability.py: + id: ac9448f661ce + last_write_checksum: sha1:e7dd4fcefdd9f89bc7d093d2ded222f0b9e45c99 + pristine_git_object: 88d799c114d3e64e8628c8be43d68934a1b68754 src/mistralai/client/models/tempogettraceresponse.py: id: 8bb3c013aa76 last_write_checksum: sha1:ff35ba718f008554d79defc41dc02af5115c7ab0 @@ -5586,6 +6066,10 @@ trackedFiles: id: 69fcb691327a last_write_checksum: sha1:85bcd4a5d30aab54425bccec9c2374137fad6736 pristine_git_object: 9c55e7bb9db0be106d30b9bf37153aaf8d7b61ff + src/mistralai/client/models/toolexecutionconfiguration.py: + id: 1c9369616b21 + last_write_checksum: sha1:b802788ceb7246914638b2b26f5b053d33913306 + pristine_git_object: ce65ad31408abe1b8bbaa042b176b8555dbf8480 src/mistralai/client/models/toolexecutiondeltaevent.py: id: df8f17cf3e07 last_write_checksum: sha1:77da4c0bca920d4ea77a64faa039fb3c07df46ed @@ -5610,14 +6094,18 @@ trackedFiles: id: 15f1af161031 last_write_checksum: sha1:9557c9f6b7be4b6ac94d3316eb605e42aa8dc03c pristine_git_object: 0dc9e92f5dd27ff93d6de62a6879699ace4300a8 + src/mistralai/client/models/toolproperties.py: + id: 3a33561f76fc + last_write_checksum: sha1:b2059b8c5d6a619f4e637b2395a54a281178282b + pristine_git_object: d3bf9789b77b305a669833ba873fb70231c4c690 src/mistralai/client/models/toolreferencechunk.py: id: 822e9f3e70de last_write_checksum: sha1:2e489c4b2360741a3e4a20710361511a0d9158ea pristine_git_object: 391724edbb7eea3d3acd1a4b3302045970cb5e31 - src/mistralai/client/models/tooltype.py: - id: cbe8c44aee50 - last_write_checksum: sha1:53949106f192944a13a8fcbeb37b3d08478b7bbc - pristine_git_object: 1a7781fc2c1001002785d512ed7909ce91a9129f + src/mistralai/client/models/toolscapability.py: + id: 2feda23ea584 + last_write_checksum: sha1:56c273d54611752761b1e70f209001a6f9559347 + pristine_git_object: 94e5ddc80669d5c06c713c6e422d59a01009dd2f src/mistralai/client/models/trainingfile.py: id: 2edf9bce227d last_write_checksum: sha1:f72468d666e903a966c12273be5a64048dcd59a0 @@ -5654,14 +6142,10 @@ trackedFiles: id: 6086dc081147 last_write_checksum: sha1:968b4bc32731be6c63be3fd90eb26f4357f891a3 pristine_git_object: 42f0ffb7f16bee4f68f9db9807aa4ec3d9ae5176 - src/mistralai/client/models/turbinetoollocale.py: - id: 2699936a7546 - last_write_checksum: sha1:9fa6910a64b464068a660b3d5bf5e09109da283b - pristine_git_object: 42682ee15e542672c190e1b82e713539a6c9b22e - src/mistralai/client/models/turbinetoolmeta.py: - id: cdb07c3837f7 - last_write_checksum: sha1:c2339efbf6dac10bf5e3f42491fa971982d4a998 - pristine_git_object: bcd4d5f2da000bcc4af9c41bf7e92efdaf99b039 + src/mistralai/client/models/turbinemeta.py: + id: 084d588caa1e + last_write_checksum: sha1:4a0ffc6cecc9ad674ab4eab0b3bb017682beddc2 + pristine_git_object: 5084c05f7090f46e35bb63e6fd70c495df3c2044 src/mistralai/client/models/unarchive_workflow_v1_workflows_workflow_identifier_unarchive_putop.py: id: 9df426343c2c last_write_checksum: sha1:12d529f6703695653004ac5692f13daab13bf060 @@ -5694,6 +6178,10 @@ trackedFiles: id: 2a14ebf4ef57 last_write_checksum: sha1:dc63747af5ef650f6d5f5a99e447bebc41450e46 pristine_git_object: 6b7d24d465d34289f97aeb83dc036501883c9c7e + src/mistralai/client/models/update_schedule_v1_workflows_schedules_schedule_id_patchop.py: + id: 6aaa918af7f4 + last_write_checksum: sha1:7bb83c6f98e4314061724c7793e979a47b3f5af7 + pristine_git_object: 5e3a1be42867c2ca00f4c5103ac318dcd5909e44 src/mistralai/client/models/update_voice_v1_audio_voices_voice_id_patchop.py: id: 399da05bd75e last_write_checksum: sha1:aca7b6539571a8111e8f1abb7f90dde1e461d4bc @@ -5712,8 +6200,8 @@ trackedFiles: pristine_git_object: 7bb9686b9b542c47ac25fb6780017b5739829b1e src/mistralai/client/models/updateconnectorrequest.py: id: a761cd154109 - last_write_checksum: sha1:1a943da5e32a0eec70de5a15b56de278082bbc25 - pristine_git_object: 145091d4ce119383e611d845f52dbb4489b78ddf + last_write_checksum: sha1:cff0bc420926e5798c7d9a4dbc6055cf99db32c8 + pristine_git_object: 81f09ea9a124d773de786310c25aa1415fe09da1 src/mistralai/client/models/updatedatasetrecordpayloadrequest.py: id: bd45f357a538 last_write_checksum: sha1:774ba70d9f417e84b546b9f4c5c85eb2876dd56d @@ -5732,8 +6220,8 @@ trackedFiles: pristine_git_object: e878c8764774e4420a85145196cfb93c32d108fa src/mistralai/client/models/updatedocumentrequest.py: id: a8cfda07d337 - last_write_checksum: sha1:612b16cee373b0e395f51eb03b3dff70d7988148 - pristine_git_object: 5f67ea697ac8d4449c76863a8e4f42e0bd197908 + last_write_checksum: sha1:f282948c29e5ef5bdb598e02923a44c0c4215e7a + pristine_git_object: 07c6f5e36119b84fab821967d0b054572fd9d45c src/mistralai/client/models/updateinvocationbody.py: id: b8558eff0be0 last_write_checksum: sha1:ea486ca10c1165b9f3dd40c005cc98bc6b0e937f @@ -5774,22 +6262,34 @@ trackedFiles: id: 15df3c7368ab last_write_checksum: sha1:4acbbd9e47cf9b351336d552488d617270d37758 pristine_git_object: 5fe796db923badd9fb85dc4080a30496ed2b419b + src/mistralai/client/models/vespaschemaresponse.py: + id: fbab188e672e + last_write_checksum: sha1:ad669056fa9c61f0ef7f33430a643fd09a41a788 + pristine_git_object: 440967d1aa77338d7526df06a7322d07fcfaf45d + src/mistralai/client/models/vespasearchindexinforesponse.py: + id: ee7484f75a7c + last_write_checksum: sha1:08714193f3bca9099c051dc3799e04fef2a03b52 + pristine_git_object: a3cce35408346525219693f6b19ae706b20fd743 + src/mistralai/client/models/voiceappearance.py: + id: 945a81bc2582 + last_write_checksum: sha1:c2370a4dfc294932987817b7e4093c7526a53d27 + pristine_git_object: a9d4f2a820ed8b309988cc2221e3f63295094225 src/mistralai/client/models/voicecreaterequest.py: id: 9a1752117dec - last_write_checksum: sha1:6ddd5af32737a8b0597f3fff476f151dbd039e50 - pristine_git_object: 99df178d594f4c5b029dd9dc027e5e1afc3f8dec + last_write_checksum: sha1:f361c10ac84b2696eae0c3d13e3789fa53ee8b20 + pristine_git_object: ec94523f54d9dd0083b685cc0531e27bc251757e src/mistralai/client/models/voicelistresponse.py: id: df4b1182d193 last_write_checksum: sha1:c451d4d0534f4d857f16efde78a7027ae6ca84eb pristine_git_object: eda768f53f2b6273ccae254ba25adf1c157d068a src/mistralai/client/models/voiceresponse.py: id: 24138e419fae - last_write_checksum: sha1:b3f4ef73cc34c3dafa3fa5bf6b4fb02774be04da - pristine_git_object: 6fa3987b8f3361baee9ca3605af0d187ddcb4858 + last_write_checksum: sha1:695a243563d99456c7b660cc16001d19ec6e672f + pristine_git_object: 818bd2578aa49060e889eaa815de1f851dcb2088 src/mistralai/client/models/voiceupdaterequest.py: id: 798f8ff225de - last_write_checksum: sha1:1e4345add08618310635c7b79a8bf3991df98d99 - pristine_git_object: 717316b0033706f1f5fc8fccf3f0159bbc82e8a0 + last_write_checksum: sha1:d4165da1079fe5cfb9cacd8fb1a6837c2ec23119 + pristine_git_object: 4239d01699c4147d752c8c3448a3619ff6a8ff3a src/mistralai/client/models/wandbintegration.py: id: 4823c1e80942 last_write_checksum: sha1:b836b2c829f16a00221354c44f55b672eefc3aa0 @@ -5818,6 +6318,26 @@ trackedFiles: id: 34623036478d last_write_checksum: sha1:0516152c52c443b8b94c830f81f591798f08ac92 pristine_git_object: d2f3db1fb851353d21ce5bbec5e8d2d4b9afabfa + src/mistralai/client/models/workflowbulkarchiverequest.py: + id: 0e0bf7feeede + last_write_checksum: sha1:4d1c8a767f73778f6f2efb1e4d7992df62f872f5 + pristine_git_object: fb2089192ca567a095b48f56f429df288ac750dd + src/mistralai/client/models/workflowbulkarchiveresponse.py: + id: 132f69064b86 + last_write_checksum: sha1:bdb96ed85fd2579c0a41407f9a4795f38e63dedc + pristine_git_object: 506724b3fec8383ef7b7cd8dc7b16e01380e0b78 + src/mistralai/client/models/workflowbulkerror.py: + id: 61b9b62c7fd6 + last_write_checksum: sha1:dd0bed42db7b7ba32c06c3609163681073ee3bb9 + pristine_git_object: 076c938a5223fa19e4929afbb4e2784f3a678745 + src/mistralai/client/models/workflowbulkunarchiverequest.py: + id: b04414883bed + last_write_checksum: sha1:3219afc9903f4f9b7c4eb7e426a74a24ff990c0d + pristine_git_object: 6ffecd91dd3271d311370a6fb07f3539f55eb267 + src/mistralai/client/models/workflowbulkunarchiveresponse.py: + id: 34554c6df2e3 + last_write_checksum: sha1:dc1d73453a4e59deef573a211ccb7e69c5e55cb8 + pristine_git_object: f2ab37272302e036bfdc4e11bd4d76096b4f2c90 src/mistralai/client/models/workflowcodedefinition.py: id: 36fd5b898ddd last_write_checksum: sha1:bd77f4a5e5b32892f806278bcd6dc2d951f10629 @@ -5952,8 +6472,8 @@ trackedFiles: pristine_git_object: 62c379d91f6f8e0b2842b11208513635160a0c02 src/mistralai/client/models/workflowschedulelistresponse.py: id: e5247c5183bb - last_write_checksum: sha1:37cea2f0f3220331105f9454169f1ea49ed1b51a - pristine_git_object: 3c9eb3d7f445a0ec010340aeae788cf47e034628 + last_write_checksum: sha1:10d416a4157ccfd9f60479ea0cd8e4daaaa49cc3 + pristine_git_object: 21341ecad5cb574436d8d2e8beab695f3e637eb0 src/mistralai/client/models/workflowschedulepauserequest.py: id: da7b9a522bcb last_write_checksum: sha1:079663a44a62694c48dd839ef1d3b4cd6fb7429b @@ -5966,6 +6486,10 @@ trackedFiles: id: c77172c4a9f6 last_write_checksum: sha1:dd347319557279367f8ccde9158dec6c4586f528 pristine_git_object: d74ba1dae81bccffa812df2a64babad0a61af787 + src/mistralai/client/models/workflowscheduleupdaterequest.py: + id: 72ca0f5e6c08 + last_write_checksum: sha1:ad25f903339edb6d9d018ba280a39789b81ffb28 + pristine_git_object: b43dc96f32704b4821936189a3f6a8bdcbd77799 src/mistralai/client/models/workflowtaskfailedattributes.py: id: c4c09c4d5ea7 last_write_checksum: sha1:b1faee3ed43b88829ca68f5cd642f24d8f1fe9f5 @@ -6004,52 +6528,56 @@ trackedFiles: pristine_git_object: 81030e21fe08c8ac1401ac6fb0a105f985985cf0 src/mistralai/client/models_.py: id: 1d277958a843 - last_write_checksum: sha1:a5e45504b21a4126a41b59c52be2050cd8215cff - pristine_git_object: 2a00325f9205bec7b5ca6ff8df2915593d12bd0e + last_write_checksum: sha1:13c8bd4907bf201957c2a9da00616618ca13e0db + pristine_git_object: 6263ead9a2934b431111fe1a80d1ba2eccc48f42 src/mistralai/client/observability.py: id: 453a1d06d130 last_write_checksum: sha1:62d4d03a08807271b404a8684b1153a739d70b05 pristine_git_object: 4057909ebc43fc419396582fd69e62ca5135ecb3 src/mistralai/client/ocr.py: id: 2f804a12fc62 - last_write_checksum: sha1:f9fe8ca3be4450aff01d1a159d905b66054cf665 - pristine_git_object: c290b1bb53f62a966f724216b29f9dc3a949197d + last_write_checksum: sha1:8d503853c2571bde3cc8bc205b86fe519788a331 + pristine_git_object: e0bc4e0efc94f3ae143b5a1baf1c2968b3e2967b src/mistralai/client/py.typed: id: d95cd1565e33 last_write_checksum: sha1:8efc425ffe830805ffcc0f3055871bdcdc542c60 pristine_git_object: 3e38f1a929f7d6b1d6de74604aa87e3d8f010544 src/mistralai/client/rag.py: id: 2c2b641de1b6 - last_write_checksum: sha1:d27e705578c277540b90b6a84a4669580170c64e - pristine_git_object: 091b02705ce1bd11ea3dc3602a1ebf8e29815495 + last_write_checksum: sha1:77d6bd45daba9879a753768896dac249eb645996 + pristine_git_object: 934b2374571b475a573d38e59c8fdf40aa5ba3b8 src/mistralai/client/records.py: id: 10f90c990bd8 - last_write_checksum: sha1:3b54fb25751ef4d12a8263bc6f29999a42ac4f61 - pristine_git_object: 2ac04c2fcc4277af7abd42a2a0cacdbba741dd4d + last_write_checksum: sha1:6401ec613de8f53368ca49cbed9a59b9204f8b5b + pristine_git_object: 5a4c3c8463a8245dc5de73c2cf93ba85f870ff5e src/mistralai/client/runs.py: id: 4297d58aeb21 - last_write_checksum: sha1:65b82f507ef945cd17f5f4fc2767d6dab3e6909b - pristine_git_object: d1a242fb2bd517b27656e2f60eef07421418cb6e + last_write_checksum: sha1:70aa67885af67c0a01c91028dad0a7beb4151f44 + pristine_git_object: 01507e33e8b1fb37fbd778fcad8abf3a5f1e8d7e src/mistralai/client/schedules.py: id: d3b4fe452390 - last_write_checksum: sha1:946fac6872a9994efbea349a91c0fd14485859b0 - pristine_git_object: 9b013acdc092797cd78e9be3f50666f4a8203fd9 + last_write_checksum: sha1:573ca09239d46817b60637a6348e02bebb5ca617 + pristine_git_object: c56e497365a765be6d3bc794aab67d63fa9f7cd2 src/mistralai/client/sdk.py: id: 48edbcb38d7e - last_write_checksum: sha1:a606046063cd946633918efa1662846c987c9b7e - pristine_git_object: 03338f46bd3d32f1770ed9b6e4d30f9d707867df + last_write_checksum: sha1:6194b5d4e8259276a5a4a581ef478e35948a59df + pristine_git_object: 86de8dd9f4f2dbd54bc84aec74ae3e44cb1d81b7 src/mistralai/client/sdkconfiguration.py: id: b7dd68a0235e last_write_checksum: sha1:c6944f12c6fdc992d43db943b24c8c90854cde5e pristine_git_object: 712e92e05c7fd3016431ec62ecb7b7789c8b7071 + src/mistralai/client/search_indexes.py: + id: c5a0a7df993a + last_write_checksum: sha1:6e0fcf67162312f3ccba44d1e1f2983bd5635ae8 + pristine_git_object: 522ae338029948d81686f2481287d4745f9737ce src/mistralai/client/speech.py: id: 5c1f1109aa5e - last_write_checksum: sha1:3cbd55d0df062a0de6e93c32816dd6e805018150 - pristine_git_object: 4893684b70781a097845f48c4b0a09b4fcb38dd5 + last_write_checksum: sha1:22ce4e2c43162a21f01dd43e66c3d92945560e72 + pristine_git_object: 42cb1bbb47ac7daf68103b9934d8067f1fda6292 src/mistralai/client/transcriptions.py: id: 75b45780c978 - last_write_checksum: sha1:c72a2c07abd80bc78554669e549ded4ec2b027e7 - pristine_git_object: d84b59f8efbe0adaff62dd4a95a9c7d9bb117d10 + last_write_checksum: sha1:897eee298c4d342650ef73a7c7bcfd640752bba6 + pristine_git_object: b63fd5d0d4c528f9df71c7772ed8e0af08e8ae74 src/mistralai/client/types/__init__.py: id: 000b943f821c last_write_checksum: sha1:12a4ace69cbc63f1125eeddf901afed7cdf378b0 @@ -6136,16 +6664,16 @@ trackedFiles: pristine_git_object: 2469a9f310a37a7170b54853715274f13d38901c src/mistralai/client/voices.py: id: ab76b1377d79 - last_write_checksum: sha1:a8009497c11da1e145fcc462ca5d6e7dcfd6e0f1 - pristine_git_object: e19d5d5a184d08110592147ba04c570cbb2b291a + last_write_checksum: sha1:d106cddf60390d93ae4d2f410a5f1f0e4ce0d0de + pristine_git_object: 2810b922fbc967bba982127ce5bc5f086640e7fd src/mistralai/client/workflows.py: id: e2a0381191f6 - last_write_checksum: sha1:b0644f87b63f179114350f2d90a2ec646cd72931 - pristine_git_object: 2693b05b7716298daafffbc76c7358feb49923c6 + last_write_checksum: sha1:4389be2822f4bd5f439cd752a2b91a7744c72b10 + pristine_git_object: a601594656c0cd542a51a996c189b641a28c4965 src/mistralai/client/workflows_events.py: id: 6d4f674ce8ef - last_write_checksum: sha1:a6362c45808a5fac5bc0a8f58c29b4d9291b9a7d - pristine_git_object: 71e44ac74c571debabf7a8b811f8c244f2b7c30a + last_write_checksum: sha1:7ea1bf2efb7a2113a672a4655c97210d29b6ed29 + pristine_git_object: fbf5bc114974bdca07d59dd0c0a1c4f8a8e5e570 examples: list_models_v1_models_get: speakeasy-default-list-models-v1-models-get: @@ -7997,10 +8525,10 @@ examples: connector_create_v1: speakeasy-default-connector-create-v1: requestBody: - application/json: {"name": "", "description": "unibody usually despite slushy wherever reward stingy from", "server": "https://royal-majority.net/"} + application/json: {"protocol": "mcp", "name": "", "description": "unibody usually despite slushy wherever reward stingy from", "server": "https://royal-majority.net/"} responses: "201": - application/json: {"id": "3633ef72-f5c6-4354-b510-7167244672aa", "name": "", "description": "why yahoo zany potentially", "created_at": "2024-05-03T05:17:01.129Z", "modified_at": "2025-09-26T20:42:01.861Z"} + application/json: {"id": "3633ef72-f5c6-4354-b510-7167244672aa", "name": "", "description": "why yahoo zany potentially", "created_at": "2024-05-03T05:17:01.129Z", "modified_at": "2025-09-26T20:42:01.861Z", "owner_type": 3, "visibility": "private", "private_tool_execution": true, "mistral": false} "422": application/json: {} connector_list_v1: @@ -8034,9 +8562,10 @@ examples: query: fetch_customer_data: false fetch_connection_secrets: false + fetch_user_data: false responses: "200": - application/json: {"id": "f6d4a827-9530-4a4c-af7f-ac5d6264abbf", "name": "", "description": "diversity nudge pulverize offensively", "created_at": "2024-12-11T18:18:39.930Z", "modified_at": "2026-11-21T21:28:01.899Z"} + application/json: {"id": "f6d4a827-9530-4a4c-af7f-ac5d6264abbf", "name": "", "description": "diversity nudge pulverize offensively", "created_at": "2024-12-11T18:18:39.930Z", "modified_at": "2026-11-21T21:28:01.899Z", "owner_type": 4, "visibility": "shared_org", "private_tool_execution": false, "mistral": false} "422": application/json: {} connector_update_v1: @@ -8048,7 +8577,7 @@ examples: application/json: {} responses: "200": - application/json: {"id": "987e4f32-6930-41a7-8adf-6e893eddc3d9", "name": "", "description": "especially usually collaborate likewise svelte tightly very", "created_at": "2026-09-13T13:33:05.718Z", "modified_at": "2026-06-23T06:11:22.023Z"} + application/json: {"id": "987e4f32-6930-41a7-8adf-6e893eddc3d9", "name": "", "description": "especially usually collaborate likewise svelte tightly very", "created_at": "2026-09-13T13:33:05.718Z", "modified_at": "2026-06-23T06:11:22.023Z", "owner_type": 3, "visibility": "shared_global", "private_tool_execution": false, "mistral": false} "422": application/json: {} connector_delete_v1: @@ -8473,6 +9002,8 @@ examples: responses: "200": application/json: {"schedules": []} + "422": + application/json: {} schedule_workflow_v1_workflows_schedules_post: speakeasy-default-schedule-workflow-v1-workflows-schedules-post: requestBody: @@ -8576,7 +9107,7 @@ examples: fetch_default: false responses: "200": - application/json: {"credentials": [{"name": "", "authentication_type": "oauth2", "is_default": false}]} + application/json: {"credentials": [{"name": "", "authentication_type": "oauth2", "scope": "workspace", "is_default": false}]} "422": application/json: {} connector_create_or_update_organization_credentials_v1: @@ -8714,16 +9245,147 @@ examples: responses: "422": application/json: {} + libraries_patch_v1: + speakeasy-default-libraries-patch-v1: + parameters: + path: + library_id: "74a30b7a-ba52-49f7-a8a3-7157e1adf565" + requestBody: + application/json: {} + responses: + "200": + application/json: {"id": "29be96b0-9e62-49f2-ad68-ea214dda839a", "name": "", "created_at": "2025-01-03T19:54:12.078Z", "updated_at": "2025-08-14T09:50:03.685Z", "owner_id": "5d60a792-57b9-45a8-9099-d3a656c15c5e", "owner_type": "", "total_size": 102530, "nb_documents": 298019, "chunk_size": 87858} + "422": + application/json: {} + libraries_documents_patch_v1: + speakeasy-default-libraries-documents-patch-v1: + parameters: + path: + library_id: "2a41249e-52ca-4436-b755-25ce3a9bfb53" + document_id: "bc26fa54-e5d9-4269-bedf-86bed5471c7d" + requestBody: + application/json: {} + responses: + "200": + application/json: {"id": "765f96ad-ca4d-443c-8614-0787ad1baedc", "library_id": "3ef9de21-c727-4a66-8495-9174b23092a7", "hash": "", "mime_type": "", "extension": null, "size": 756040, "name": "", "created_at": "2026-06-24T13:02:34.703Z", "process_status": "noop", "uploaded_by_id": "7048d94f-55be-4b1f-ab73-3f0f5a005ed9", "uploaded_by_type": "", "processing_status": "", "tokens_processing_total": 943369} + "422": + application/json: {} + connector_activate_for_organization_v1: + speakeasy-default-connector-activate-for-organization-v1: + parameters: + path: + connector_id: "a91bb4ec-caab-4cf2-be03-84b8343f4643" + responses: + "200": + application/json: {"message": ""} + "422": + application/json: {} + connector_deactivate_for_organization_v1: + speakeasy-default-connector-deactivate-for-organization-v1: + parameters: + path: + connector_id: "8f4c1089-2a37-44b3-a3c4-830ca7a0e439" + responses: + "200": + application/json: {"message": ""} + "422": + application/json: {} + connector_activate_for_workspace_v1: + speakeasy-default-connector-activate-for-workspace-v1: + parameters: + path: + connector_id: "2adfa8af-3618-41a9-8980-e5ea1486e58e" + responses: + "200": + application/json: {"message": ""} + "422": + application/json: {} + connector_deactivate_for_workspace_v1: + speakeasy-default-connector-deactivate-for-workspace-v1: + parameters: + path: + connector_id: "15b00e98-a9e7-4582-b0fc-87d28c3dac04" + responses: + "200": + application/json: {"message": ""} + "422": + application/json: {} + connector_activate_for_user_v1: + speakeasy-default-connector-activate-for-user-v1: + parameters: + path: + connector_id: "cd4fb4d2-de68-451f-8f2a-57fe39b33d96" + responses: + "200": + application/json: {"message": ""} + "422": + application/json: {} + connector_deactivate_for_user_v1: + speakeasy-default-connector-deactivate-for-user-v1: + parameters: + path: + connector_id: "99c6ed86-e6bb-40ed-b6ee-d22ba791a68f" + responses: + "200": + application/json: {"message": ""} + "422": + application/json: {} + get_search_indexes_v1_rag_search_index_get: + speakeasy-default-get-search-indexes-v1-rag-search-index-get: + responses: + "200": + application/json: [{"id": "07d38908-4a10-4d0f-96d0-001229ae40a6", "name": "", "creator_id": "", "document_count": 47250, "status": "online", "created_at": "2025-05-05T18:06:12.781Z", "modified_at": "2024-11-11T19:44:30.545Z", "index": {"type": "vespa", "k8s_cluster": "", "k8s_namespace": "", "vespa_instance_name": "", "schemas": []}}] + register_search_index_v1_rag_search_index_put: + speakeasy-default-register-search-index-v1-rag-search-index-put: + requestBody: + application/json: {"name": "", "status": "offline", "index": {"type": "vespa", "k8s_cluster": "", "k8s_namespace": "", "vespa_instance_name": "", "schemas": []}} + responses: + "200": + application/json: {"id": "aeab57c4-7bc2-4d90-b739-da6d58fffa60", "name": "", "creator_id": "", "document_count": 577632, "status": "offline", "created_at": "2024-12-18T16:38:29.006Z", "modified_at": "2025-12-02T12:13:54.773Z", "index": {"type": "vespa", "k8s_cluster": "", "k8s_namespace": "", "vespa_instance_name": "", "schemas": [{"name": "", "document_count": 745815}]}} + "422": + application/json: {} + bulk_archive_workflows_v1_workflows_archive_put: + speakeasy-default-bulk-archive-workflows-v1-workflows-archive-put: + requestBody: + application/json: {"workflow_ids": []} + responses: + "200": + application/json: {"archived": [{"id": "7d8a39b0-ac85-4a75-bc3c-a21d9d086958", "name": "", "display_name": "Dominic_Wisozk95", "type": "code", "customer_id": "85b3fb51-c815-4b9e-b51b-8d81a405b5e3", "workspace_id": "7dd61975-6390-409d-b7f3-839b110cbb97", "available_in_chat_assistant": false, "is_technical": false, "on_behalf_of": false, "archived": false}]} + "422": + application/json: {} + bulk_unarchive_workflows_v1_workflows_unarchive_put: + speakeasy-default-bulk-unarchive-workflows-v1-workflows-unarchive-put: + requestBody: + application/json: {"workflow_ids": []} + responses: + "200": + application/json: {"unarchived": []} + "422": + application/json: {} + get_schedule_v1_workflows_schedules__schedule_id__get: + speakeasy-default-get-schedule-v1-workflows-schedules-schedule-id-get: + parameters: + path: + schedule_id: "" + responses: + "200": + application/json: {"input": "", "schedule_id": "", "workflow_name": "", "paused": false} + "422": + application/json: {} + update_schedule_v1_workflows_schedules__schedule_id__patch: + speakeasy-default-update-schedule-v1-workflows-schedules-schedule-id-patch: + parameters: + path: + schedule_id: "" + requestBody: + application/json: {"schedule": {}} + responses: + "200": + application/json: {"schedule_id": ""} + "422": + application/json: {} examplesVersion: 1.0.2 generatedTests: {} -releaseNotes: | - ## Python SDK Changes: - * `mistral.workflows.executions.stream()`: `response.[].data.data.union(CustomTaskInProgressResponse).attributes.payload` **Changed** (Breaking ⚠️) - * `mistral.workflows.events.get_stream_events()`: `response.[].data.data` **Changed** (Breaking ⚠️) - * `mistral.workflows.events.get_workflow_events()`: `response.events[]` **Changed** (Breaking ⚠️) - * `mistral.events.get_stream_events()`: `response.[].data.data.union(CustomTaskInProgressResponse).attributes.payload` **Changed** (Breaking ⚠️) - * `mistral.events.get_workflow_events()`: `response.events[]` **Changed** (Breaking ⚠️) - * `mistral.beta.connectors.get_authentication_methods()`: `response.[].has_default_credentials` **Added** generatedFiles: - .gitattributes - .vscode/settings.json diff --git a/.speakeasy/gen.yaml b/.speakeasy/gen.yaml index a246d5a7..86507823 100644 --- a/.speakeasy/gen.yaml +++ b/.speakeasy/gen.yaml @@ -32,7 +32,7 @@ generation: generateNewTests: false skipResponseBodyAssertions: false python: - version: 2.4.5 + version: 2.4.7 additionalDependencies: dev: pytest: ^8.2.2 diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index 7d463029..f5b175a6 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -16,10 +16,11 @@ sources: - speakeasy-mistralai-gcp-sdk-26292830187-1 mistral-openapi: sourceNamespace: mistral-openapi - sourceRevisionDigest: sha256:6b325264f8e8a60caa875776438b07d4eb5b56283da0796b283e9c5597810e22 - sourceBlobDigest: sha256:11d21b003c903f5539d5d7a79cf8fe17d1d284b48e47da0009eac3866ad58899 + sourceRevisionDigest: sha256:0e18f147a374ca3cc89ea5d05181e8e333f2724201da419e1cccf59192285a9e + sourceBlobDigest: sha256:e2a240443dcc2f25c798e66ba4ba17caec1e7fd80ccca52112e058d08e293e4d tags: - latest + - speakeasy-mistralai-sdk-26292816554-1 targets: mistralai-azure-sdk: source: mistral-azure-source @@ -38,10 +39,10 @@ targets: mistralai-sdk: source: mistral-openapi sourceNamespace: mistral-openapi - sourceRevisionDigest: sha256:6b325264f8e8a60caa875776438b07d4eb5b56283da0796b283e9c5597810e22 - sourceBlobDigest: sha256:11d21b003c903f5539d5d7a79cf8fe17d1d284b48e47da0009eac3866ad58899 + sourceRevisionDigest: sha256:0e18f147a374ca3cc89ea5d05181e8e333f2724201da419e1cccf59192285a9e + sourceBlobDigest: sha256:e2a240443dcc2f25c798e66ba4ba17caec1e7fd80ccca52112e058d08e293e4d codeSamplesNamespace: mistral-openapi-code-samples - codeSamplesRevisionDigest: sha256:95c443855a95966259bd108beec0cbdb8238f6f753dc4b021bf833d398e86c0c + codeSamplesRevisionDigest: sha256:33fc2a349a4e8dfc5211c638cc2c36585d844ba4bd7ebfb2fa17cbe5477a9d34 workflow: workflowVersion: 1.0.0 speakeasyVersion: 1.763.6 diff --git a/README.md b/README.md index 2a3bedff..31e0eeb0 100644 --- a/README.md +++ b/README.md @@ -513,6 +513,12 @@ print(res.choices[0].message.content) * [create](docs/sdks/connectors/README.md#create) - Create a new connector. * [list](docs/sdks/connectors/README.md#list) - List all connectors. * [get_auth_url](docs/sdks/connectors/README.md#get_auth_url) - Get the auth URL for a connector. +* [activate_for_organization](docs/sdks/connectors/README.md#activate_for_organization) - Activate a connector for an organization. +* [deactivate_for_organization](docs/sdks/connectors/README.md#deactivate_for_organization) - Deactivate a connector for an organization. +* [activate_for_workspace](docs/sdks/connectors/README.md#activate_for_workspace) - Activate a connector for a workspace. +* [deactivate_for_workspace](docs/sdks/connectors/README.md#deactivate_for_workspace) - Deactivate a connector for a workspace. +* [activate_for_user](docs/sdks/connectors/README.md#activate_for_user) - Activate a connector for the current user. +* [deactivate_for_user](docs/sdks/connectors/README.md#deactivate_for_user) - Deactivate a connector for the current user. * [call_tool](docs/sdks/connectors/README.md#call_tool) - Call Connector Tool * [list_tools](docs/sdks/connectors/README.md#list_tools) - List tools for a connector. * [get_authentication_methods](docs/sdks/connectors/README.md#get_authentication_methods) - Get authentication methods for a connector. @@ -550,6 +556,7 @@ print(res.choices[0].message.content) * [get](docs/sdks/libraries/README.md#get) - Detailed information about a specific Library. * [delete](docs/sdks/libraries/README.md#delete) - Delete a library and all of it's document. * [update](docs/sdks/libraries/README.md#update) - Update a library. +* [~~libraries_update_v1~~](docs/sdks/libraries/README.md#libraries_update_v1) - Update a library. :warning: **Deprecated** #### [Beta.Libraries.Accesses](docs/sdks/accesses/README.md) @@ -563,6 +570,7 @@ print(res.choices[0].message.content) * [upload](docs/sdks/documents/README.md#upload) - Upload a new document. * [get](docs/sdks/documents/README.md#get) - Retrieve the metadata of a specific document. * [update](docs/sdks/documents/README.md#update) - Update the metadata of a specific document. +* [~~libraries_documents_update_v1~~](docs/sdks/documents/README.md#libraries_documents_update_v1) - Update the metadata of a specific document. :warning: **Deprecated** * [delete](docs/sdks/documents/README.md#delete) - Delete a document. * [text_content](docs/sdks/documents/README.md#text_content) - Retrieve the text content of a specific document. * [status](docs/sdks/documents/README.md#status) - Retrieve the processing status of a specific document. @@ -635,6 +643,11 @@ print(res.choices[0].message.content) * [register](docs/sdks/ingestionpipelineconfigurations/README.md#register) - Register Config * [update_run_info](docs/sdks/ingestionpipelineconfigurations/README.md#update_run_info) - Update Run Info +### [Beta.Rag.SearchIndexes](docs/sdks/searchindexes/README.md) + +* [list](docs/sdks/searchindexes/README.md#list) - Get Search Indexes +* [register](docs/sdks/searchindexes/README.md#register) - Register Search Index + ### [Chat](docs/sdks/chat/README.md) * [complete](docs/sdks/chat/README.md#complete) - Chat Completion @@ -700,6 +713,8 @@ print(res.choices[0].message.content) * [get_workflow](docs/sdks/workflows/README.md#get_workflow) - Get Workflow * [update_workflow](docs/sdks/workflows/README.md#update_workflow) - Update Workflow * [get_workflow_registration](docs/sdks/workflows/README.md#get_workflow_registration) - Get Workflow Registration +* [bulk_archive_workflows](docs/sdks/workflows/README.md#bulk_archive_workflows) - Bulk Archive Workflows +* [bulk_unarchive_workflows](docs/sdks/workflows/README.md#bulk_unarchive_workflows) - Bulk Unarchive Workflows * [archive_workflow](docs/sdks/workflows/README.md#archive_workflow) - Archive Workflow * [unarchive_workflow](docs/sdks/workflows/README.md#unarchive_workflow) - Unarchive Workflow @@ -744,7 +759,9 @@ print(res.choices[0].message.content) * [get_schedules](docs/sdks/schedules/README.md#get_schedules) - Get Schedules * [schedule_workflow](docs/sdks/schedules/README.md#schedule_workflow) - Schedule Workflow +* [get_schedule](docs/sdks/schedules/README.md#get_schedule) - Get Schedule * [unschedule_workflow](docs/sdks/schedules/README.md#unschedule_workflow) - Unschedule Workflow +* [update_schedule](docs/sdks/schedules/README.md#update_schedule) - Update Schedule * [pause_schedule](docs/sdks/schedules/README.md#pause_schedule) - Pause Schedule * [resume_schedule](docs/sdks/schedules/README.md#resume_schedule) - Resume Schedule @@ -958,8 +975,8 @@ with Mistral( **Inherit from [`MistralError`](./src/mistralai/client/errors/mistralerror.py)**: -* [`HTTPValidationError`](./src/mistralai/client/errors/httpvalidationerror.py): Validation Error. Status code `422`. Applicable to 116 of 183 methods.* -* [`ObservabilityError`](./src/mistralai/client/errors/observabilityerror.py): Bad Request - Invalid request parameters or data. Applicable to 41 of 183 methods.* +* [`HTTPValidationError`](./src/mistralai/client/errors/httpvalidationerror.py): Validation Error. Status code `422`. Applicable to 130 of 197 methods.* +* [`ObservabilityError`](./src/mistralai/client/errors/observabilityerror.py): Bad Request - Invalid request parameters or data. Applicable to 41 of 197 methods.* * [`ResponseValidationError`](./src/mistralai/client/errors/responsevalidationerror.py): Type mismatch between the response data and the expected Pydantic model. Provides access to the Pydantic validation error via the `cause` attribute. diff --git a/RELEASES.md b/RELEASES.md index 2f69eacf..f21a0dc2 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -638,4 +638,14 @@ Based on: ### Generated - [python v2.4.5] . ### Releases -- [PyPI v2.4.5] https://pypi.org/project/mistralai/2.4.5 - . \ No newline at end of file +- [PyPI v2.4.5] https://pypi.org/project/mistralai/2.4.5 - . + +## 2026-05-22 14:12:57 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.763.6 (2.884.13) https://github.com/speakeasy-api/speakeasy +### Generated +- [python v2.4.7] . +### Releases +- [PyPI v2.4.7] https://pypi.org/project/mistralai/2.4.7 - . \ No newline at end of file diff --git a/docs/models/authenticationconfiguration.md b/docs/models/authenticationconfiguration.md index 6644875e..cdd1e55f 100644 --- a/docs/models/authenticationconfiguration.md +++ b/docs/models/authenticationconfiguration.md @@ -7,4 +7,5 @@ | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | | `name` | *str* | :heavy_check_mark: | N/A | | `authentication_type` | [models.OutboundAuthenticationType](../models/outboundauthenticationtype.md) | :heavy_check_mark: | N/A | +| `scope` | [models.ConsumerType](../models/consumertype.md) | :heavy_check_mark: | N/A | | `is_default` | *Optional[bool]* | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/clientcapabilities.md b/docs/models/clientcapabilities.md new file mode 100644 index 00000000..236bb0c4 --- /dev/null +++ b/docs/models/clientcapabilities.md @@ -0,0 +1,15 @@ +# ClientCapabilities + +Capabilities a client may support. + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | +| `experimental` | Dict[str, Dict[str, *Any*]] | :heavy_minus_sign: | N/A | +| `sampling` | [OptionalNullable[models.SamplingCapability]](../models/samplingcapability.md) | :heavy_minus_sign: | N/A | +| `elicitation` | [OptionalNullable[models.ElicitationCapability]](../models/elicitationcapability.md) | :heavy_minus_sign: | N/A | +| `roots` | [OptionalNullable[models.RootsCapability]](../models/rootscapability.md) | :heavy_minus_sign: | N/A | +| `tasks` | [OptionalNullable[models.ClientTasksCapability]](../models/clienttaskscapability.md) | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/clienttaskscapability.md b/docs/models/clienttaskscapability.md new file mode 100644 index 00000000..9008ba61 --- /dev/null +++ b/docs/models/clienttaskscapability.md @@ -0,0 +1,13 @@ +# ClientTasksCapability + +Capability for client tasks operations. + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | +| `list` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `cancel` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `requests` | [OptionalNullable[models.ClientTasksRequestsCapability]](../models/clienttasksrequestscapability.md) | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/clienttasksrequestscapability.md b/docs/models/clienttasksrequestscapability.md new file mode 100644 index 00000000..8dac48a4 --- /dev/null +++ b/docs/models/clienttasksrequestscapability.md @@ -0,0 +1,12 @@ +# ClientTasksRequestsCapability + +Capability for tasks requests operations. + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | +| `sampling` | [OptionalNullable[models.TasksSamplingCapability]](../models/taskssamplingcapability.md) | :heavy_minus_sign: | N/A | +| `elicitation` | [OptionalNullable[models.TasksElicitationCapability]](../models/taskselicitationcapability.md) | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/connectionconfigtype.md b/docs/models/connectionconfigtype.md new file mode 100644 index 00000000..8db3ea64 --- /dev/null +++ b/docs/models/connectionconfigtype.md @@ -0,0 +1,19 @@ +# ConnectionConfigType + +## Example Usage + +```python +from mistralai.client.models import ConnectionConfigType + +# Open enum: unrecognized values are captured as UnrecognizedStr +value: ConnectionConfigType = "mcp" +``` + + +## Values + +This is an open enum. Unrecognized values will not fail type checks. + +- `"mcp"` +- `"turbine"` +- `"eolienne"` diff --git a/docs/models/turbinetoolmeta.md b/docs/models/connectionpreference.md similarity index 65% rename from docs/models/turbinetoolmeta.md rename to docs/models/connectionpreference.md index 2f61a2c4..e069233f 100644 --- a/docs/models/turbinetoolmeta.md +++ b/docs/models/connectionpreference.md @@ -1,11 +1,11 @@ -# TurbineToolMeta +# ConnectionPreference ## Fields | Field | Type | Required | Description | | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | -| `locale` | [OptionalNullable[models.TurbineToolLocale]](../models/turbinetoollocale.md) | :heavy_minus_sign: | N/A | -| `tool_type` | [OptionalNullable[models.ToolType]](../models/tooltype.md) | :heavy_minus_sign: | N/A | -| `timeout` | *OptionalNullable[float]* | :heavy_minus_sign: | N/A | -| `private_execution` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | \ No newline at end of file +| `name` | *str* | :heavy_check_mark: | N/A | +| `tool_configuration` | [models.ToolExecutionConfiguration](../models/toolexecutionconfiguration.md) | :heavy_check_mark: | N/A | +| `is_default` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | +| `consumer_type` | [OptionalNullable[models.ConsumerType]](../models/consumertype.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/connector.md b/docs/models/connector.md index 29f8ad07..45aafa1e 100644 --- a/docs/models/connector.md +++ b/docs/models/connector.md @@ -3,13 +3,30 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -| `id` | *str* | :heavy_check_mark: | N/A | -| `name` | *str* | :heavy_check_mark: | N/A | -| `title` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `description` | *str* | :heavy_check_mark: | N/A | -| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | -| `modified_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | -| `server` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `auth_type` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | N/A | +| `name` | *str* | :heavy_check_mark: | N/A | +| `title` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `description` | *str* | :heavy_check_mark: | N/A | +| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | +| `modified_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | +| `server` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `protocol` | [Optional[models.ConnectorProtocol]](../models/connectorprotocol.md) | :heavy_minus_sign: | N/A | +| `icon_url` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `server_card` | [OptionalNullable[models.MCPServerCard]](../models/mcpservercard.md) | :heavy_minus_sign: | N/A | +| `owner_id` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `owner_type` | [models.ResourceType](../models/resourcetype.md) | :heavy_check_mark: | N/A | +| `visibility` | [models.ResourceVisibility](../models/resourcevisibility.md) | :heavy_check_mark: | N/A | +| `locale` | [OptionalNullable[models.ConnectorLocale]](../models/connectorlocale.md) | :heavy_minus_sign: | N/A | +| `system_prompt` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `supported_auth_methods` | List[[models.PublicAuthenticationMethod](../models/publicauthenticationmethod.md)] | :heavy_minus_sign: | N/A | +| `connection_preferences` | List[[models.ConnectionPreference](../models/connectionpreference.md)] | :heavy_minus_sign: | N/A | +| `connection_credentials` | List[[models.AuthenticationConfiguration](../models/authenticationconfiguration.md)] | :heavy_minus_sign: | N/A | +| `active` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | +| `private_tool_execution` | *bool* | :heavy_check_mark: | N/A | +| `mistral` | *Optional[bool]* | :heavy_minus_sign: | N/A | +| `is_authenticated` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | +| `tools` | List[[models.ConnectorTool](../models/connectortool.md)] | :heavy_minus_sign: | N/A | +| `system_prompt_route` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `connection_config` | [OptionalNullable[models.PublicConnectionConfig]](../models/publicconnectionconfig.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/connectoractivatefororganizationv1request.md b/docs/models/connectoractivatefororganizationv1request.md new file mode 100644 index 00000000..40469996 --- /dev/null +++ b/docs/models/connectoractivatefororganizationv1request.md @@ -0,0 +1,9 @@ +# ConnectorActivateForOrganizationV1Request + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | +| `connector_id` | *str* | :heavy_check_mark: | N/A | +| `tool_execution_configuration` | [OptionalNullable[models.ToolExecutionConfiguration]](../models/toolexecutionconfiguration.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/connectoractivateforuserv1request.md b/docs/models/connectoractivateforuserv1request.md new file mode 100644 index 00000000..bdf73b8a --- /dev/null +++ b/docs/models/connectoractivateforuserv1request.md @@ -0,0 +1,9 @@ +# ConnectorActivateForUserV1Request + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | +| `connector_id` | *str* | :heavy_check_mark: | N/A | +| `tool_execution_configuration` | [OptionalNullable[models.ToolExecutionConfiguration]](../models/toolexecutionconfiguration.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/connectoractivateforworkspacev1request.md b/docs/models/connectoractivateforworkspacev1request.md new file mode 100644 index 00000000..e4dbaf1d --- /dev/null +++ b/docs/models/connectoractivateforworkspacev1request.md @@ -0,0 +1,9 @@ +# ConnectorActivateForWorkspaceV1Request + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | +| `connector_id` | *str* | :heavy_check_mark: | N/A | +| `tool_execution_configuration` | [OptionalNullable[models.ToolExecutionConfiguration]](../models/toolexecutionconfiguration.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/connectordeactivatefororganizationv1request.md b/docs/models/connectordeactivatefororganizationv1request.md new file mode 100644 index 00000000..1fd64004 --- /dev/null +++ b/docs/models/connectordeactivatefororganizationv1request.md @@ -0,0 +1,8 @@ +# ConnectorDeactivateForOrganizationV1Request + + +## Fields + +| Field | Type | Required | Description | +| ------------------ | ------------------ | ------------------ | ------------------ | +| `connector_id` | *str* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/connectordeactivateforuserv1request.md b/docs/models/connectordeactivateforuserv1request.md new file mode 100644 index 00000000..992603b0 --- /dev/null +++ b/docs/models/connectordeactivateforuserv1request.md @@ -0,0 +1,8 @@ +# ConnectorDeactivateForUserV1Request + + +## Fields + +| Field | Type | Required | Description | +| ------------------ | ------------------ | ------------------ | ------------------ | +| `connector_id` | *str* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/connectordeactivateforworkspacev1request.md b/docs/models/connectordeactivateforworkspacev1request.md new file mode 100644 index 00000000..15033f29 --- /dev/null +++ b/docs/models/connectordeactivateforworkspacev1request.md @@ -0,0 +1,8 @@ +# ConnectorDeactivateForWorkspaceV1Request + + +## Fields + +| Field | Type | Required | Description | +| ------------------ | ------------------ | ------------------ | ------------------ | +| `connector_id` | *str* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/connectorgetv1request.md b/docs/models/connectorgetv1request.md index c45148b9..35a6f393 100644 --- a/docs/models/connectorgetv1request.md +++ b/docs/models/connectorgetv1request.md @@ -5,6 +5,6 @@ | Field | Type | Required | Description | | --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | +| `fetch_user_data` | *Optional[bool]* | :heavy_minus_sign: | Fetch the user-level data associated with the connector (e.g. connection credentials). | | `fetch_customer_data` | *Optional[bool]* | :heavy_minus_sign: | Fetch the customer data associated with the connector (e.g. customer secrets / config). | -| `fetch_connection_secrets` | *Optional[bool]* | :heavy_minus_sign: | Fetch the general connection secrets associated with the connector. | | `connector_id_or_name` | *str* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/connectorlocale.md b/docs/models/connectorlocale.md new file mode 100644 index 00000000..c2e7cf5b --- /dev/null +++ b/docs/models/connectorlocale.md @@ -0,0 +1,10 @@ +# ConnectorLocale + + +## Fields + +| Field | Type | Required | Description | +| ------------------ | ------------------ | ------------------ | ------------------ | +| `name` | Dict[str, *str*] | :heavy_check_mark: | N/A | +| `description` | Dict[str, *str*] | :heavy_check_mark: | N/A | +| `usage_sentence` | Dict[str, *str*] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/tooltype.md b/docs/models/connectorprotocol.md similarity index 56% rename from docs/models/tooltype.md rename to docs/models/connectorprotocol.md index 2a64e130..77d28458 100644 --- a/docs/models/tooltype.md +++ b/docs/models/connectorprotocol.md @@ -1,12 +1,12 @@ -# ToolType +# ConnectorProtocol ## Example Usage ```python -from mistralai.client.models import ToolType +from mistralai.client.models import ConnectorProtocol # Open enum: unrecognized values are captured as UnrecognizedStr -value: ToolType = "rag" +value: ConnectorProtocol = "mcp" ``` @@ -14,7 +14,6 @@ value: ToolType = "rag" This is an open enum. Unrecognized values will not fail type checks. -- `"rag"` -- `"image"` -- `"code"` -- `"event"` +- `"mcp"` +- `"http"` +- `"turbine"` diff --git a/docs/models/connectorsqueryfilters.md b/docs/models/connectorsqueryfilters.md index aea47e14..37c19e7a 100644 --- a/docs/models/connectorsqueryfilters.md +++ b/docs/models/connectorsqueryfilters.md @@ -5,5 +5,4 @@ | Field | Type | Required | Description | | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -| `active` | *OptionalNullable[bool]* | :heavy_minus_sign: | Filter for active connectors for a given user, workspace and organization. | -| `fetch_connection_secrets` | *Optional[bool]* | :heavy_minus_sign: | Fetch connection secrets. | \ No newline at end of file +| `active` | *OptionalNullable[bool]* | :heavy_minus_sign: | Filter for active connectors for a given user, workspace and organization. | \ No newline at end of file diff --git a/docs/models/consumertype.md b/docs/models/consumertype.md new file mode 100644 index 00000000..9ac4df3f --- /dev/null +++ b/docs/models/consumertype.md @@ -0,0 +1,20 @@ +# ConsumerType + +## Example Usage + +```python +from mistralai.client.models import ConsumerType + +# Open enum: unrecognized values are captured as UnrecognizedStr +value: ConsumerType = "user" +``` + + +## Values + +This is an open enum. Unrecognized values will not fail type checks. + +- `"user"` +- `"org"` +- `"workspace"` +- `"system"` diff --git a/docs/models/createconnectorrequest.md b/docs/models/createconnectorrequest.md index 111c460a..eb14f585 100644 --- a/docs/models/createconnectorrequest.md +++ b/docs/models/createconnectorrequest.md @@ -5,6 +5,7 @@ | Field | Type | Required | Description | | --------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- | +| `protocol` | *Optional[Literal["mcp"]]* | :heavy_minus_sign: | N/A | | `name` | *str* | :heavy_check_mark: | The name of the connector. Should be 64 char length maximum, alphanumeric, only underscores/dashes. | | `title` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional human-readable title for the connector. | | `description` | *str* | :heavy_check_mark: | The description of the connector. | diff --git a/docs/models/createlibraryrequest.md b/docs/models/createlibraryrequest.md index 07ff97d0..fd94c1ca 100644 --- a/docs/models/createlibraryrequest.md +++ b/docs/models/createlibraryrequest.md @@ -7,5 +7,5 @@ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `name` | *str* | :heavy_check_mark: | N/A | | `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `chunk_size` | *OptionalNullable[int]* | :heavy_minus_sign: | The size of the chunks (in characters) to split document text into. Must be between 256 and 32768. | +| ~~`chunk_size`~~ | *OptionalNullable[int]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

The size of the chunks (in characters) to split document text into. Must be between 256 and 32768. | | `owner_type` | [OptionalNullable[models.OwnerType]](../models/ownertype.md) | :heavy_minus_sign: | Determines who owns the created library. 'User' creates a private library accessible only to its owner. 'Workspace' creates a library shared with the workspace. Defaults to 'Workspace' for API key sessions. Only API keys with the 'Private and shared connectors' connector access scope can create private, user-owned libraries. | \ No newline at end of file diff --git a/docs/models/createsearchindexinforequest.md b/docs/models/createsearchindexinforequest.md new file mode 100644 index 00000000..64b22aa4 --- /dev/null +++ b/docs/models/createsearchindexinforequest.md @@ -0,0 +1,11 @@ +# CreateSearchIndexInfoRequest + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | +| `name` | *str* | :heavy_check_mark: | N/A | +| `document_count` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | +| `status` | [Optional[models.CreateSearchIndexInfoRequestStatus]](../models/createsearchindexinforequeststatus.md) | :heavy_minus_sign: | N/A | +| `index` | [models.CreateSearchIndexInfoRequestIndex](../models/createsearchindexinforequestindex.md) | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/createsearchindexinforequestindex.md b/docs/models/createsearchindexinforequestindex.md new file mode 100644 index 00000000..42d99fcb --- /dev/null +++ b/docs/models/createsearchindexinforequestindex.md @@ -0,0 +1,11 @@ +# CreateSearchIndexInfoRequestIndex + + +## Supported Types + +### `models.CreateVespaSearchIndexInfoRequest` + +```python +value: models.CreateVespaSearchIndexInfoRequest = /* values here */ +``` + diff --git a/docs/models/createsearchindexinforequeststatus.md b/docs/models/createsearchindexinforequeststatus.md new file mode 100644 index 00000000..1e477acc --- /dev/null +++ b/docs/models/createsearchindexinforequeststatus.md @@ -0,0 +1,14 @@ +# CreateSearchIndexInfoRequestStatus + +## Example Usage + +```python +from mistralai.client.models import CreateSearchIndexInfoRequestStatus +value: CreateSearchIndexInfoRequestStatus = "online" +``` + + +## Values + +- `"online"` +- `"offline"` diff --git a/docs/models/createvespaschemarequest.md b/docs/models/createvespaschemarequest.md new file mode 100644 index 00000000..3098a2b9 --- /dev/null +++ b/docs/models/createvespaschemarequest.md @@ -0,0 +1,9 @@ +# CreateVespaSchemaRequest + + +## Fields + +| Field | Type | Required | Description | +| ----------------------- | ----------------------- | ----------------------- | ----------------------- | +| `name` | *str* | :heavy_check_mark: | N/A | +| `document_count` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/createvespasearchindexinforequest.md b/docs/models/createvespasearchindexinforequest.md new file mode 100644 index 00000000..0bd47c38 --- /dev/null +++ b/docs/models/createvespasearchindexinforequest.md @@ -0,0 +1,12 @@ +# CreateVespaSearchIndexInfoRequest + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | +| `type` | *Literal["vespa"]* | :heavy_check_mark: | N/A | +| `k8s_cluster` | *str* | :heavy_check_mark: | N/A | +| `k8s_namespace` | *str* | :heavy_check_mark: | N/A | +| `vespa_instance_name` | *str* | :heavy_check_mark: | N/A | +| `schemas` | List[[models.CreateVespaSchemaRequest](../models/createvespaschemarequest.md)] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/document.md b/docs/models/document.md index 42c639a6..ff0238ea 100644 --- a/docs/models/document.md +++ b/docs/models/document.md @@ -3,25 +3,26 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -| `id` | *str* | :heavy_check_mark: | N/A | -| `library_id` | *str* | :heavy_check_mark: | N/A | -| `hash` | *Nullable[str]* | :heavy_check_mark: | N/A | -| `mime_type` | *Nullable[str]* | :heavy_check_mark: | N/A | -| `extension` | *Nullable[str]* | :heavy_check_mark: | N/A | -| `size` | *Nullable[int]* | :heavy_check_mark: | N/A | -| `name` | *str* | :heavy_check_mark: | N/A | -| `summary` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | -| `last_processed_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | N/A | -| `number_of_pages` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | -| `process_status` | [models.ProcessStatus](../models/processstatus.md) | :heavy_check_mark: | N/A | -| `uploaded_by_id` | *Nullable[str]* | :heavy_check_mark: | N/A | -| `uploaded_by_type` | *str* | :heavy_check_mark: | N/A | -| `tokens_processing_main_content` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | -| `tokens_processing_summary` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | -| `url` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `attributes` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | -| `processing_status` | *str* | :heavy_check_mark: | N/A | -| `tokens_processing_total` | *int* | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | N/A | +| `library_id` | *str* | :heavy_check_mark: | N/A | +| ~~`hash`~~ | *Nullable[str]* | :heavy_check_mark: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| `mime_type` | *Nullable[str]* | :heavy_check_mark: | N/A | +| `extension` | *Nullable[str]* | :heavy_check_mark: | N/A | +| `size` | *Nullable[int]* | :heavy_check_mark: | N/A | +| `name` | *str* | :heavy_check_mark: | N/A | +| `summary` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | +| `last_processed_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | N/A | +| `number_of_pages` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | +| `process_status` | [models.ProcessStatus](../models/processstatus.md) | :heavy_check_mark: | N/A | +| `uploaded_by_id` | *Nullable[str]* | :heavy_check_mark: | N/A | +| `uploaded_by_type` | *str* | :heavy_check_mark: | N/A | +| ~~`tokens_processing_main_content`~~ | *OptionalNullable[int]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| ~~`tokens_processing_summary`~~ | *OptionalNullable[int]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| `url` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `attributes` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `expires_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | If set, the document will be automatically deleted after this date. | +| ~~`processing_status`~~ | *str* | :heavy_check_mark: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| `tokens_processing_total` | *int* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/elicitationcapability.md b/docs/models/elicitationcapability.md new file mode 100644 index 00000000..c2f8fab6 --- /dev/null +++ b/docs/models/elicitationcapability.md @@ -0,0 +1,14 @@ +# ElicitationCapability + +Capability for elicitation operations. + +Clients must support at least one mode (form or url). + + +## Fields + +| Field | Type | Required | Description | +| -------------------- | -------------------- | -------------------- | -------------------- | +| `form` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `url` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/encryptedpatchvalue.md b/docs/models/encryptedpatchvalue.md new file mode 100644 index 00000000..1d5988b4 --- /dev/null +++ b/docs/models/encryptedpatchvalue.md @@ -0,0 +1,16 @@ +# EncryptedPatchValue + +Wrapper for encrypted patch values in selective json_patch encryption. + +When partial encryption mode is enabled and a patch targets an EncryptedStrField, +the patch value is encrypted and wrapped in this structure. + +The type field acts as a discriminator to distinguish this from user data. + + +## Fields + +| Field | Type | Required | Description | +| -------------------------- | -------------------------- | -------------------------- | -------------------------- | +| `type` | *Literal["__encrypted__"]* | :heavy_check_mark: | N/A | +| `value` | *str* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/expression.md b/docs/models/expression.md new file mode 100644 index 00000000..d7de83a9 --- /dev/null +++ b/docs/models/expression.md @@ -0,0 +1,23 @@ +# Expression + + +## Supported Types + +### `List[str]` + +```python +value: List[str] = /* values here */ +``` + +### `models.LogicalExpression` + +```python +value: models.LogicalExpression = /* values here */ +``` + +### `models.ToolProperties` + +```python +value: models.ToolProperties = /* values here */ +``` + diff --git a/docs/models/getschedulesv1workflowsschedulesgetrequest.md b/docs/models/getschedulesv1workflowsschedulesgetrequest.md new file mode 100644 index 00000000..d510c27d --- /dev/null +++ b/docs/models/getschedulesv1workflowsschedulesgetrequest.md @@ -0,0 +1,12 @@ +# GetSchedulesV1WorkflowsSchedulesGetRequest + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | +| `workflow_name` | *OptionalNullable[str]* | :heavy_minus_sign: | Filter by workflow name | +| `user_id` | *OptionalNullable[str]* | :heavy_minus_sign: | Filter by user ID. Pass 'current' to resolve to the authenticated user's ID. | +| `status` | [OptionalNullable[models.GetSchedulesV1WorkflowsSchedulesGetStatus]](../models/getschedulesv1workflowsschedulesgetstatus.md) | :heavy_minus_sign: | Filter by schedule status: 'active' or 'paused' | +| `page_size` | *OptionalNullable[int]* | :heavy_minus_sign: | Number of items per page. Omitting this parameter fetches all results at once (deprecated — pass page_size to use pagination). | +| `next_page_token` | *OptionalNullable[str]* | :heavy_minus_sign: | Token for the next page of results | \ No newline at end of file diff --git a/docs/models/getschedulesv1workflowsschedulesgetresponse.md b/docs/models/getschedulesv1workflowsschedulesgetresponse.md new file mode 100644 index 00000000..20adb3c0 --- /dev/null +++ b/docs/models/getschedulesv1workflowsschedulesgetresponse.md @@ -0,0 +1,8 @@ +# GetSchedulesV1WorkflowsSchedulesGetResponse + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | +| `result` | [models.WorkflowScheduleListResponse](../models/workflowschedulelistresponse.md) | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/getschedulesv1workflowsschedulesgetstatus.md b/docs/models/getschedulesv1workflowsschedulesgetstatus.md new file mode 100644 index 00000000..312db2cd --- /dev/null +++ b/docs/models/getschedulesv1workflowsschedulesgetstatus.md @@ -0,0 +1,16 @@ +# GetSchedulesV1WorkflowsSchedulesGetStatus + +Filter by schedule status: 'active' or 'paused' + +## Example Usage + +```python +from mistralai.client.models import GetSchedulesV1WorkflowsSchedulesGetStatus +value: GetSchedulesV1WorkflowsSchedulesGetStatus = "active" +``` + + +## Values + +- `"active"` +- `"paused"` diff --git a/docs/models/getschedulev1workflowsschedulesscheduleidgetrequest.md b/docs/models/getschedulev1workflowsschedulesscheduleidgetrequest.md new file mode 100644 index 00000000..e681e674 --- /dev/null +++ b/docs/models/getschedulev1workflowsschedulesscheduleidgetrequest.md @@ -0,0 +1,8 @@ +# GetScheduleV1WorkflowsSchedulesScheduleIDGetRequest + + +## Fields + +| Field | Type | Required | Description | +| ------------------ | ------------------ | ------------------ | ------------------ | +| `schedule_id` | *str* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/jsonpatchappend.md b/docs/models/jsonpatchappend.md index 684cc896..903d6c71 100644 --- a/docs/models/jsonpatchappend.md +++ b/docs/models/jsonpatchappend.md @@ -6,5 +6,5 @@ | Field | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `path` | *str* | :heavy_check_mark: | A JSON Pointer (RFC 6901) identifying the target location within the document. Can be a string path (e.g., '/foo/bar'), '/', '', or an empty list [] for root-level operations. | -| `value` | *str* | :heavy_check_mark: | The value to use for the operation. A string to append to the existing value | +| `value` | [models.JSONPatchAppendValue](../models/jsonpatchappendvalue.md) | :heavy_check_mark: | The value to use for the operation. A string to append to the existing value, or an EncryptedPatchValue wrapper when encryption is applied. | | `op` | *Literal["append"]* | :heavy_check_mark: | 'append' is an extension for efficient string concatenation in streaming scenarios. | \ No newline at end of file diff --git a/docs/models/jsonpatchappendvalue.md b/docs/models/jsonpatchappendvalue.md new file mode 100644 index 00000000..551cafe1 --- /dev/null +++ b/docs/models/jsonpatchappendvalue.md @@ -0,0 +1,19 @@ +# JSONPatchAppendValue + +The value to use for the operation. A string to append to the existing value, or an EncryptedPatchValue wrapper when encryption is applied. + + +## Supported Types + +### `str` + +```python +value: str = /* values here */ +``` + +### `models.EncryptedPatchValue` + +```python +value: models.EncryptedPatchValue = /* values here */ +``` + diff --git a/docs/models/librariesdocumentslistv1request.md b/docs/models/librariesdocumentslistv1request.md index 44f63001..6149336f 100644 --- a/docs/models/librariesdocumentslistv1request.md +++ b/docs/models/librariesdocumentslistv1request.md @@ -3,12 +3,12 @@ ## Fields -| Field | Type | Required | Description | -| ----------------------- | ----------------------- | ----------------------- | ----------------------- | -| `library_id` | *str* | :heavy_check_mark: | N/A | -| `search` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `page_size` | *Optional[int]* | :heavy_minus_sign: | N/A | -| `page` | *Optional[int]* | :heavy_minus_sign: | N/A | -| `filters_attributes` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `sort_by` | *Optional[str]* | :heavy_minus_sign: | N/A | -| `sort_order` | *Optional[str]* | :heavy_minus_sign: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `library_id` | *str* | :heavy_check_mark: | N/A | +| `search` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `page_size` | *Optional[int]* | :heavy_minus_sign: | N/A | +| `page` | *Optional[int]* | :heavy_minus_sign: | N/A | +| ~~`filters_attributes`~~ | *OptionalNullable[str]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Deprecated: this parameter will be removed in a future version. | +| `sort_by` | *Optional[str]* | :heavy_minus_sign: | N/A | +| `sort_order` | *Optional[str]* | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/librariesdocumentspatchv1request.md b/docs/models/librariesdocumentspatchv1request.md new file mode 100644 index 00000000..511aee46 --- /dev/null +++ b/docs/models/librariesdocumentspatchv1request.md @@ -0,0 +1,10 @@ +# LibrariesDocumentsPatchV1Request + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | +| `library_id` | *str* | :heavy_check_mark: | N/A | +| `document_id` | *str* | :heavy_check_mark: | N/A | +| `update_document_request` | [models.UpdateDocumentRequest](../models/updatedocumentrequest.md) | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/librarieslistv1request.md b/docs/models/librarieslistv1request.md index 37352ee1..5efdb897 100644 --- a/docs/models/librarieslistv1request.md +++ b/docs/models/librarieslistv1request.md @@ -3,9 +3,9 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `page_size` | *Optional[int]* | :heavy_minus_sign: | N/A | -| `page` | *Optional[int]* | :heavy_minus_sign: | N/A | -| `search` | *OptionalNullable[str]* | :heavy_minus_sign: | Case-insensitive search on the library name. | -| `filter_owned_by_me` | *OptionalNullable[bool]* | :heavy_minus_sign: | Filter libraries by whether they were created by the current authenticated identity. Set to true for created by me, false for only libraries shared with me, or None to disable this filter. | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `page_size` | *Optional[int]* | :heavy_minus_sign: | N/A | +| `page` | *Optional[int]* | :heavy_minus_sign: | N/A | +| `search` | *OptionalNullable[str]* | :heavy_minus_sign: | Case-insensitive search on the library name. | +| ~~`filter_owned_by_me`~~ | *OptionalNullable[bool]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Deprecated: this parameter will be removed in a future version. | \ No newline at end of file diff --git a/docs/models/librariespatchv1request.md b/docs/models/librariespatchv1request.md new file mode 100644 index 00000000..47648086 --- /dev/null +++ b/docs/models/librariespatchv1request.md @@ -0,0 +1,9 @@ +# LibrariesPatchV1Request + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | +| `library_id` | *str* | :heavy_check_mark: | N/A | +| `update_library_request` | [models.UpdateLibraryRequest](../models/updatelibraryrequest.md) | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/library.md b/docs/models/library.md index a07d3afa..5b9aa658 100644 --- a/docs/models/library.md +++ b/docs/models/library.md @@ -3,21 +3,21 @@ ## Fields -| Field | Type | Required | Description | -| ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | -| `id` | *str* | :heavy_check_mark: | N/A | -| `name` | *str* | :heavy_check_mark: | N/A | -| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | -| `updated_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | -| `owner_id` | *Nullable[str]* | :heavy_check_mark: | N/A | -| `owner_type` | *str* | :heavy_check_mark: | N/A | -| `total_size` | *int* | :heavy_check_mark: | N/A | -| `nb_documents` | *int* | :heavy_check_mark: | N/A | -| `chunk_size` | *Nullable[int]* | :heavy_check_mark: | N/A | -| `emoji` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `generated_description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `explicit_user_members_count` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | -| `explicit_workspace_members_count` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | -| ~~`org_sharing_role`~~ | *OptionalNullable[str]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | -| `generated_name` | *OptionalNullable[str]* | :heavy_minus_sign: | Generated Name | \ No newline at end of file +| Field | Type | Required | Description | +| --------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | N/A | +| `name` | *str* | :heavy_check_mark: | N/A | +| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | +| `updated_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | +| `owner_id` | *Nullable[str]* | :heavy_check_mark: | N/A | +| `owner_type` | *str* | :heavy_check_mark: | N/A | +| `total_size` | *int* | :heavy_check_mark: | N/A | +| `nb_documents` | *int* | :heavy_check_mark: | N/A | +| ~~`chunk_size`~~ | *Nullable[int]* | :heavy_check_mark: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| ~~`emoji`~~ | *OptionalNullable[str]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| ~~`generated_description`~~ | *OptionalNullable[str]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| ~~`explicit_user_members_count`~~ | *OptionalNullable[int]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| ~~`explicit_workspace_members_count`~~ | *OptionalNullable[int]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| ~~`org_sharing_role`~~ | *OptionalNullable[str]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| ~~`generated_name`~~ | *OptionalNullable[str]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Generated Name | \ No newline at end of file diff --git a/docs/models/logicalexpression.md b/docs/models/logicalexpression.md new file mode 100644 index 00000000..675368e7 --- /dev/null +++ b/docs/models/logicalexpression.md @@ -0,0 +1,9 @@ +# LogicalExpression + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | +| `type` | [models.LogicalExpressionType](../models/logicalexpressiontype.md) | :heavy_check_mark: | N/A | +| `expressions` | List[[models.Expression](../models/expression.md)] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/visibility.md b/docs/models/logicalexpressiontype.md similarity index 56% rename from docs/models/visibility.md rename to docs/models/logicalexpressiontype.md index 924f2bdd..0d3c1f78 100644 --- a/docs/models/visibility.md +++ b/docs/models/logicalexpressiontype.md @@ -1,12 +1,12 @@ -# Visibility +# LogicalExpressionType ## Example Usage ```python -from mistralai.client.models import Visibility +from mistralai.client.models import LogicalExpressionType # Open enum: unrecognized values are captured as UnrecognizedStr -value: Visibility = "model" +value: LogicalExpressionType = "and" ``` @@ -14,5 +14,5 @@ value: Visibility = "model" This is an open enum. Unrecognized values will not fail type checks. -- `"model"` -- `"app"` +- `"and"` +- `"or"` diff --git a/docs/models/mcpprompt.md b/docs/models/mcpprompt.md new file mode 100644 index 00000000..b68d0046 --- /dev/null +++ b/docs/models/mcpprompt.md @@ -0,0 +1,14 @@ +# MCPPrompt + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | +| `name` | *str* | :heavy_check_mark: | N/A | +| `title` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `arguments` | List[[models.PromptArgument](../models/promptargument.md)] | :heavy_minus_sign: | N/A | +| `icons` | List[[models.MCPServerIcon](../models/mcpservericon.md)] | :heavy_minus_sign: | N/A | +| `meta` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/mcpresource.md b/docs/models/mcpresource.md new file mode 100644 index 00000000..ac3d92a8 --- /dev/null +++ b/docs/models/mcpresource.md @@ -0,0 +1,17 @@ +# MCPResource + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | +| `name` | *str* | :heavy_check_mark: | N/A | +| `title` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `uri` | *str* | :heavy_check_mark: | N/A | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `mime_type` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `size` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | +| `icons` | List[[models.MCPServerIcon](../models/mcpservericon.md)] | :heavy_minus_sign: | N/A | +| `annotations` | [OptionalNullable[models.Annotations]](../models/annotations.md) | :heavy_minus_sign: | N/A | +| `meta` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/mcpserverauthenticationrequirement.md b/docs/models/mcpserverauthenticationrequirement.md new file mode 100644 index 00000000..a3824be6 --- /dev/null +++ b/docs/models/mcpserverauthenticationrequirement.md @@ -0,0 +1,11 @@ +# MCPServerAuthenticationRequirement + +Authentication requirements for a remote transport (SEP-2127). + + +## Fields + +| Field | Type | Required | Description | +| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- | --------------------------------------------- | +| `required` | *bool* | :heavy_check_mark: | Whether authentication is mandatory | +| `schemes` | List[*str*] | :heavy_minus_sign: | Supported schemes (e.g. ['bearer', 'oauth2']) | \ No newline at end of file diff --git a/docs/models/mcpservercard.md b/docs/models/mcpservercard.md new file mode 100644 index 00000000..ebc72b07 --- /dev/null +++ b/docs/models/mcpservercard.md @@ -0,0 +1,23 @@ +# MCPServerCard + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | +| `dollar_schema` | *OptionalNullable[str]* | :heavy_minus_sign: | URL to the JSON schema definition | +| `name` | *str* | :heavy_check_mark: | Server identifier in reverse-DNS format with exactly one / | +| `version` | *str* | :heavy_check_mark: | Server version (semantic versioning preferred) | +| `capabilities` | [Optional[models.ServerCapabilities]](../models/servercapabilities.md) | :heavy_minus_sign: | Capabilities that a server may support. | +| `title` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `website_url` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `repository` | [OptionalNullable[models.MCPServerRepository]](../models/mcpserverrepository.md) | :heavy_minus_sign: | N/A | +| `icons` | List[[models.MCPServerIcon](../models/mcpservericon.md)] | :heavy_minus_sign: | N/A | +| `remotes` | List[[models.MCPServerRemote](../models/mcpserverremote.md)] | :heavy_minus_sign: | N/A | +| `requires` | [OptionalNullable[models.ClientCapabilities]](../models/clientcapabilities.md) | :heavy_minus_sign: | N/A | +| `resources` | [OptionalNullable[models.Resources]](../models/resources.md) | :heavy_minus_sign: | N/A | +| `tools` | [OptionalNullable[models.Tools]](../models/tools.md) | :heavy_minus_sign: | N/A | +| `prompts` | [OptionalNullable[models.Prompts]](../models/prompts.md) | :heavy_minus_sign: | N/A | +| `meta` | [OptionalNullable[models.MCPServerCardMeta]](../models/mcpservercardmeta.md) | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/mcpservercardmeta.md b/docs/models/mcpservercardmeta.md new file mode 100644 index 00000000..52345bcf --- /dev/null +++ b/docs/models/mcpservercardmeta.md @@ -0,0 +1,13 @@ +# MCPServerCardMeta + +Typed _meta for MCP server cards. + +Only the 'turbine' field is typed. Other fields are allowed via extra="allow". + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | +| `ai_mistral_turbine` | [OptionalNullable[models.TurbineMeta]](../models/turbinemeta.md) | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/mcpserverremote.md b/docs/models/mcpserverremote.md new file mode 100644 index 00000000..1c7c4de3 --- /dev/null +++ b/docs/models/mcpserverremote.md @@ -0,0 +1,14 @@ +# MCPServerRemote + +Remote transport endpoint (SEP-2127). + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- | +| `type` | [models.MCPServerRemoteType](../models/mcpserverremotetype.md) | :heavy_check_mark: | Transport type | +| `url` | *str* | :heavy_check_mark: | Transport endpoint URL | +| `supported_protocol_versions` | List[*str*] | :heavy_minus_sign: | N/A | +| `headers` | List[[models.MCPServerRemoteHeader](../models/mcpserverremoteheader.md)] | :heavy_minus_sign: | N/A | +| `authentication` | [OptionalNullable[models.MCPServerAuthenticationRequirement]](../models/mcpserverauthenticationrequirement.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/mcpserverremoteheader.md b/docs/models/mcpserverremoteheader.md new file mode 100644 index 00000000..a3966a54 --- /dev/null +++ b/docs/models/mcpserverremoteheader.md @@ -0,0 +1,15 @@ +# MCPServerRemoteHeader + +Header definition for a remote transport (SEP-2127). + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- | ---------------------------------------- | +| `name` | *str* | :heavy_check_mark: | Header name | +| `description` | *str* | :heavy_check_mark: | Human-readable description of the header | +| `is_required` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | +| `is_secret` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | +| `default` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `choices` | List[*str*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/mcpserverremotetype.md b/docs/models/mcpserverremotetype.md new file mode 100644 index 00000000..ea4585b6 --- /dev/null +++ b/docs/models/mcpserverremotetype.md @@ -0,0 +1,20 @@ +# MCPServerRemoteType + +Transport type + +## Example Usage + +```python +from mistralai.client.models import MCPServerRemoteType + +# Open enum: unrecognized values are captured as UnrecognizedStr +value: MCPServerRemoteType = "streamable-http" +``` + + +## Values + +This is an open enum. Unrecognized values will not fail type checks. + +- `"streamable-http"` +- `"sse"` diff --git a/docs/models/mcpserverrepository.md b/docs/models/mcpserverrepository.md new file mode 100644 index 00000000..16fbdd18 --- /dev/null +++ b/docs/models/mcpserverrepository.md @@ -0,0 +1,12 @@ +# MCPServerRepository + +Source repository information (SEP-2127). + + +## Fields + +| Field | Type | Required | Description | +| --------------------------------- | --------------------------------- | --------------------------------- | --------------------------------- | +| `url` | *str* | :heavy_check_mark: | Repository URL | +| `source` | *str* | :heavy_check_mark: | Source identifier (e.g. 'github') | +| `subfolder` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/mcptoolmeta.md b/docs/models/mcptoolmeta.md index 23e8b64c..723f40b1 100644 --- a/docs/models/mcptoolmeta.md +++ b/docs/models/mcptoolmeta.md @@ -1,14 +1,17 @@ # MCPToolMeta -Typed _meta for MCP tools. - -Only the 'ui' field is typed. Other fields are allowed via extra="allow". - ## Fields | Field | Type | Required | Description | | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | -| `ui` | [OptionalNullable[models.MCPUIToolMeta]](../models/mcpuitoolmeta.md) | :heavy_minus_sign: | N/A | -| `ai_mistral_turbine` | [OptionalNullable[models.TurbineToolMeta]](../models/turbinetoolmeta.md) | :heavy_minus_sign: | N/A | +| `name` | *str* | :heavy_check_mark: | N/A | +| `title` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `input_schema` | Dict[str, *Any*] | :heavy_check_mark: | N/A | +| `output_schema` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `icons` | List[[models.MCPServerIcon](../models/mcpservericon.md)] | :heavy_minus_sign: | N/A | +| `annotations` | [OptionalNullable[models.ToolAnnotations]](../models/toolannotations.md) | :heavy_minus_sign: | N/A | +| `meta` | [OptionalNullable[models.MCPToolMeta]](../models/mcptoolmeta.md) | :heavy_minus_sign: | N/A | +| `execution` | [OptionalNullable[models.ToolExecution]](../models/toolexecution.md) | :heavy_minus_sign: | N/A | | `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/mcpuitoolmeta.md b/docs/models/mcpuitoolmeta.md deleted file mode 100644 index c09b29ad..00000000 --- a/docs/models/mcpuitoolmeta.md +++ /dev/null @@ -1,12 +0,0 @@ -# MCPUIToolMeta - -UI metadata for tools that reference UI resources. - - -## Fields - -| Field | Type | Required | Description | -| -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -| `resource_uri` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `visibility` | List[[models.Visibility](../models/visibility.md)] | :heavy_minus_sign: | N/A | -| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/partialscheduledefinition.md b/docs/models/partialscheduledefinition.md new file mode 100644 index 00000000..e66ee671 --- /dev/null +++ b/docs/models/partialscheduledefinition.md @@ -0,0 +1,23 @@ +# PartialScheduleDefinition + +Schedule definition for partial updates. + +All fields are optional (inherited from _ScheduleRequestBase). Only explicitly-set +fields are applied during an update; unset fields preserve the existing schedule values. + + +## Fields + +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `input` | *Optional[Any]* | :heavy_minus_sign: | Input to provide to the workflow when starting it. | +| `calendars` | List[[models.ScheduleCalendar](../models/schedulecalendar.md)] | :heavy_minus_sign: | Calendar-based specification of times. | +| `intervals` | List[[models.ScheduleInterval](../models/scheduleinterval.md)] | :heavy_minus_sign: | Interval-based specification of times. | +| `cron_expressions` | List[*str*] | :heavy_minus_sign: | Cron-based specification of times. | +| `skip` | List[[models.ScheduleCalendar](../models/schedulecalendar.md)] | :heavy_minus_sign: | Set of calendar times to skip. | +| `start_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | Time after which the first action may be run. | +| `end_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | Time after which no more actions will be run. | +| `jitter` | *OptionalNullable[str]* | :heavy_minus_sign: | Jitter to apply each action.

An action's scheduled time will be incremented by a random value between 0
and this value if present (but not past the next schedule).
| +| `time_zone_name` | *OptionalNullable[str]* | :heavy_minus_sign: | IANA time zone name, for example ``US/Central``. | +| `policy` | [Optional[models.SchedulePolicy]](../models/schedulepolicy.md) | :heavy_minus_sign: | N/A | +| `max_executions` | *OptionalNullable[int]* | :heavy_minus_sign: | Maximum number of times this schedule will trigger a workflow execution. Once this limit is reached, no further executions are triggered automatically. null means unlimited. | \ No newline at end of file diff --git a/docs/models/processingstatus.md b/docs/models/processingstatus.md index 514caa50..1d472b88 100644 --- a/docs/models/processingstatus.md +++ b/docs/models/processingstatus.md @@ -3,8 +3,8 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -| `document_id` | *str* | :heavy_check_mark: | N/A | -| `process_status` | [models.ProcessStatus](../models/processstatus.md) | :heavy_check_mark: | N/A | -| `processing_status` | *str* | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | +| `document_id` | *str* | :heavy_check_mark: | N/A | +| `process_status` | [models.ProcessStatus](../models/processstatus.md) | :heavy_check_mark: | N/A | +| ~~`processing_status`~~ | *str* | :heavy_check_mark: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | \ No newline at end of file diff --git a/docs/models/promptargument.md b/docs/models/promptargument.md new file mode 100644 index 00000000..a8dfdb05 --- /dev/null +++ b/docs/models/promptargument.md @@ -0,0 +1,13 @@ +# PromptArgument + +An argument for a prompt template. + + +## Fields + +| Field | Type | Required | Description | +| ------------------------ | ------------------------ | ------------------------ | ------------------------ | +| `name` | *str* | :heavy_check_mark: | N/A | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `required` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/prompts.md b/docs/models/prompts.md new file mode 100644 index 00000000..9fe85597 --- /dev/null +++ b/docs/models/prompts.md @@ -0,0 +1,17 @@ +# Prompts + + +## Supported Types + +### `str` + +```python +value: str = /* values here */ +``` + +### `List[models.MCPPrompt]` + +```python +value: List[models.MCPPrompt] = /* values here */ +``` + diff --git a/docs/models/promptscapability.md b/docs/models/promptscapability.md new file mode 100644 index 00000000..50ffae2b --- /dev/null +++ b/docs/models/promptscapability.md @@ -0,0 +1,11 @@ +# PromptsCapability + +Capability for prompts operations. + + +## Fields + +| Field | Type | Required | Description | +| ------------------------ | ------------------------ | ------------------------ | ------------------------ | +| `list_changed` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/publicconnectionconfig.md b/docs/models/publicconnectionconfig.md new file mode 100644 index 00000000..56c9ee8e --- /dev/null +++ b/docs/models/publicconnectionconfig.md @@ -0,0 +1,11 @@ +# PublicConnectionConfig + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | +| `type` | [Optional[models.ConnectionConfigType]](../models/connectionconfigtype.md) | :heavy_minus_sign: | N/A | +| `base_url` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `headers` | Dict[str, *str*] | :heavy_minus_sign: | N/A | +| `signed` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/requiresconfirmation.md b/docs/models/requiresconfirmation.md new file mode 100644 index 00000000..e7f1e4a6 --- /dev/null +++ b/docs/models/requiresconfirmation.md @@ -0,0 +1,23 @@ +# RequiresConfirmation + + +## Supported Types + +### `List[str]` + +```python +value: List[str] = /* values here */ +``` + +### `models.LogicalExpression` + +```python +value: models.LogicalExpression = /* values here */ +``` + +### `models.ToolProperties` + +```python +value: models.ToolProperties = /* values here */ +``` + diff --git a/docs/models/resources.md b/docs/models/resources.md new file mode 100644 index 00000000..cf19612e --- /dev/null +++ b/docs/models/resources.md @@ -0,0 +1,17 @@ +# Resources + + +## Supported Types + +### `str` + +```python +value: str = /* values here */ +``` + +### `List[models.MCPResource]` + +```python +value: List[models.MCPResource] = /* values here */ +``` + diff --git a/docs/models/resourcescapability.md b/docs/models/resourcescapability.md new file mode 100644 index 00000000..bbd256d0 --- /dev/null +++ b/docs/models/resourcescapability.md @@ -0,0 +1,12 @@ +# ResourcesCapability + +Capability for resources operations. + + +## Fields + +| Field | Type | Required | Description | +| ------------------------ | ------------------------ | ------------------------ | ------------------------ | +| `subscribe` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | +| `list_changed` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/resourcetype.md b/docs/models/resourcetype.md new file mode 100644 index 00000000..047f96bb --- /dev/null +++ b/docs/models/resourcetype.md @@ -0,0 +1,20 @@ +# ResourceType + +## Example Usage + +```python +from mistralai.client.models import ResourceType + +# Open enum: unrecognized values are captured as UnrecognizedInt +value: ResourceType = 1 +``` + + +## Values + +This is an open enum. Unrecognized values will not fail type checks. + +- `1` +- `2` +- `3` +- `4` diff --git a/docs/models/rootscapability.md b/docs/models/rootscapability.md new file mode 100644 index 00000000..f025431d --- /dev/null +++ b/docs/models/rootscapability.md @@ -0,0 +1,11 @@ +# RootsCapability + +Capability for root operations. + + +## Fields + +| Field | Type | Required | Description | +| ------------------------ | ------------------------ | ------------------------ | ------------------------ | +| `list_changed` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/samplingcapability.md b/docs/models/samplingcapability.md new file mode 100644 index 00000000..b05fb678 --- /dev/null +++ b/docs/models/samplingcapability.md @@ -0,0 +1,12 @@ +# SamplingCapability + +Sampling capability structure, allowing fine-grained capability advertisement. + + +## Fields + +| Field | Type | Required | Description | +| -------------------- | -------------------- | -------------------- | -------------------- | +| `context` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `tools` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/scheduledefinition.md b/docs/models/scheduledefinition.md index 7d0509f6..93c58740 100644 --- a/docs/models/scheduledefinition.md +++ b/docs/models/scheduledefinition.md @@ -22,5 +22,5 @@ Used for input where schedule_id is optional (can be provided or auto-generated) | `jitter` | *OptionalNullable[str]* | :heavy_minus_sign: | Jitter to apply each action.

An action's scheduled time will be incremented by a random value between 0
and this value if present (but not past the next schedule).
| | `time_zone_name` | *OptionalNullable[str]* | :heavy_minus_sign: | IANA time zone name, for example ``US/Central``. | | `policy` | [Optional[models.SchedulePolicy]](../models/schedulepolicy.md) | :heavy_minus_sign: | N/A | -| `schedule_id` | *OptionalNullable[str]* | :heavy_minus_sign: | Unique identifier for the schedule. | -| `max_executions` | *OptionalNullable[int]* | :heavy_minus_sign: | Maximum number of times this schedule will trigger a workflow execution. Once this limit is reached, no further executions are triggered automatically. null means unlimited. | \ No newline at end of file +| `max_executions` | *OptionalNullable[int]* | :heavy_minus_sign: | Maximum number of times this schedule will trigger a workflow execution. Once this limit is reached, no further executions are triggered automatically. null means unlimited. | +| `schedule_id` | *OptionalNullable[str]* | :heavy_minus_sign: | Unique identifier for the schedule. | \ No newline at end of file diff --git a/docs/models/searchindexresponse.md b/docs/models/searchindexresponse.md new file mode 100644 index 00000000..ce6087ec --- /dev/null +++ b/docs/models/searchindexresponse.md @@ -0,0 +1,15 @@ +# SearchIndexResponse + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | +| `id` | *str* | :heavy_check_mark: | N/A | +| `name` | *str* | :heavy_check_mark: | N/A | +| `creator_id` | *str* | :heavy_check_mark: | N/A | +| `document_count` | *int* | :heavy_check_mark: | N/A | +| `status` | [models.SearchIndexResponseStatus](../models/searchindexresponsestatus.md) | :heavy_check_mark: | N/A | +| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | +| `modified_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | +| `index` | [models.SearchIndexResponseIndex](../models/searchindexresponseindex.md) | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/searchindexresponseindex.md b/docs/models/searchindexresponseindex.md new file mode 100644 index 00000000..3093f4d4 --- /dev/null +++ b/docs/models/searchindexresponseindex.md @@ -0,0 +1,11 @@ +# SearchIndexResponseIndex + + +## Supported Types + +### `models.VespaSearchIndexInfoResponse` + +```python +value: models.VespaSearchIndexInfoResponse = /* values here */ +``` + diff --git a/docs/models/searchindexresponsestatus.md b/docs/models/searchindexresponsestatus.md new file mode 100644 index 00000000..c2200101 --- /dev/null +++ b/docs/models/searchindexresponsestatus.md @@ -0,0 +1,18 @@ +# SearchIndexResponseStatus + +## Example Usage + +```python +from mistralai.client.models import SearchIndexResponseStatus + +# Open enum: unrecognized values are captured as UnrecognizedStr +value: SearchIndexResponseStatus = "online" +``` + + +## Values + +This is an open enum. Unrecognized values will not fail type checks. + +- `"online"` +- `"offline"` diff --git a/docs/models/servercapabilities.md b/docs/models/servercapabilities.md new file mode 100644 index 00000000..4faca72e --- /dev/null +++ b/docs/models/servercapabilities.md @@ -0,0 +1,17 @@ +# ServerCapabilities + +Capabilities that a server may support. + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | +| `experimental` | Dict[str, Dict[str, *Any*]] | :heavy_minus_sign: | N/A | +| `logging` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `prompts` | [OptionalNullable[models.PromptsCapability]](../models/promptscapability.md) | :heavy_minus_sign: | N/A | +| `resources` | [OptionalNullable[models.ResourcesCapability]](../models/resourcescapability.md) | :heavy_minus_sign: | N/A | +| `tools` | [OptionalNullable[models.ToolsCapability]](../models/toolscapability.md) | :heavy_minus_sign: | N/A | +| `completions` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `tasks` | [OptionalNullable[models.ServerTasksCapability]](../models/servertaskscapability.md) | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/turbinetoollocale.md b/docs/models/serverlocale.md similarity index 97% rename from docs/models/turbinetoollocale.md rename to docs/models/serverlocale.md index 283dd339..a26fcf11 100644 --- a/docs/models/turbinetoollocale.md +++ b/docs/models/serverlocale.md @@ -1,4 +1,4 @@ -# TurbineToolLocale +# ServerLocale ## Fields diff --git a/docs/models/servertaskscapability.md b/docs/models/servertaskscapability.md new file mode 100644 index 00000000..9554996d --- /dev/null +++ b/docs/models/servertaskscapability.md @@ -0,0 +1,13 @@ +# ServerTasksCapability + +Capability for server tasks operations. + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | +| `list` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `cancel` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `requests` | [OptionalNullable[models.ServerTasksRequestsCapability]](../models/servertasksrequestscapability.md) | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/servertasksrequestscapability.md b/docs/models/servertasksrequestscapability.md new file mode 100644 index 00000000..65c8593c --- /dev/null +++ b/docs/models/servertasksrequestscapability.md @@ -0,0 +1,11 @@ +# ServerTasksRequestsCapability + +Capability for tasks requests operations. + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | +| `tools` | [OptionalNullable[models.TasksToolsCapability]](../models/taskstoolscapability.md) | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/sharing.md b/docs/models/sharing.md index fc718632..922506d3 100644 --- a/docs/models/sharing.md +++ b/docs/models/sharing.md @@ -3,11 +3,11 @@ ## Fields -| Field | Type | Required | Description | -| ----------------------- | ----------------------- | ----------------------- | ----------------------- | -| `library_id` | *str* | :heavy_check_mark: | N/A | -| `user_id` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `org_id` | *str* | :heavy_check_mark: | N/A | -| `role` | *str* | :heavy_check_mark: | N/A | -| `share_with_type` | *str* | :heavy_check_mark: | N/A | -| `share_with_uuid` | *Nullable[str]* | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | +| `library_id` | *str* | :heavy_check_mark: | N/A | +| ~~`user_id`~~ | *OptionalNullable[str]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| ~~`org_id`~~ | *str* | :heavy_check_mark: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| `role` | *str* | :heavy_check_mark: | N/A | +| `share_with_type` | *str* | :heavy_check_mark: | N/A | +| `share_with_uuid` | *Nullable[str]* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/sharingdelete.md b/docs/models/sharingdelete.md index 1dcec095..e6e0732b 100644 --- a/docs/models/sharingdelete.md +++ b/docs/models/sharingdelete.md @@ -3,8 +3,8 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -| `org_id` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `share_with_uuid` | *str* | :heavy_check_mark: | The id of the entity (user, workspace or organization) to share with | -| `share_with_type` | [models.EntityType](../models/entitytype.md) | :heavy_check_mark: | The type of entity, used to share a library. | \ No newline at end of file +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | +| ~~`org_id`~~ | *OptionalNullable[str]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| `share_with_uuid` | *str* | :heavy_check_mark: | The id of the entity (user, workspace or organization) to share with | +| `share_with_type` | [models.EntityType](../models/entitytype.md) | :heavy_check_mark: | The type of entity, used to share a library. | \ No newline at end of file diff --git a/docs/models/sharingrequest.md b/docs/models/sharingrequest.md index 21b8ec1f..e92318f8 100644 --- a/docs/models/sharingrequest.md +++ b/docs/models/sharingrequest.md @@ -3,9 +3,9 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -| `org_id` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `level` | [models.ShareEnum](../models/shareenum.md) | :heavy_check_mark: | N/A | -| `share_with_uuid` | *str* | :heavy_check_mark: | The id of the entity (user, workspace or organization) to share with | -| `share_with_type` | [models.EntityType](../models/entitytype.md) | :heavy_check_mark: | The type of entity, used to share a library. | \ No newline at end of file +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | +| ~~`org_id`~~ | *OptionalNullable[str]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| `level` | [models.ShareEnum](../models/shareenum.md) | :heavy_check_mark: | N/A | +| `share_with_uuid` | *str* | :heavy_check_mark: | The id of the entity (user, workspace or organization) to share with | +| `share_with_type` | [models.EntityType](../models/entitytype.md) | :heavy_check_mark: | The type of entity, used to share a library. | \ No newline at end of file diff --git a/docs/models/skipconfirmation.md b/docs/models/skipconfirmation.md new file mode 100644 index 00000000..48eade7a --- /dev/null +++ b/docs/models/skipconfirmation.md @@ -0,0 +1,23 @@ +# SkipConfirmation + + +## Supported Types + +### `List[str]` + +```python +value: List[str] = /* values here */ +``` + +### `models.LogicalExpression` + +```python +value: models.LogicalExpression = /* values here */ +``` + +### `models.ToolProperties` + +```python +value: models.ToolProperties = /* values here */ +``` + diff --git a/docs/models/taskselicitationcapability.md b/docs/models/taskselicitationcapability.md new file mode 100644 index 00000000..f2f3ef81 --- /dev/null +++ b/docs/models/taskselicitationcapability.md @@ -0,0 +1,11 @@ +# TasksElicitationCapability + +Capability for tasks elicitation operations. + + +## Fields + +| Field | Type | Required | Description | +| -------------------- | -------------------- | -------------------- | -------------------- | +| `create` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/taskssamplingcapability.md b/docs/models/taskssamplingcapability.md new file mode 100644 index 00000000..805d8574 --- /dev/null +++ b/docs/models/taskssamplingcapability.md @@ -0,0 +1,11 @@ +# TasksSamplingCapability + +Capability for tasks sampling operations. + + +## Fields + +| Field | Type | Required | Description | +| -------------------- | -------------------- | -------------------- | -------------------- | +| `create_message` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/taskstoolscapability.md b/docs/models/taskstoolscapability.md new file mode 100644 index 00000000..cd60fe49 --- /dev/null +++ b/docs/models/taskstoolscapability.md @@ -0,0 +1,11 @@ +# TasksToolsCapability + +Capability for tasks tools operations. + + +## Fields + +| Field | Type | Required | Description | +| -------------------- | -------------------- | -------------------- | -------------------- | +| `call` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/toolexecutionconfiguration.md b/docs/models/toolexecutionconfiguration.md new file mode 100644 index 00000000..04981b89 --- /dev/null +++ b/docs/models/toolexecutionconfiguration.md @@ -0,0 +1,11 @@ +# ToolExecutionConfiguration + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | +| `requires_confirmation` | [OptionalNullable[models.RequiresConfirmation]](../models/requiresconfirmation.md) | :heavy_minus_sign: | N/A | +| `skip_confirmation` | [OptionalNullable[models.SkipConfirmation]](../models/skipconfirmation.md) | :heavy_minus_sign: | N/A | +| `include` | List[*str*] | :heavy_minus_sign: | N/A | +| `exclude` | List[*str*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/toolproperties.md b/docs/models/toolproperties.md new file mode 100644 index 00000000..d85fd821 --- /dev/null +++ b/docs/models/toolproperties.md @@ -0,0 +1,8 @@ +# ToolProperties + + +## Fields + +| Field | Type | Required | Description | +| ------------------ | ------------------ | ------------------ | ------------------ | +| `read_only` | *Nullable[bool]* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/tools.md b/docs/models/tools.md new file mode 100644 index 00000000..2f9decd6 --- /dev/null +++ b/docs/models/tools.md @@ -0,0 +1,17 @@ +# Tools + + +## Supported Types + +### `str` + +```python +value: str = /* values here */ +``` + +### `List[models.MCPToolMeta]` + +```python +value: List[models.MCPToolMeta] = /* values here */ +``` + diff --git a/docs/models/toolscapability.md b/docs/models/toolscapability.md new file mode 100644 index 00000000..7bde4735 --- /dev/null +++ b/docs/models/toolscapability.md @@ -0,0 +1,11 @@ +# ToolsCapability + +Capability for tools operations. + + +## Fields + +| Field | Type | Required | Description | +| ------------------------ | ------------------------ | ------------------------ | ------------------------ | +| `list_changed` | *OptionalNullable[bool]* | :heavy_minus_sign: | N/A | +| `__pydantic_extra__` | Dict[str, *Any*] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/turbinemeta.md b/docs/models/turbinemeta.md new file mode 100644 index 00000000..d5e48e38 --- /dev/null +++ b/docs/models/turbinemeta.md @@ -0,0 +1,9 @@ +# TurbineMeta + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | +| `system_prompt_name` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `locale` | [OptionalNullable[models.ServerLocale]](../models/serverlocale.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/updateconnectorrequest.md b/docs/models/updateconnectorrequest.md index 335588ea..7a267df3 100644 --- a/docs/models/updateconnectorrequest.md +++ b/docs/models/updateconnectorrequest.md @@ -3,15 +3,16 @@ ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -| `title` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional human-readable title for the connector. | -| `name` | *OptionalNullable[str]* | :heavy_minus_sign: | The name of the connector. | -| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | The description of the connector. | -| `icon_url` | *OptionalNullable[str]* | :heavy_minus_sign: | The optional url of the icon you want to associate to the connector. | -| `system_prompt` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional system prompt for the connector. | -| `connection_config` | Dict[str, *Any*] | :heavy_minus_sign: | Optional new connection config. | -| `connection_secrets` | Dict[str, *Any*] | :heavy_minus_sign: | Optional new connection secrets | -| `server` | *OptionalNullable[str]* | :heavy_minus_sign: | New server url for your mcp connector. | -| `headers` | Dict[str, *Any*] | :heavy_minus_sign: | New headers for your mcp connector. | -| `auth_data` | [OptionalNullable[models.AuthData]](../models/authdata.md) | :heavy_minus_sign: | New authentication data for your mcp connector. | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | +| `title` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional human-readable title for the connector. | +| `name` | *OptionalNullable[str]* | :heavy_minus_sign: | The name of the connector. | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | The description of the connector. | +| `icon_url` | *OptionalNullable[str]* | :heavy_minus_sign: | The optional url of the icon you want to associate to the connector. | +| `system_prompt` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional system prompt for the connector. | +| `protocol` | [OptionalNullable[models.ConnectorProtocol]](../models/connectorprotocol.md) | :heavy_minus_sign: | Protocol of the connector. | +| `connection_config` | Dict[str, *Any*] | :heavy_minus_sign: | Optional new connection config. | +| `connection_secrets` | Dict[str, *Any*] | :heavy_minus_sign: | Optional new connection secrets | +| `server` | *OptionalNullable[str]* | :heavy_minus_sign: | New server url for your mcp connector. | +| `headers` | Dict[str, *Any*] | :heavy_minus_sign: | New headers for your mcp connector. | +| `auth_data` | [OptionalNullable[models.AuthData]](../models/authdata.md) | :heavy_minus_sign: | New authentication data for your mcp connector. | \ No newline at end of file diff --git a/docs/models/updatedocumentrequest.md b/docs/models/updatedocumentrequest.md index dd06dd4b..5a3c93af 100644 --- a/docs/models/updatedocumentrequest.md +++ b/docs/models/updatedocumentrequest.md @@ -3,7 +3,8 @@ ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | -| `name` | *Optional[str]* | :heavy_minus_sign: | N/A | -| `attributes` | Dict[str, [models.Attributes](../models/attributes.md)] | :heavy_minus_sign: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | +| `name` | *Optional[str]* | :heavy_minus_sign: | N/A | +| `attributes` | Dict[str, [models.Attributes](../models/attributes.md)] | :heavy_minus_sign: | N/A | +| `expires_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | If set, the document will be automatically deleted after this date. | \ No newline at end of file diff --git a/docs/models/updateschedulev1workflowsschedulesscheduleidpatchrequest.md b/docs/models/updateschedulev1workflowsschedulesscheduleidpatchrequest.md new file mode 100644 index 00000000..68ffe15a --- /dev/null +++ b/docs/models/updateschedulev1workflowsschedulesscheduleidpatchrequest.md @@ -0,0 +1,9 @@ +# UpdateScheduleV1WorkflowsSchedulesScheduleIDPatchRequest + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | +| `schedule_id` | *str* | :heavy_check_mark: | N/A | +| `workflow_schedule_update_request` | [models.WorkflowScheduleUpdateRequest](../models/workflowscheduleupdaterequest.md) | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/vespaschemaresponse.md b/docs/models/vespaschemaresponse.md new file mode 100644 index 00000000..1cb7277b --- /dev/null +++ b/docs/models/vespaschemaresponse.md @@ -0,0 +1,9 @@ +# VespaSchemaResponse + + +## Fields + +| Field | Type | Required | Description | +| ------------------ | ------------------ | ------------------ | ------------------ | +| `name` | *str* | :heavy_check_mark: | N/A | +| `document_count` | *Nullable[int]* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/vespasearchindexinforesponse.md b/docs/models/vespasearchindexinforesponse.md new file mode 100644 index 00000000..16272fce --- /dev/null +++ b/docs/models/vespasearchindexinforesponse.md @@ -0,0 +1,12 @@ +# VespaSearchIndexInfoResponse + + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | +| `type` | *Literal["vespa"]* | :heavy_check_mark: | N/A | +| `k8s_cluster` | *str* | :heavy_check_mark: | N/A | +| `k8s_namespace` | *str* | :heavy_check_mark: | N/A | +| `vespa_instance_name` | *str* | :heavy_check_mark: | N/A | +| `schemas` | List[[models.VespaSchemaResponse](../models/vespaschemaresponse.md)] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/voiceappearance.md b/docs/models/voiceappearance.md new file mode 100644 index 00000000..b77de4c8 --- /dev/null +++ b/docs/models/voiceappearance.md @@ -0,0 +1,11 @@ +# VoiceAppearance + + +## Fields + +| Field | Type | Required | Description | +| ----------------------- | ----------------------- | ----------------------- | ----------------------- | +| `skin_color` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `hair_color` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `background_color` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `avatar_id` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/voicecreaterequest.md b/docs/models/voicecreaterequest.md index e9a3b3a1..775da22b 100644 --- a/docs/models/voicecreaterequest.md +++ b/docs/models/voicecreaterequest.md @@ -5,15 +5,17 @@ Request model for creating a new voice with base64 audio. ## Fields -| Field | Type | Required | Description | -| ----------------------------------------- | ----------------------------------------- | ----------------------------------------- | ----------------------------------------- | -| `name` | *str* | :heavy_check_mark: | N/A | -| `slug` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `languages` | List[*str*] | :heavy_minus_sign: | N/A | -| `gender` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `age` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | -| `tags` | List[*str*] | :heavy_minus_sign: | N/A | -| `color` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `retention_notice` | *Optional[int]* | :heavy_minus_sign: | N/A | -| `sample_audio` | *str* | :heavy_check_mark: | Base64-encoded audio file | -| `sample_filename` | *OptionalNullable[str]* | :heavy_minus_sign: | Original filename for extension detection | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | +| `name` | *str* | :heavy_check_mark: | N/A | +| `slug` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `languages` | List[*str*] | :heavy_minus_sign: | N/A | +| `gender` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `age` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | +| `tags` | List[*str*] | :heavy_minus_sign: | N/A | +| `color` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `appearance` | [OptionalNullable[models.VoiceAppearance]](../models/voiceappearance.md) | :heavy_minus_sign: | N/A | +| `retention_notice` | *Optional[int]* | :heavy_minus_sign: | N/A | +| `sample_audio` | *str* | :heavy_check_mark: | Base64-encoded audio file | +| `sample_filename` | *OptionalNullable[str]* | :heavy_minus_sign: | Original filename for extension detection | \ No newline at end of file diff --git a/docs/models/voiceresponse.md b/docs/models/voiceresponse.md index 3ec6d540..a907372e 100644 --- a/docs/models/voiceresponse.md +++ b/docs/models/voiceresponse.md @@ -5,16 +5,18 @@ Schema for voice response ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -| `name` | *str* | :heavy_check_mark: | N/A | -| `slug` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `languages` | List[*str*] | :heavy_minus_sign: | N/A | -| `gender` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `age` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | -| `tags` | List[*str*] | :heavy_minus_sign: | N/A | -| `color` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `retention_notice` | *Optional[int]* | :heavy_minus_sign: | N/A | -| `id` | *str* | :heavy_check_mark: | N/A | -| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | -| `user_id` | *Nullable[str]* | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | +| `name` | *str* | :heavy_check_mark: | N/A | +| `slug` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `languages` | List[*str*] | :heavy_minus_sign: | N/A | +| `gender` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `age` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | +| `tags` | List[*str*] | :heavy_minus_sign: | N/A | +| `color` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `appearance` | [OptionalNullable[models.VoiceAppearance]](../models/voiceappearance.md) | :heavy_minus_sign: | N/A | +| `retention_notice` | *Optional[int]* | :heavy_minus_sign: | N/A | +| `id` | *str* | :heavy_check_mark: | N/A | +| `created_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_check_mark: | N/A | +| `user_id` | *Nullable[str]* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/voiceupdaterequest.md b/docs/models/voiceupdaterequest.md index 924b5f47..ec2913dd 100644 --- a/docs/models/voiceupdaterequest.md +++ b/docs/models/voiceupdaterequest.md @@ -5,10 +5,12 @@ Request model for partially updating voice metadata. ## Fields -| Field | Type | Required | Description | -| ----------------------- | ----------------------- | ----------------------- | ----------------------- | -| `name` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `languages` | List[*str*] | :heavy_minus_sign: | N/A | -| `gender` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `age` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | -| `tags` | List[*str*] | :heavy_minus_sign: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | +| `name` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `languages` | List[*str*] | :heavy_minus_sign: | N/A | +| `gender` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `age` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | +| `tags` | List[*str*] | :heavy_minus_sign: | N/A | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `appearance` | [OptionalNullable[models.VoiceAppearance]](../models/voiceappearance.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/workflowbulkarchiverequest.md b/docs/models/workflowbulkarchiverequest.md new file mode 100644 index 00000000..2c9b9341 --- /dev/null +++ b/docs/models/workflowbulkarchiverequest.md @@ -0,0 +1,8 @@ +# WorkflowBulkArchiveRequest + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------- | ------------------------------- | ------------------------------- | ------------------------------- | +| `workflow_ids` | List[*str*] | :heavy_check_mark: | List of workflow IDs to archive | \ No newline at end of file diff --git a/docs/models/workflowbulkarchiveresponse.md b/docs/models/workflowbulkarchiveresponse.md new file mode 100644 index 00000000..ce1999f3 --- /dev/null +++ b/docs/models/workflowbulkarchiveresponse.md @@ -0,0 +1,9 @@ +# WorkflowBulkArchiveResponse + + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------- | +| `archived` | List[[models.Workflow](../models/workflow.md)] | :heavy_check_mark: | Workflows that were successfully archived or were already archived | +| `errored` | List[[models.WorkflowBulkError](../models/workflowbulkerror.md)] | :heavy_minus_sign: | Workflows that could not be archived and the corresponding error messages | \ No newline at end of file diff --git a/docs/models/workflowbulkerror.md b/docs/models/workflowbulkerror.md new file mode 100644 index 00000000..d8e34f4e --- /dev/null +++ b/docs/models/workflowbulkerror.md @@ -0,0 +1,10 @@ +# WorkflowBulkError + + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | +| `workflow_id` | *str* | :heavy_check_mark: | The requested workflow ID | +| `workflow` | [OptionalNullable[models.Workflow]](../models/workflow.md) | :heavy_minus_sign: | The workflow, if found | +| `message` | *str* | :heavy_check_mark: | Error message describing why the operation failed | \ No newline at end of file diff --git a/docs/models/workflowbulkunarchiverequest.md b/docs/models/workflowbulkunarchiverequest.md new file mode 100644 index 00000000..0e5342cf --- /dev/null +++ b/docs/models/workflowbulkunarchiverequest.md @@ -0,0 +1,8 @@ +# WorkflowBulkUnarchiveRequest + + +## Fields + +| Field | Type | Required | Description | +| --------------------------------- | --------------------------------- | --------------------------------- | --------------------------------- | +| `workflow_ids` | List[*str*] | :heavy_check_mark: | List of workflow IDs to unarchive | \ No newline at end of file diff --git a/docs/models/workflowbulkunarchiveresponse.md b/docs/models/workflowbulkunarchiveresponse.md new file mode 100644 index 00000000..8b139b75 --- /dev/null +++ b/docs/models/workflowbulkunarchiveresponse.md @@ -0,0 +1,9 @@ +# WorkflowBulkUnarchiveResponse + + +## Fields + +| Field | Type | Required | Description | +| --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | +| `unarchived` | List[[models.Workflow](../models/workflow.md)] | :heavy_check_mark: | Workflows that were successfully unarchived or were already unarchived | +| `errored` | List[[models.WorkflowBulkError](../models/workflowbulkerror.md)] | :heavy_minus_sign: | Workflows that could not be unarchived and the corresponding error messages | \ No newline at end of file diff --git a/docs/models/workflowschedulelistresponse.md b/docs/models/workflowschedulelistresponse.md index 7142185b..b6428546 100644 --- a/docs/models/workflowschedulelistresponse.md +++ b/docs/models/workflowschedulelistresponse.md @@ -5,4 +5,5 @@ | Field | Type | Required | Description | | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | -| `schedules` | List[[models.ScheduleDefinitionOutput](../models/scheduledefinitionoutput.md)] | :heavy_check_mark: | A list of workflow schedules | \ No newline at end of file +| `schedules` | List[[models.ScheduleDefinitionOutput](../models/scheduledefinitionoutput.md)] | :heavy_check_mark: | A list of workflow schedules | +| `next_page_token` | *OptionalNullable[str]* | :heavy_minus_sign: | Token for the next page of results | \ No newline at end of file diff --git a/docs/models/workflowscheduleupdaterequest.md b/docs/models/workflowscheduleupdaterequest.md new file mode 100644 index 00000000..24357f65 --- /dev/null +++ b/docs/models/workflowscheduleupdaterequest.md @@ -0,0 +1,8 @@ +# WorkflowScheduleUpdateRequest + + +## Fields + +| Field | Type | Required | Description | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `schedule` | [models.PartialScheduleDefinition](../models/partialscheduledefinition.md) | :heavy_check_mark: | Schedule definition for partial updates.

All fields are optional (inherited from _ScheduleRequestBase). Only explicitly-set
fields are applied during an update; unset fields preserve the existing schedule values. | \ No newline at end of file diff --git a/docs/sdks/accesses/README.md b/docs/sdks/accesses/README.md index 51a63779..3acf0566 100644 --- a/docs/sdks/accesses/README.md +++ b/docs/sdks/accesses/README.md @@ -76,14 +76,14 @@ with Mistral( ### Parameters -| Parameter | Type | Required | Description | -| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -| `library_id` | *str* | :heavy_check_mark: | N/A | -| `level` | [models.ShareEnum](../../models/shareenum.md) | :heavy_check_mark: | N/A | -| `share_with_uuid` | *str* | :heavy_check_mark: | The id of the entity (user, workspace or organization) to share with | -| `share_with_type` | [models.EntityType](../../models/entitytype.md) | :heavy_check_mark: | The type of entity, used to share a library. | -| `org_id` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `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 | +| ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | +| `library_id` | *str* | :heavy_check_mark: | N/A | +| `level` | [models.ShareEnum](../../models/shareenum.md) | :heavy_check_mark: | N/A | +| `share_with_uuid` | *str* | :heavy_check_mark: | The id of the entity (user, workspace or organization) to share with | +| `share_with_type` | [models.EntityType](../../models/entitytype.md) | :heavy_check_mark: | The type of entity, used to share a library. | +| `org_id` | *OptionalNullable[str]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | ### Response @@ -121,13 +121,13 @@ with Mistral( ### Parameters -| Parameter | Type | Required | Description | -| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -| `library_id` | *str* | :heavy_check_mark: | N/A | -| `share_with_uuid` | *str* | :heavy_check_mark: | The id of the entity (user, workspace or organization) to share with | -| `share_with_type` | [models.EntityType](../../models/entitytype.md) | :heavy_check_mark: | The type of entity, used to share a library. | -| `org_id` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `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 | +| ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | +| `library_id` | *str* | :heavy_check_mark: | N/A | +| `share_with_uuid` | *str* | :heavy_check_mark: | The id of the entity (user, workspace or organization) to share with | +| `share_with_type` | [models.EntityType](../../models/entitytype.md) | :heavy_check_mark: | The type of entity, used to share a library. | +| `org_id` | *OptionalNullable[str]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible. | +| `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/connectors/README.md b/docs/sdks/connectors/README.md index 753c1cf3..4a0d8a93 100644 --- a/docs/sdks/connectors/README.md +++ b/docs/sdks/connectors/README.md @@ -9,6 +9,12 @@ * [create](#create) - Create a new connector. * [list](#list) - List all connectors. * [get_auth_url](#get_auth_url) - Get the auth URL for a connector. +* [activate_for_organization](#activate_for_organization) - Activate a connector for an organization. +* [deactivate_for_organization](#deactivate_for_organization) - Deactivate a connector for an organization. +* [activate_for_workspace](#activate_for_workspace) - Activate a connector for a workspace. +* [deactivate_for_workspace](#deactivate_for_workspace) - Deactivate a connector for a workspace. +* [activate_for_user](#activate_for_user) - Activate a connector for the current user. +* [deactivate_for_user](#deactivate_for_user) - Deactivate a connector for the current user. * [call_tool](#call_tool) - Call Connector Tool * [list_tools](#list_tools) - List tools for a connector. * [get_authentication_methods](#get_authentication_methods) - Get authentication methods for a connector. @@ -160,6 +166,264 @@ with Mistral( | errors.HTTPValidationError | 422 | application/json | | errors.SDKError | 4XX, 5XX | \*/\* | +## activate_for_organization + +Enable a connector at the organization level so all members can use it. + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.beta.connectors.activate_for_organization(connector_id="a91bb4ec-caab-4cf2-be03-84b8343f4643") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | +| `connector_id` | *str* | :heavy_check_mark: | N/A | +| `requires_confirmation` | [OptionalNullable[models.RequiresConfirmation]](../../models/requiresconfirmation.md) | :heavy_minus_sign: | N/A | +| `skip_confirmation` | [OptionalNullable[models.SkipConfirmation]](../../models/skipconfirmation.md) | :heavy_minus_sign: | N/A | +| `include` | List[*str*] | :heavy_minus_sign: | N/A | +| `exclude` | List[*str*] | :heavy_minus_sign: | N/A | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.MessageResponse](../../models/messageresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | + +## deactivate_for_organization + +Disable a connector at the organization level. + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.beta.connectors.deactivate_for_organization(connector_id="8f4c1089-2a37-44b3-a3c4-830ca7a0e439") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `connector_id` | *str* | :heavy_check_mark: | N/A | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.MessageResponse](../../models/messageresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | + +## activate_for_workspace + +Enable a connector at the workspace level so all members of the workspace can use it. + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.beta.connectors.activate_for_workspace(connector_id="2adfa8af-3618-41a9-8980-e5ea1486e58e") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | +| `connector_id` | *str* | :heavy_check_mark: | N/A | +| `requires_confirmation` | [OptionalNullable[models.RequiresConfirmation]](../../models/requiresconfirmation.md) | :heavy_minus_sign: | N/A | +| `skip_confirmation` | [OptionalNullable[models.SkipConfirmation]](../../models/skipconfirmation.md) | :heavy_minus_sign: | N/A | +| `include` | List[*str*] | :heavy_minus_sign: | N/A | +| `exclude` | List[*str*] | :heavy_minus_sign: | N/A | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.MessageResponse](../../models/messageresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | + +## deactivate_for_workspace + +Disable a connector at the workspace level. + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.beta.connectors.deactivate_for_workspace(connector_id="15b00e98-a9e7-4582-b0fc-87d28c3dac04") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `connector_id` | *str* | :heavy_check_mark: | N/A | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.MessageResponse](../../models/messageresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | + +## activate_for_user + +Enable a connector for the calling user only. + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.beta.connectors.activate_for_user(connector_id="cd4fb4d2-de68-451f-8f2a-57fe39b33d96") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | +| `connector_id` | *str* | :heavy_check_mark: | N/A | +| `requires_confirmation` | [OptionalNullable[models.RequiresConfirmation]](../../models/requiresconfirmation.md) | :heavy_minus_sign: | N/A | +| `skip_confirmation` | [OptionalNullable[models.SkipConfirmation]](../../models/skipconfirmation.md) | :heavy_minus_sign: | N/A | +| `include` | List[*str*] | :heavy_minus_sign: | N/A | +| `exclude` | List[*str*] | :heavy_minus_sign: | N/A | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.MessageResponse](../../models/messageresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | + +## deactivate_for_user + +Disable a connector for the calling user only. + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.beta.connectors.deactivate_for_user(connector_id="99c6ed86-e6bb-40ed-b6ee-d22ba791a68f") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `connector_id` | *str* | :heavy_check_mark: | N/A | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.MessageResponse](../../models/messageresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | + ## call_tool Call a tool on an MCP connector. @@ -693,7 +957,7 @@ with Mistral( api_key=os.getenv("MISTRAL_API_KEY", ""), ) as mistral: - res = mistral.beta.connectors.get(connector_id_or_name="", fetch_customer_data=False, fetch_connection_secrets=False) + res = mistral.beta.connectors.get(connector_id_or_name="", fetch_user_data=False, fetch_customer_data=False) # Handle response print(res) @@ -705,8 +969,8 @@ with Mistral( | Parameter | Type | Required | Description | | --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | | `connector_id_or_name` | *str* | :heavy_check_mark: | N/A | +| `fetch_user_data` | *Optional[bool]* | :heavy_minus_sign: | Fetch the user-level data associated with the connector (e.g. connection credentials). | | `fetch_customer_data` | *Optional[bool]* | :heavy_minus_sign: | Fetch the customer data associated with the connector (e.g. customer secrets / config). | -| `fetch_connection_secrets` | *Optional[bool]* | :heavy_minus_sign: | Fetch the general connection secrets associated with the connector. | | `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | ### Response @@ -745,20 +1009,21 @@ with Mistral( ### Parameters -| Parameter | Type | Required | Description | -| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -| `connector_id` | *str* | :heavy_check_mark: | N/A | -| `title` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional human-readable title for the connector. | -| `name` | *OptionalNullable[str]* | :heavy_minus_sign: | The name of the connector. | -| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | The description of the connector. | -| `icon_url` | *OptionalNullable[str]* | :heavy_minus_sign: | The optional url of the icon you want to associate to the connector. | -| `system_prompt` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional system prompt for the connector. | -| `connection_config` | Dict[str, *Any*] | :heavy_minus_sign: | Optional new connection config. | -| `connection_secrets` | Dict[str, *Any*] | :heavy_minus_sign: | Optional new connection secrets | -| `server` | *OptionalNullable[str]* | :heavy_minus_sign: | New server url for your mcp connector. | -| `headers` | Dict[str, *Any*] | :heavy_minus_sign: | New headers for your mcp connector. | -| `auth_data` | [OptionalNullable[models.AuthData]](../../models/authdata.md) | :heavy_minus_sign: | New authentication data for your mcp connector. | -| `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 | +| ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | +| `connector_id` | *str* | :heavy_check_mark: | N/A | +| `title` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional human-readable title for the connector. | +| `name` | *OptionalNullable[str]* | :heavy_minus_sign: | The name of the connector. | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | The description of the connector. | +| `icon_url` | *OptionalNullable[str]* | :heavy_minus_sign: | The optional url of the icon you want to associate to the connector. | +| `system_prompt` | *OptionalNullable[str]* | :heavy_minus_sign: | Optional system prompt for the connector. | +| `protocol` | [OptionalNullable[models.ConnectorProtocol]](../../models/connectorprotocol.md) | :heavy_minus_sign: | Protocol of the connector. | +| `connection_config` | Dict[str, *Any*] | :heavy_minus_sign: | Optional new connection config. | +| `connection_secrets` | Dict[str, *Any*] | :heavy_minus_sign: | Optional new connection secrets | +| `server` | *OptionalNullable[str]* | :heavy_minus_sign: | New server url for your mcp connector. | +| `headers` | Dict[str, *Any*] | :heavy_minus_sign: | New headers for your mcp connector. | +| `auth_data` | [OptionalNullable[models.AuthData]](../../models/authdata.md) | :heavy_minus_sign: | New authentication data for your mcp connector. | +| `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/documents/README.md b/docs/sdks/documents/README.md index eabe9976..e7c70307 100644 --- a/docs/sdks/documents/README.md +++ b/docs/sdks/documents/README.md @@ -10,6 +10,7 @@ * [upload](#upload) - Upload a new document. * [get](#get) - Retrieve the metadata of a specific document. * [update](#update) - Update the metadata of a specific document. +* [~~libraries_documents_update_v1~~](#libraries_documents_update_v1) - Update the metadata of a specific document. :warning: **Deprecated** * [delete](#delete) - Delete a document. * [text_content](#text_content) - Retrieve the text content of a specific document. * [status](#status) - Retrieve the processing status of a specific document. @@ -42,16 +43,16 @@ with Mistral( ### Parameters -| Parameter | Type | Required | Description | -| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | -| `library_id` | *str* | :heavy_check_mark: | N/A | -| `search` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `page_size` | *Optional[int]* | :heavy_minus_sign: | N/A | -| `page` | *Optional[int]* | :heavy_minus_sign: | N/A | -| `filters_attributes` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `sort_by` | *Optional[str]* | :heavy_minus_sign: | N/A | -| `sort_order` | *Optional[str]* | :heavy_minus_sign: | N/A | -| `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 | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `library_id` | *str* | :heavy_check_mark: | N/A | +| `search` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `page_size` | *Optional[int]* | :heavy_minus_sign: | N/A | +| `page` | *Optional[int]* | :heavy_minus_sign: | N/A | +| `filters_attributes` | *OptionalNullable[str]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Deprecated: this parameter will be removed in a future version. | +| `sort_by` | *Optional[str]* | :heavy_minus_sign: | N/A | +| `sort_order` | *Optional[str]* | :heavy_minus_sign: | N/A | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | ### Response @@ -153,8 +154,55 @@ with Mistral( ## update +Given a library and a document in that library, update the name and/or attributes of that document. + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.beta.libraries.documents.update(library_id="2a41249e-52ca-4436-b755-25ce3a9bfb53", document_id="bc26fa54-e5d9-4269-bedf-86bed5471c7d") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | +| `library_id` | *str* | :heavy_check_mark: | N/A | +| `document_id` | *str* | :heavy_check_mark: | N/A | +| `name` | *Optional[str]* | :heavy_minus_sign: | N/A | +| `attributes` | Dict[str, [models.Attributes](../../models/attributes.md)] | :heavy_minus_sign: | N/A | +| `expires_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | If set, the document will be automatically deleted after this date. | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.Document](../../models/document.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | + +## ~~libraries_documents_update_v1~~ + Given a library and a document in that library, update the name of that document. +> :warning: **DEPRECATED**: Use the PATCH method instead. This PUT endpoint will be removed in a future version.. + ### Example Usage @@ -167,7 +215,7 @@ with Mistral( api_key=os.getenv("MISTRAL_API_KEY", ""), ) as mistral: - res = mistral.beta.libraries.documents.update(library_id="3ddd8d93-dca5-4a6d-980d-173226c35742", document_id="2a25e44c-b160-40ca-b5c2-b65fb2fcae34") + res = mistral.beta.libraries.documents.libraries_documents_update_v1(library_id="3ddd8d93-dca5-4a6d-980d-173226c35742", document_id="2a25e44c-b160-40ca-b5c2-b65fb2fcae34") # Handle response print(res) @@ -176,13 +224,14 @@ with Mistral( ### Parameters -| Parameter | Type | Required | Description | -| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | -| `library_id` | *str* | :heavy_check_mark: | N/A | -| `document_id` | *str* | :heavy_check_mark: | N/A | -| `name` | *Optional[str]* | :heavy_minus_sign: | N/A | -| `attributes` | Dict[str, [models.Attributes](../../models/attributes.md)] | :heavy_minus_sign: | N/A | -| `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 | +| -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------- | +| `library_id` | *str* | :heavy_check_mark: | N/A | +| `document_id` | *str* | :heavy_check_mark: | N/A | +| `name` | *Optional[str]* | :heavy_minus_sign: | N/A | +| `attributes` | Dict[str, [models.Attributes](../../models/attributes.md)] | :heavy_minus_sign: | N/A | +| `expires_at` | [date](https://docs.python.org/3/library/datetime.html#date-objects) | :heavy_minus_sign: | If set, the document will be automatically deleted after this date. | +| `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/libraries/README.md b/docs/sdks/libraries/README.md index d282f541..42c3323e 100644 --- a/docs/sdks/libraries/README.md +++ b/docs/sdks/libraries/README.md @@ -11,6 +11,7 @@ * [get](#get) - Detailed information about a specific Library. * [delete](#delete) - Delete a library and all of its documents. * [update](#update) - Update a library. +* [~~libraries_update_v1~~](#libraries_update_v1) - Update a library. :warning: **Deprecated** ## list @@ -37,13 +38,13 @@ with Mistral( ### Parameters -| Parameter | Type | Required | Description | -| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `page_size` | *Optional[int]* | :heavy_minus_sign: | N/A | -| `page` | *Optional[int]* | :heavy_minus_sign: | N/A | -| `search` | *OptionalNullable[str]* | :heavy_minus_sign: | Case-insensitive search on the library name. | -| `filter_owned_by_me` | *OptionalNullable[bool]* | :heavy_minus_sign: | Filter libraries by whether they were created by the current authenticated identity. Set to true for created by me, false for only libraries shared with me, or None to disable this filter. | -| `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 | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `page_size` | *Optional[int]* | :heavy_minus_sign: | N/A | +| `page` | *Optional[int]* | :heavy_minus_sign: | N/A | +| `search` | *OptionalNullable[str]* | :heavy_minus_sign: | Case-insensitive search on the library name. | +| `filter_owned_by_me` | *OptionalNullable[bool]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Deprecated: this parameter will be removed in a future version. | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | ### Response @@ -85,7 +86,7 @@ with Mistral( | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `name` | *str* | :heavy_check_mark: | N/A | | `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `chunk_size` | *OptionalNullable[int]* | :heavy_minus_sign: | The size of the chunks (in characters) to split document text into. Must be between 256 and 32768. | +| `chunk_size` | *OptionalNullable[int]* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

The size of the chunks (in characters) to split document text into. Must be between 256 and 32768. | | `owner_type` | [OptionalNullable[models.OwnerType]](../../models/ownertype.md) | :heavy_minus_sign: | Determines who owns the created library. 'User' creates a private library accessible only to its owner. 'Workspace' creates a library shared with the workspace. Defaults to 'Workspace' for API key sessions. Only API keys with the 'Private and shared connectors' connector access scope can create private, user-owned libraries. | | `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | @@ -143,7 +144,7 @@ with Mistral( ## delete -Given a library id, deletes it together with all documents that have been uploaded to that library. +Given a library id, deletes it together with all documents that have been uploaded to that library. Warning: the response will change from 200 (returning the deleted library) to 204 No Content in a future version. ### Example Usage @@ -188,6 +189,51 @@ Given a library id, you can update the name and description. ### Example Usage + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.beta.libraries.update(library_id="74a30b7a-ba52-49f7-a8a3-7157e1adf565") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `library_id` | *str* | :heavy_check_mark: | N/A | +| `name` | *Optional[str]* | :heavy_minus_sign: | N/A | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.Library](../../models/library.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | + +## ~~libraries_update_v1~~ + +Given a library id, you can update the name and description. + +> :warning: **DEPRECATED**: Use the PATCH method instead. This PUT endpoint will be removed in a future version.. + +### Example Usage + ```python from mistralai.client import Mistral @@ -198,7 +244,7 @@ with Mistral( api_key=os.getenv("MISTRAL_API_KEY", ""), ) as mistral: - res = mistral.beta.libraries.update(library_id="e01880c3-d0b5-4a29-8b1b-abdb8ce917e4") + res = mistral.beta.libraries.libraries_update_v1(library_id="e01880c3-d0b5-4a29-8b1b-abdb8ce917e4") # Handle response print(res) diff --git a/docs/sdks/schedules/README.md b/docs/sdks/schedules/README.md index 7bf59931..6b0e5f0e 100644 --- a/docs/sdks/schedules/README.md +++ b/docs/sdks/schedules/README.md @@ -6,7 +6,9 @@ * [get_schedules](#get_schedules) - Get Schedules * [schedule_workflow](#schedule_workflow) - Schedule Workflow +* [get_schedule](#get_schedule) - Get Schedule * [unschedule_workflow](#unschedule_workflow) - Unschedule Workflow +* [update_schedule](#update_schedule) - Update Schedule * [pause_schedule](#pause_schedule) - Pause Schedule * [resume_schedule](#resume_schedule) - Resume Schedule @@ -28,26 +30,34 @@ with Mistral( res = mistral.workflows.schedules.get_schedules() - # Handle response - print(res) + while res is not None: + # Handle items + + res = res.next() ``` ### 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. | +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- | +| `workflow_name` | *OptionalNullable[str]* | :heavy_minus_sign: | Filter by workflow name | +| `user_id` | *OptionalNullable[str]* | :heavy_minus_sign: | Filter by user ID. Pass 'current' to resolve to the authenticated user's ID. | +| `status` | [OptionalNullable[models.GetSchedulesV1WorkflowsSchedulesGetStatus]](../../models/getschedulesv1workflowsschedulesgetstatus.md) | :heavy_minus_sign: | Filter by schedule status: 'active' or 'paused' | +| `page_size` | *OptionalNullable[int]* | :heavy_minus_sign: | Number of items per page. Omitting this parameter fetches all results at once (deprecated — pass page_size to use pagination). | +| `next_page_token` | *OptionalNullable[str]* | :heavy_minus_sign: | Token for the next page of results | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | ### Response -**[models.WorkflowScheduleListResponse](../../models/workflowschedulelistresponse.md)** +**[models.GetSchedulesV1WorkflowsSchedulesGetResponse](../../models/getschedulesv1workflowsschedulesgetresponse.md)** ### Errors -| Error Type | Status Code | Content Type | -| --------------- | --------------- | --------------- | -| errors.SDKError | 4XX, 5XX | \*/\* | +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | ## schedule_workflow @@ -98,6 +108,47 @@ with Mistral( | errors.HTTPValidationError | 422 | application/json | | errors.SDKError | 4XX, 5XX | \*/\* | +## get_schedule + +Get Schedule + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.workflows.schedules.get_schedule(schedule_id="") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `schedule_id` | *str* | :heavy_check_mark: | N/A | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.ScheduleDefinitionOutput](../../models/scheduledefinitionoutput.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | + ## unschedule_workflow Unschedule Workflow @@ -134,6 +185,48 @@ with Mistral( | errors.HTTPValidationError | 422 | application/json | | errors.SDKError | 4XX, 5XX | \*/\* | +## update_schedule + +Update Schedule + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.workflows.schedules.update_schedule(schedule_id="", schedule={}) + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `schedule_id` | *str* | :heavy_check_mark: | N/A | +| `schedule` | [models.PartialScheduleDefinition](../../models/partialscheduledefinition.md) | :heavy_check_mark: | Schedule definition for partial updates.

All fields are optional (inherited from _ScheduleRequestBase). Only explicitly-set
fields are applied during an update; unset fields preserve the existing schedule values. | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.WorkflowScheduleResponse](../../models/workflowscheduleresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | + ## pause_schedule Pause Schedule diff --git a/docs/sdks/searchindexes/README.md b/docs/sdks/searchindexes/README.md new file mode 100644 index 00000000..471bba59 --- /dev/null +++ b/docs/sdks/searchindexes/README.md @@ -0,0 +1,97 @@ +# Beta.Rag.SearchIndexes + +## Overview + +### Available Operations + +* [list](#list) - Get Search Indexes +* [register](#register) - Register Search Index + +## list + +Get Search Indexes + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.beta.rag.search_indexes.list() + + # 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 + +**[List[models.SearchIndexResponse]](../../models/.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| --------------- | --------------- | --------------- | +| errors.SDKError | 4XX, 5XX | \*/\* | + +## register + +Register Search Index + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.beta.rag.search_indexes.register(name="", index={ + "type": "vespa", + "k8s_cluster": "", + "k8s_namespace": "", + "vespa_instance_name": "", + "schemas": [], + }, status="offline") + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| --------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------- | +| `name` | *str* | :heavy_check_mark: | N/A | +| `index` | [models.CreateSearchIndexInfoRequestIndex](../../models/createsearchindexinforequestindex.md) | :heavy_check_mark: | N/A | +| `document_count` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | +| `status` | [Optional[models.CreateSearchIndexInfoRequestStatus]](../../models/createsearchindexinforequeststatus.md) | :heavy_minus_sign: | N/A | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.SearchIndexResponse](../../models/searchindexresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/docs/sdks/voices/README.md b/docs/sdks/voices/README.md index 49b8533f..da59de37 100644 --- a/docs/sdks/voices/README.md +++ b/docs/sdks/voices/README.md @@ -79,19 +79,21 @@ with Mistral( ### Parameters -| Parameter | Type | Required | Description | -| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | -| `name` | *str* | :heavy_check_mark: | N/A | -| `sample_audio` | *str* | :heavy_check_mark: | Base64-encoded audio file | -| `slug` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `languages` | List[*str*] | :heavy_minus_sign: | N/A | -| `gender` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `age` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | -| `tags` | List[*str*] | :heavy_minus_sign: | N/A | -| `color` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `retention_notice` | *Optional[int]* | :heavy_minus_sign: | N/A | -| `sample_filename` | *OptionalNullable[str]* | :heavy_minus_sign: | Original filename for extension detection | -| `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 | +| --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | +| `name` | *str* | :heavy_check_mark: | N/A | +| `sample_audio` | *str* | :heavy_check_mark: | Base64-encoded audio file | +| `slug` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `languages` | List[*str*] | :heavy_minus_sign: | N/A | +| `gender` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `age` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | +| `tags` | List[*str*] | :heavy_minus_sign: | N/A | +| `color` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `appearance` | [OptionalNullable[models.VoiceAppearance]](../../models/voiceappearance.md) | :heavy_minus_sign: | N/A | +| `retention_notice` | *Optional[int]* | :heavy_minus_sign: | N/A | +| `sample_filename` | *OptionalNullable[str]* | :heavy_minus_sign: | Original filename for extension detection | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | ### Response @@ -170,15 +172,17 @@ with Mistral( ### Parameters -| Parameter | Type | Required | Description | -| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | -| `voice_id` | *str* | :heavy_check_mark: | N/A | -| `name` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `languages` | List[*str*] | :heavy_minus_sign: | N/A | -| `gender` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | -| `age` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | -| `tags` | List[*str*] | :heavy_minus_sign: | N/A | -| `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 | +| --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | --------------------------------------------------------------------------- | +| `voice_id` | *str* | :heavy_check_mark: | N/A | +| `name` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `languages` | List[*str*] | :heavy_minus_sign: | N/A | +| `gender` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `age` | *OptionalNullable[int]* | :heavy_minus_sign: | N/A | +| `tags` | List[*str*] | :heavy_minus_sign: | N/A | +| `description` | *OptionalNullable[str]* | :heavy_minus_sign: | N/A | +| `appearance` | [OptionalNullable[models.VoiceAppearance]](../../models/voiceappearance.md) | :heavy_minus_sign: | N/A | +| `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/workflows/README.md b/docs/sdks/workflows/README.md index 45759776..0fcb9b8b 100644 --- a/docs/sdks/workflows/README.md +++ b/docs/sdks/workflows/README.md @@ -11,6 +11,8 @@ * [get_workflow](#get_workflow) - Get Workflow * [update_workflow](#update_workflow) - Update Workflow * [get_workflow_registration](#get_workflow_registration) - Get Workflow Registration +* [bulk_archive_workflows](#bulk_archive_workflows) - Bulk Archive Workflows +* [bulk_unarchive_workflows](#bulk_unarchive_workflows) - Bulk Unarchive Workflows * [archive_workflow](#archive_workflow) - Archive Workflow * [unarchive_workflow](#unarchive_workflow) - Unarchive Workflow @@ -340,6 +342,88 @@ with Mistral( | errors.HTTPValidationError | 422 | application/json | | errors.SDKError | 4XX, 5XX | \*/\* | +## bulk_archive_workflows + +Bulk Archive Workflows + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.workflows.bulk_archive_workflows(workflow_ids=[]) + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `workflow_ids` | List[*str*] | :heavy_check_mark: | List of workflow IDs to archive | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.WorkflowBulkArchiveResponse](../../models/workflowbulkarchiveresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | + +## bulk_unarchive_workflows + +Bulk Unarchive Workflows + +### Example Usage + + +```python +from mistralai.client import Mistral +import os + + +with Mistral( + api_key=os.getenv("MISTRAL_API_KEY", ""), +) as mistral: + + res = mistral.workflows.bulk_unarchive_workflows(workflow_ids=[]) + + # Handle response + print(res) + +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------- | +| `workflow_ids` | List[*str*] | :heavy_check_mark: | List of workflow IDs to unarchive | +| `retries` | [Optional[utils.RetryConfig]](../../models/utils/retryconfig.md) | :heavy_minus_sign: | Configuration to override the default retry behavior of the client. | + +### Response + +**[models.WorkflowBulkUnarchiveResponse](../../models/workflowbulkunarchiveresponse.md)** + +### Errors + +| Error Type | Status Code | Content Type | +| -------------------------- | -------------------------- | -------------------------- | +| errors.HTTPValidationError | 422 | application/json | +| errors.SDKError | 4XX, 5XX | \*/\* | + ## archive_workflow Archive Workflow diff --git a/pyproject.toml b/pyproject.toml index 09efd36c..be262286 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "mistralai" -version = "2.4.5" +version = "2.4.7" description = "Python Client SDK for the Mistral AI API." authors = [{ name = "Mistral" }] requires-python = ">=3.10" diff --git a/src/mistralai/client/_version.py b/src/mistralai/client/_version.py index 9f9ae8c6..1a977e80 100644 --- a/src/mistralai/client/_version.py +++ b/src/mistralai/client/_version.py @@ -4,10 +4,10 @@ import importlib.metadata __title__: str = "mistralai" -__version__: str = "2.4.5" +__version__: str = "2.4.7" __openapi_doc_version__: str = "1.0.0" -__gen_version__: str = "2.879.6" -__user_agent__: str = "speakeasy-sdk/python 2.4.5 2.879.6 1.0.0 mistralai" +__gen_version__: str = "2.884.13" +__user_agent__: str = "speakeasy-sdk/python 2.4.7 2.884.13 1.0.0 mistralai" try: if __package__ is not None: diff --git a/src/mistralai/client/accesses.py b/src/mistralai/client/accesses.py index 5d859a39..90aef2e7 100644 --- a/src/mistralai/client/accesses.py +++ b/src/mistralai/client/accesses.py @@ -85,7 +85,7 @@ def list( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -178,7 +178,7 @@ async def list_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -288,7 +288,7 @@ def update_or_create( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -398,7 +398,7 @@ async def update_or_create_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -433,7 +433,7 @@ def delete( ) -> models.Sharing: r"""Delete an access level. - Given a library id, you can delete the access level of an entity. An owner cannot delete it's own access. You have to be the owner of the library to delete an acces other than yours. + Given a library id, you can delete the access level of an entity. An owner cannot delete their own access. You have to be the owner of the library to delete an access other than yours. Warning: the response will change from 200 (returning the deleted sharing) to 204 No Content in a future version. :param library_id: :param share_with_uuid: The id of the entity (user, workspace or organization) to share with @@ -505,7 +505,7 @@ def delete( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -540,7 +540,7 @@ async def delete_async( ) -> models.Sharing: r"""Delete an access level. - Given a library id, you can delete the access level of an entity. An owner cannot delete it's own access. You have to be the owner of the library to delete an acces other than yours. + Given a library id, you can delete the access level of an entity. An owner cannot delete their own access. You have to be the owner of the library to delete an access other than yours. Warning: the response will change from 200 (returning the deleted sharing) to 204 No Content in a future version. :param library_id: :param share_with_uuid: The id of the entity (user, workspace or organization) to share with @@ -612,7 +612,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/agents.py b/src/mistralai/client/agents.py index 1bcd8c54..86c31b3e 100644 --- a/src/mistralai/client/agents.py +++ b/src/mistralai/client/agents.py @@ -176,7 +176,7 @@ def complete( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -360,7 +360,7 @@ async def complete_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -546,7 +546,7 @@ def stream( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -740,7 +740,7 @@ async def stream_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) diff --git a/src/mistralai/client/basesdk.py b/src/mistralai/client/basesdk.py index 4a27eb2f..b305e63e 100644 --- a/src/mistralai/client/basesdk.py +++ b/src/mistralai/client/basesdk.py @@ -8,6 +8,7 @@ AfterErrorContext, AfterSuccessContext, BeforeRequestContext, + HookContext, ) from mistralai.client.utils import ( RetryConfig, @@ -238,10 +239,10 @@ def _build_request_with_client( def do_request( self, - hook_ctx, - request, - error_status_codes, - stream=False, + hook_ctx: HookContext, + request: httpx.Request, + is_error_status_code: Callable[[int], bool], + stream: bool = False, retry_config: Optional[Tuple[RetryConfig, List[str]]] = None, ) -> httpx.Response: client = self.sdk_configuration.client @@ -285,19 +286,6 @@ def do(): "" if stream else http_res.text, ) - if utils.match_status_codes(error_status_codes, http_res.status_code): - result, err = hooks.after_error( - AfterErrorContext(hook_ctx), http_res, None - ) - if err is not None: - logger.debug("Request Exception", exc_info=True) - raise err - if result is not None: - http_res = result - else: - logger.debug("Raising unexpected SDK error") - raise errors.SDKError("Unexpected error occurred", http_res) - return http_res if retry_config is not None: @@ -305,17 +293,27 @@ def do(): else: http_res = do() - if not utils.match_status_codes(error_status_codes, http_res.status_code): + if is_error_status_code(http_res.status_code): + result, err = hooks.after_error(AfterErrorContext(hook_ctx), http_res, None) + if err is not None: + logger.debug("Request Exception", exc_info=True) + raise err + if result is not None: + http_res = result + else: + logger.debug("Raising unexpected SDK error") + raise errors.SDKError("Unexpected error occurred", http_res) + else: http_res = hooks.after_success(AfterSuccessContext(hook_ctx), http_res) return http_res async def do_request_async( self, - hook_ctx, - request, - error_status_codes, - stream=False, + hook_ctx: HookContext, + request: httpx.Request, + is_error_status_code: Callable[[int], bool], + stream: bool = False, retry_config: Optional[Tuple[RetryConfig, List[str]]] = None, ) -> httpx.Response: client = self.sdk_configuration.async_client @@ -365,20 +363,6 @@ async def do(): "" if stream else http_res.text, ) - if utils.match_status_codes(error_status_codes, http_res.status_code): - result, err = await run_sync_in_thread( - hooks.after_error, AfterErrorContext(hook_ctx), http_res, None - ) - - if err is not None: - logger.debug("Request Exception", exc_info=True) - raise err - if result is not None: - http_res = result - else: - logger.debug("Raising unexpected SDK error") - raise errors.SDKError("Unexpected error occurred", http_res) - return http_res if retry_config is not None: @@ -388,7 +372,20 @@ async def do(): else: http_res = await do() - if not utils.match_status_codes(error_status_codes, http_res.status_code): + if is_error_status_code(http_res.status_code): + result, err = await run_sync_in_thread( + hooks.after_error, AfterErrorContext(hook_ctx), http_res, None + ) + + if err is not None: + logger.debug("Request Exception", exc_info=True) + raise err + if result is not None: + http_res = result + else: + logger.debug("Raising unexpected SDK error") + raise errors.SDKError("Unexpected error occurred", http_res) + else: http_res = await run_sync_in_thread( hooks.after_success, AfterSuccessContext(hook_ctx), http_res ) diff --git a/src/mistralai/client/batch_jobs.py b/src/mistralai/client/batch_jobs.py index 2bf50fd3..456e285b 100644 --- a/src/mistralai/client/batch_jobs.py +++ b/src/mistralai/client/batch_jobs.py @@ -108,7 +108,7 @@ def list( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -219,7 +219,7 @@ async def list_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -336,7 +336,7 @@ def create( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -453,7 +453,7 @@ async def create_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -546,7 +546,7 @@ def get( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -639,7 +639,7 @@ async def get_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -726,7 +726,7 @@ def delete( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -813,7 +813,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -900,7 +900,7 @@ def cancel( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -987,7 +987,7 @@ async def cancel_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/beta_agents.py b/src/mistralai/client/beta_agents.py index 64baf53b..3c0661b6 100644 --- a/src/mistralai/client/beta_agents.py +++ b/src/mistralai/client/beta_agents.py @@ -130,7 +130,7 @@ def create( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -268,7 +268,7 @@ async def create_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -382,7 +382,7 @@ def list( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -496,7 +496,7 @@ async def list_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -597,7 +597,7 @@ def get( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -698,7 +698,7 @@ async def get_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -848,7 +848,7 @@ def update( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -998,7 +998,7 @@ async def update_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1089,7 +1089,7 @@ def delete( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1180,7 +1180,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1276,7 +1276,7 @@ def update_version( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1372,7 +1372,7 @@ async def update_version_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1471,7 +1471,7 @@ def list_versions( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1570,7 +1570,7 @@ async def list_versions_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1666,7 +1666,7 @@ def get_version( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1762,7 +1762,7 @@ async def get_version_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1861,7 +1861,7 @@ def create_version_alias( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1960,7 +1960,7 @@ async def create_version_alias_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2053,7 +2053,7 @@ def list_version_aliases( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2146,7 +2146,7 @@ async def list_version_aliases_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2242,7 +2242,7 @@ def delete_version_alias( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2338,7 +2338,7 @@ async def delete_version_alias_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/campaigns.py b/src/mistralai/client/campaigns.py index c9f28794..460b0b5a 100644 --- a/src/mistralai/client/campaigns.py +++ b/src/mistralai/client/campaigns.py @@ -96,7 +96,7 @@ def create( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -204,7 +204,7 @@ async def create_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -303,7 +303,7 @@ def list( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -402,7 +402,7 @@ async def list_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -495,7 +495,7 @@ def fetch( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -588,7 +588,7 @@ async def fetch_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -681,7 +681,7 @@ def delete( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -774,7 +774,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -867,7 +867,7 @@ def fetch_status( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -960,7 +960,7 @@ async def fetch_status_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1059,7 +1059,7 @@ def list_events( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1160,7 +1160,7 @@ async def list_events_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/chat.py b/src/mistralai/client/chat.py index 9deff9a0..74a9221a 100644 --- a/src/mistralai/client/chat.py +++ b/src/mistralai/client/chat.py @@ -270,7 +270,7 @@ def complete( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -463,7 +463,7 @@ async def complete_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -658,7 +658,7 @@ def stream( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -861,7 +861,7 @@ async def stream_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) diff --git a/src/mistralai/client/chat_completion_events.py b/src/mistralai/client/chat_completion_events.py index af4124f0..ef737912 100644 --- a/src/mistralai/client/chat_completion_events.py +++ b/src/mistralai/client/chat_completion_events.py @@ -115,7 +115,7 @@ def search( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -230,7 +230,7 @@ async def search_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -335,7 +335,7 @@ def search_ids( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -440,7 +440,7 @@ async def search_ids_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -535,7 +535,7 @@ def fetch( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -628,7 +628,7 @@ async def fetch_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -721,7 +721,7 @@ def fetch_similar_events( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -816,7 +816,7 @@ async def fetch_similar_events_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -927,7 +927,7 @@ def judge( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1036,7 +1036,7 @@ async def judge_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/classifiers.py b/src/mistralai/client/classifiers.py index ddb2d0b1..36329ea6 100644 --- a/src/mistralai/client/classifiers.py +++ b/src/mistralai/client/classifiers.py @@ -95,7 +95,7 @@ def moderate( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -198,7 +198,7 @@ async def moderate_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -300,7 +300,7 @@ def moderate_chat( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -402,7 +402,7 @@ async def moderate_chat_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -505,7 +505,7 @@ def classify( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -608,7 +608,7 @@ async def classify_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -705,7 +705,7 @@ def classify_chat( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -802,7 +802,7 @@ async def classify_chat_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/connectors.py b/src/mistralai/client/connectors.py index 793c9f8a..dc8df3e8 100644 --- a/src/mistralai/client/connectors.py +++ b/src/mistralai/client/connectors.py @@ -116,7 +116,7 @@ def create( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -240,7 +240,7 @@ async def create_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -343,7 +343,7 @@ def list( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -446,7 +446,7 @@ async def list_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -545,7 +545,7 @@ def get_auth_url( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -644,7 +644,7 @@ async def get_auth_url_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -665,6 +665,1296 @@ async def get_auth_url_async( raise errors.SDKError("Unexpected response received", http_res) + def activate_for_organization( + self, + *, + connector_id: str, + requires_confirmation: OptionalNullable[ + Union[models.RequiresConfirmation, models.RequiresConfirmationTypedDict] + ] = UNSET, + skip_confirmation: OptionalNullable[ + Union[models.SkipConfirmation, models.SkipConfirmationTypedDict] + ] = UNSET, + include: OptionalNullable[List[str]] = UNSET, + exclude: OptionalNullable[List[str]] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.MessageResponse: + r"""Activate a connector for an organization. + + Enable a connector at the organization level so all members can use it. + + :param connector_id: + :param requires_confirmation: + :param skip_confirmation: + :param include: + :param exclude: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.ConnectorActivateForOrganizationV1Request( + connector_id=connector_id, + tool_execution_configuration=models.ToolExecutionConfiguration( + requires_confirmation=utils.get_pydantic_model( + requires_confirmation, OptionalNullable[models.RequiresConfirmation] + ), + skip_confirmation=utils.get_pydantic_model( + skip_confirmation, OptionalNullable[models.SkipConfirmation] + ), + include=include, + exclude=exclude, + ), + ) + + req = self._build_request( + method="POST", + path="/v1/connectors/{connector_id}/organization/activate", + 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, + get_serialized_body=lambda: utils.serialize_request_body( + request.tool_execution_configuration if request is not None else None, + True, + True, + "json", + OptionalNullable[models.ToolExecutionConfiguration], + ), + 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="connector_activate_for_organization_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.MessageResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def activate_for_organization_async( + self, + *, + connector_id: str, + requires_confirmation: OptionalNullable[ + Union[models.RequiresConfirmation, models.RequiresConfirmationTypedDict] + ] = UNSET, + skip_confirmation: OptionalNullable[ + Union[models.SkipConfirmation, models.SkipConfirmationTypedDict] + ] = UNSET, + include: OptionalNullable[List[str]] = UNSET, + exclude: OptionalNullable[List[str]] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.MessageResponse: + r"""Activate a connector for an organization. + + Enable a connector at the organization level so all members can use it. + + :param connector_id: + :param requires_confirmation: + :param skip_confirmation: + :param include: + :param exclude: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.ConnectorActivateForOrganizationV1Request( + connector_id=connector_id, + tool_execution_configuration=models.ToolExecutionConfiguration( + requires_confirmation=utils.get_pydantic_model( + requires_confirmation, OptionalNullable[models.RequiresConfirmation] + ), + skip_confirmation=utils.get_pydantic_model( + skip_confirmation, OptionalNullable[models.SkipConfirmation] + ), + include=include, + exclude=exclude, + ), + ) + + req = self._build_request_async( + method="POST", + path="/v1/connectors/{connector_id}/organization/activate", + 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, + get_serialized_body=lambda: utils.serialize_request_body( + request.tool_execution_configuration if request is not None else None, + True, + True, + "json", + OptionalNullable[models.ToolExecutionConfiguration], + ), + 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="connector_activate_for_organization_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.MessageResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + def deactivate_for_organization( + self, + *, + connector_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.MessageResponse: + r"""Deactivate a connector for an organization. + + Disable a connector at the organization level. + + :param connector_id: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.ConnectorDeactivateForOrganizationV1Request( + connector_id=connector_id, + ) + + req = self._build_request( + method="POST", + path="/v1/connectors/{connector_id}/organization/deactivate", + 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="connector_deactivate_for_organization_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.MessageResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def deactivate_for_organization_async( + self, + *, + connector_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.MessageResponse: + r"""Deactivate a connector for an organization. + + Disable a connector at the organization level. + + :param connector_id: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.ConnectorDeactivateForOrganizationV1Request( + connector_id=connector_id, + ) + + req = self._build_request_async( + method="POST", + path="/v1/connectors/{connector_id}/organization/deactivate", + 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="connector_deactivate_for_organization_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.MessageResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + def activate_for_workspace( + self, + *, + connector_id: str, + requires_confirmation: OptionalNullable[ + Union[models.RequiresConfirmation, models.RequiresConfirmationTypedDict] + ] = UNSET, + skip_confirmation: OptionalNullable[ + Union[models.SkipConfirmation, models.SkipConfirmationTypedDict] + ] = UNSET, + include: OptionalNullable[List[str]] = UNSET, + exclude: OptionalNullable[List[str]] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.MessageResponse: + r"""Activate a connector for a workspace. + + Enable a connector at the workspace level so all members of the workspace can use it. + + :param connector_id: + :param requires_confirmation: + :param skip_confirmation: + :param include: + :param exclude: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.ConnectorActivateForWorkspaceV1Request( + connector_id=connector_id, + tool_execution_configuration=models.ToolExecutionConfiguration( + requires_confirmation=utils.get_pydantic_model( + requires_confirmation, OptionalNullable[models.RequiresConfirmation] + ), + skip_confirmation=utils.get_pydantic_model( + skip_confirmation, OptionalNullable[models.SkipConfirmation] + ), + include=include, + exclude=exclude, + ), + ) + + req = self._build_request( + method="POST", + path="/v1/connectors/{connector_id}/workspace/activate", + 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, + get_serialized_body=lambda: utils.serialize_request_body( + request.tool_execution_configuration if request is not None else None, + True, + True, + "json", + OptionalNullable[models.ToolExecutionConfiguration], + ), + 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="connector_activate_for_workspace_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.MessageResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def activate_for_workspace_async( + self, + *, + connector_id: str, + requires_confirmation: OptionalNullable[ + Union[models.RequiresConfirmation, models.RequiresConfirmationTypedDict] + ] = UNSET, + skip_confirmation: OptionalNullable[ + Union[models.SkipConfirmation, models.SkipConfirmationTypedDict] + ] = UNSET, + include: OptionalNullable[List[str]] = UNSET, + exclude: OptionalNullable[List[str]] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.MessageResponse: + r"""Activate a connector for a workspace. + + Enable a connector at the workspace level so all members of the workspace can use it. + + :param connector_id: + :param requires_confirmation: + :param skip_confirmation: + :param include: + :param exclude: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.ConnectorActivateForWorkspaceV1Request( + connector_id=connector_id, + tool_execution_configuration=models.ToolExecutionConfiguration( + requires_confirmation=utils.get_pydantic_model( + requires_confirmation, OptionalNullable[models.RequiresConfirmation] + ), + skip_confirmation=utils.get_pydantic_model( + skip_confirmation, OptionalNullable[models.SkipConfirmation] + ), + include=include, + exclude=exclude, + ), + ) + + req = self._build_request_async( + method="POST", + path="/v1/connectors/{connector_id}/workspace/activate", + 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, + get_serialized_body=lambda: utils.serialize_request_body( + request.tool_execution_configuration if request is not None else None, + True, + True, + "json", + OptionalNullable[models.ToolExecutionConfiguration], + ), + 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="connector_activate_for_workspace_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.MessageResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + def deactivate_for_workspace( + self, + *, + connector_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.MessageResponse: + r"""Deactivate a connector for a workspace. + + Disable a connector at the workspace level. + + :param connector_id: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.ConnectorDeactivateForWorkspaceV1Request( + connector_id=connector_id, + ) + + req = self._build_request( + method="POST", + path="/v1/connectors/{connector_id}/workspace/deactivate", + 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="connector_deactivate_for_workspace_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.MessageResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def deactivate_for_workspace_async( + self, + *, + connector_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.MessageResponse: + r"""Deactivate a connector for a workspace. + + Disable a connector at the workspace level. + + :param connector_id: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.ConnectorDeactivateForWorkspaceV1Request( + connector_id=connector_id, + ) + + req = self._build_request_async( + method="POST", + path="/v1/connectors/{connector_id}/workspace/deactivate", + 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="connector_deactivate_for_workspace_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.MessageResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + def activate_for_user( + self, + *, + connector_id: str, + requires_confirmation: OptionalNullable[ + Union[models.RequiresConfirmation, models.RequiresConfirmationTypedDict] + ] = UNSET, + skip_confirmation: OptionalNullable[ + Union[models.SkipConfirmation, models.SkipConfirmationTypedDict] + ] = UNSET, + include: OptionalNullable[List[str]] = UNSET, + exclude: OptionalNullable[List[str]] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.MessageResponse: + r"""Activate a connector for the current user. + + Enable a connector for the calling user only. + + :param connector_id: + :param requires_confirmation: + :param skip_confirmation: + :param include: + :param exclude: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.ConnectorActivateForUserV1Request( + connector_id=connector_id, + tool_execution_configuration=models.ToolExecutionConfiguration( + requires_confirmation=utils.get_pydantic_model( + requires_confirmation, OptionalNullable[models.RequiresConfirmation] + ), + skip_confirmation=utils.get_pydantic_model( + skip_confirmation, OptionalNullable[models.SkipConfirmation] + ), + include=include, + exclude=exclude, + ), + ) + + req = self._build_request( + method="POST", + path="/v1/connectors/{connector_id}/user/activate", + 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, + get_serialized_body=lambda: utils.serialize_request_body( + request.tool_execution_configuration if request is not None else None, + True, + True, + "json", + OptionalNullable[models.ToolExecutionConfiguration], + ), + 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="connector_activate_for_user_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.MessageResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def activate_for_user_async( + self, + *, + connector_id: str, + requires_confirmation: OptionalNullable[ + Union[models.RequiresConfirmation, models.RequiresConfirmationTypedDict] + ] = UNSET, + skip_confirmation: OptionalNullable[ + Union[models.SkipConfirmation, models.SkipConfirmationTypedDict] + ] = UNSET, + include: OptionalNullable[List[str]] = UNSET, + exclude: OptionalNullable[List[str]] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.MessageResponse: + r"""Activate a connector for the current user. + + Enable a connector for the calling user only. + + :param connector_id: + :param requires_confirmation: + :param skip_confirmation: + :param include: + :param exclude: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.ConnectorActivateForUserV1Request( + connector_id=connector_id, + tool_execution_configuration=models.ToolExecutionConfiguration( + requires_confirmation=utils.get_pydantic_model( + requires_confirmation, OptionalNullable[models.RequiresConfirmation] + ), + skip_confirmation=utils.get_pydantic_model( + skip_confirmation, OptionalNullable[models.SkipConfirmation] + ), + include=include, + exclude=exclude, + ), + ) + + req = self._build_request_async( + method="POST", + path="/v1/connectors/{connector_id}/user/activate", + 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, + get_serialized_body=lambda: utils.serialize_request_body( + request.tool_execution_configuration if request is not None else None, + True, + True, + "json", + OptionalNullable[models.ToolExecutionConfiguration], + ), + 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="connector_activate_for_user_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.MessageResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + def deactivate_for_user( + self, + *, + connector_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.MessageResponse: + r"""Deactivate a connector for the current user. + + Disable a connector for the calling user only. + + :param connector_id: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.ConnectorDeactivateForUserV1Request( + connector_id=connector_id, + ) + + req = self._build_request( + method="POST", + path="/v1/connectors/{connector_id}/user/deactivate", + 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="connector_deactivate_for_user_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.MessageResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def deactivate_for_user_async( + self, + *, + connector_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.MessageResponse: + r"""Deactivate a connector for the current user. + + Disable a connector for the calling user only. + + :param connector_id: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.ConnectorDeactivateForUserV1Request( + connector_id=connector_id, + ) + + req = self._build_request_async( + method="POST", + path="/v1/connectors/{connector_id}/user/deactivate", + 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="connector_deactivate_for_user_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.MessageResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + def call_tool( self, *, @@ -755,7 +2045,7 @@ def call_tool( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -866,7 +2156,7 @@ async def call_tool_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -974,7 +2264,7 @@ def list_tools( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1084,7 +2374,7 @@ async def list_tools_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1179,7 +2469,7 @@ def get_authentication_methods( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1268,7 +2558,7 @@ async def get_authentication_methods_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1363,7 +2653,7 @@ def list_organization_credentials( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1462,7 +2752,7 @@ async def list_organization_credentials_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1577,7 +2867,7 @@ def create_or_update_organization_credentials( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1692,7 +2982,7 @@ async def create_or_update_organization_credentials_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1791,7 +3081,7 @@ def list_workspace_credentials( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1890,7 +3180,7 @@ async def list_workspace_credentials_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2005,7 +3295,7 @@ def create_or_update_workspace_credentials( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2120,7 +3410,7 @@ async def create_or_update_workspace_credentials_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2219,7 +3509,7 @@ def list_user_credentials( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2318,7 +3608,7 @@ async def list_user_credentials_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2433,7 +3723,7 @@ def create_or_update_user_credentials( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2548,7 +3838,7 @@ async def create_or_update_user_credentials_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2644,7 +3934,7 @@ def delete_organization_credentials( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2740,7 +4030,7 @@ async def delete_organization_credentials_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2836,7 +4126,7 @@ def delete_workspace_credentials( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2932,7 +4222,7 @@ async def delete_workspace_credentials_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -3028,7 +4318,7 @@ def delete_user_credentials( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -3124,7 +4414,7 @@ async def delete_user_credentials_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -3149,8 +4439,8 @@ def get( self, *, connector_id_or_name: str, + fetch_user_data: Optional[bool] = False, fetch_customer_data: Optional[bool] = False, - fetch_connection_secrets: Optional[bool] = False, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -3161,8 +4451,8 @@ def get( Get a connector by its ID or name. :param connector_id_or_name: + :param fetch_user_data: Fetch the user-level data associated with the connector (e.g. connection credentials). :param fetch_customer_data: Fetch the customer data associated with the connector (e.g. customer secrets / config). - :param fetch_connection_secrets: Fetch the general connection secrets associated with the connector. :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 @@ -3182,8 +4472,8 @@ def get( base_url = self._get_url(base_url, url_variables) request = models.ConnectorGetV1Request( + fetch_user_data=fetch_user_data, fetch_customer_data=fetch_customer_data, - fetch_connection_secrets=fetch_connection_secrets, connector_id_or_name=connector_id_or_name, ) @@ -3223,7 +4513,7 @@ def get( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -3248,8 +4538,8 @@ async def get_async( self, *, connector_id_or_name: str, + fetch_user_data: Optional[bool] = False, fetch_customer_data: Optional[bool] = False, - fetch_connection_secrets: Optional[bool] = False, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -3260,8 +4550,8 @@ async def get_async( Get a connector by its ID or name. :param connector_id_or_name: + :param fetch_user_data: Fetch the user-level data associated with the connector (e.g. connection credentials). :param fetch_customer_data: Fetch the customer data associated with the connector (e.g. customer secrets / config). - :param fetch_connection_secrets: Fetch the general connection secrets associated with the connector. :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 @@ -3281,8 +4571,8 @@ async def get_async( base_url = self._get_url(base_url, url_variables) request = models.ConnectorGetV1Request( + fetch_user_data=fetch_user_data, fetch_customer_data=fetch_customer_data, - fetch_connection_secrets=fetch_connection_secrets, connector_id_or_name=connector_id_or_name, ) @@ -3322,7 +4612,7 @@ async def get_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -3352,6 +4642,7 @@ def update( description: OptionalNullable[str] = UNSET, icon_url: OptionalNullable[str] = UNSET, system_prompt: OptionalNullable[str] = UNSET, + protocol: OptionalNullable[models.ConnectorProtocol] = UNSET, connection_config: OptionalNullable[Dict[str, Any]] = UNSET, connection_secrets: OptionalNullable[Dict[str, Any]] = UNSET, server: OptionalNullable[str] = UNSET, @@ -3374,6 +4665,7 @@ def update( :param description: The description of the connector. :param icon_url: The optional url of the icon you want to associate to the connector. :param system_prompt: Optional system prompt for the connector. + :param protocol: Protocol of the connector. :param connection_config: Optional new connection config. :param connection_secrets: Optional new connection secrets :param server: New server url for your mcp connector. @@ -3405,6 +4697,7 @@ def update( description=description, icon_url=icon_url, system_prompt=system_prompt, + protocol=protocol, connection_config=connection_config, connection_secrets=connection_secrets, server=server, @@ -3458,7 +4751,7 @@ def update( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -3488,6 +4781,7 @@ async def update_async( description: OptionalNullable[str] = UNSET, icon_url: OptionalNullable[str] = UNSET, system_prompt: OptionalNullable[str] = UNSET, + protocol: OptionalNullable[models.ConnectorProtocol] = UNSET, connection_config: OptionalNullable[Dict[str, Any]] = UNSET, connection_secrets: OptionalNullable[Dict[str, Any]] = UNSET, server: OptionalNullable[str] = UNSET, @@ -3510,6 +4804,7 @@ async def update_async( :param description: The description of the connector. :param icon_url: The optional url of the icon you want to associate to the connector. :param system_prompt: Optional system prompt for the connector. + :param protocol: Protocol of the connector. :param connection_config: Optional new connection config. :param connection_secrets: Optional new connection secrets :param server: New server url for your mcp connector. @@ -3541,6 +4836,7 @@ async def update_async( description=description, icon_url=icon_url, system_prompt=system_prompt, + protocol=protocol, connection_config=connection_config, connection_secrets=connection_secrets, server=server, @@ -3594,7 +4890,7 @@ async def update_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -3687,7 +4983,7 @@ def delete( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -3780,7 +5076,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/conversations.py b/src/mistralai/client/conversations.py index 0e0bca0d..33b9e0cf 100644 --- a/src/mistralai/client/conversations.py +++ b/src/mistralai/client/conversations.py @@ -505,7 +505,7 @@ def start( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -659,7 +659,7 @@ async def start_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -758,7 +758,7 @@ def list( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -859,7 +859,7 @@ async def list_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -954,7 +954,7 @@ def get( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1047,7 +1047,7 @@ async def get_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1140,7 +1140,7 @@ def delete( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1233,7 +1233,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1368,7 +1368,7 @@ def append( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1503,7 +1503,7 @@ async def append_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1596,7 +1596,7 @@ def get_history( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1689,7 +1689,7 @@ async def get_history_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1782,7 +1782,7 @@ def get_messages( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1875,7 +1875,7 @@ async def get_messages_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2020,7 +2020,7 @@ def restart( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2165,7 +2165,7 @@ async def restart_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2319,7 +2319,7 @@ def start_stream( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -2480,7 +2480,7 @@ async def start_stream_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -2622,7 +2622,7 @@ def append_stream( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -2764,7 +2764,7 @@ async def append_stream_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -2916,7 +2916,7 @@ def restart_stream( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -3068,7 +3068,7 @@ async def restart_stream_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) diff --git a/src/mistralai/client/datasets.py b/src/mistralai/client/datasets.py index 437b42fd..078bb18b 100644 --- a/src/mistralai/client/datasets.py +++ b/src/mistralai/client/datasets.py @@ -101,7 +101,7 @@ def create( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -200,7 +200,7 @@ async def create_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -299,7 +299,7 @@ def list( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -398,7 +398,7 @@ async def list_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -491,7 +491,7 @@ def fetch( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -584,7 +584,7 @@ async def fetch_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -677,7 +677,7 @@ def delete( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -770,7 +770,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -878,7 +878,7 @@ def update( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -986,7 +986,7 @@ async def update_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1087,7 +1087,7 @@ def list_records( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1188,7 +1188,7 @@ async def list_records_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1296,7 +1296,7 @@ def create_record( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1404,7 +1404,7 @@ async def create_record_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1509,7 +1509,7 @@ def import_from_campaign( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1614,7 +1614,7 @@ async def import_from_campaign_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1719,7 +1719,7 @@ def import_from_explorer( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1824,7 +1824,7 @@ async def import_from_explorer_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1929,7 +1929,7 @@ def import_from_file( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2034,7 +2034,7 @@ async def import_from_file_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2139,7 +2139,7 @@ def import_from_playground( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2244,7 +2244,7 @@ async def import_from_playground_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2349,7 +2349,7 @@ def import_from_dataset_records( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2454,7 +2454,7 @@ async def import_from_dataset_records_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2547,7 +2547,7 @@ def export_to_jsonl( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2640,7 +2640,7 @@ async def export_to_jsonl_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2736,7 +2736,7 @@ def fetch_task( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2832,7 +2832,7 @@ async def fetch_task_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2933,7 +2933,7 @@ def list_tasks( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -3036,7 +3036,7 @@ async def list_tasks_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/deployments.py b/src/mistralai/client/deployments.py index 26e9c565..086e95a2 100644 --- a/src/mistralai/client/deployments.py +++ b/src/mistralai/client/deployments.py @@ -84,7 +84,7 @@ def list_deployments( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -178,7 +178,7 @@ async def list_deployments_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -269,7 +269,7 @@ def get_deployment( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -360,7 +360,7 @@ async def get_deployment_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/documents.py b/src/mistralai/client/documents.py index 2a555d3e..a3c8b07b 100644 --- a/src/mistralai/client/documents.py +++ b/src/mistralai/client/documents.py @@ -2,12 +2,14 @@ # @generated-id: bcc17286c31c from .basesdk import BaseSDK +from datetime import datetime from mistralai.client import errors, models, utils from mistralai.client._hooks import HookContext from mistralai.client.types import OptionalNullable, UNSET from mistralai.client.utils import get_security_from_env from mistralai.client.utils.unmarshal_json_response import unmarshal_json_response from typing import Any, Dict, Mapping, Optional, Union +from typing_extensions import deprecated class Documents(BaseSDK): @@ -36,7 +38,7 @@ def list( :param search: :param page_size: :param page: - :param filters_attributes: + :param filters_attributes: Deprecated: this parameter will be removed in a future version. :param sort_by: :param sort_order: :param retries: Override the default retry configuration for this method @@ -103,7 +105,7 @@ def list( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -147,7 +149,7 @@ async def list_async( :param search: :param page_size: :param page: - :param filters_attributes: + :param filters_attributes: Deprecated: this parameter will be removed in a future version. :param sort_by: :param sort_order: :param retries: Override the default retry configuration for this method @@ -214,7 +216,7 @@ async def list_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -323,7 +325,7 @@ def upload( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -432,7 +434,7 @@ async def upload_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -528,7 +530,7 @@ def get( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -624,7 +626,7 @@ async def get_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -654,6 +656,242 @@ def update( attributes: OptionalNullable[ Union[Dict[str, models.Attributes], Dict[str, models.AttributesTypedDict]] ] = UNSET, + expires_at: OptionalNullable[datetime] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.Document: + r"""Update the metadata of a specific document. + + Given a library and a document in that library, update the name and/or attributes of that document. + + :param library_id: + :param document_id: + :param name: + :param attributes: + :param expires_at: If set, the document will be automatically deleted after this date. + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.LibrariesDocumentsPatchV1Request( + library_id=library_id, + document_id=document_id, + update_document_request=models.UpdateDocumentRequest( + name=name, + attributes=attributes, + expires_at=expires_at, + ), + ) + + req = self._build_request( + method="PATCH", + path="/v1/libraries/{library_id}/documents/{document_id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + 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, + get_serialized_body=lambda: utils.serialize_request_body( + request.update_document_request, + False, + False, + "json", + models.UpdateDocumentRequest, + ), + 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="libraries_documents_patch_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.Document, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def update_async( + self, + *, + library_id: str, + document_id: str, + name: Optional[str] = None, + attributes: OptionalNullable[ + Union[Dict[str, models.Attributes], Dict[str, models.AttributesTypedDict]] + ] = UNSET, + expires_at: OptionalNullable[datetime] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.Document: + r"""Update the metadata of a specific document. + + Given a library and a document in that library, update the name and/or attributes of that document. + + :param library_id: + :param document_id: + :param name: + :param attributes: + :param expires_at: If set, the document will be automatically deleted after this date. + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.LibrariesDocumentsPatchV1Request( + library_id=library_id, + document_id=document_id, + update_document_request=models.UpdateDocumentRequest( + name=name, + attributes=attributes, + expires_at=expires_at, + ), + ) + + req = self._build_request_async( + method="PATCH", + path="/v1/libraries/{library_id}/documents/{document_id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + 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, + get_serialized_body=lambda: utils.serialize_request_body( + request.update_document_request, + False, + False, + "json", + models.UpdateDocumentRequest, + ), + 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="libraries_documents_patch_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.Document, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + @deprecated( + "warning: ** DEPRECATED ** - Use the PATCH method instead. This PUT endpoint will be removed in a future version.." + ) + def libraries_documents_update_v1( + self, + *, + library_id: str, + document_id: str, + name: Optional[str] = None, + attributes: OptionalNullable[ + Union[Dict[str, models.Attributes], Dict[str, models.AttributesTypedDict]] + ] = UNSET, + expires_at: OptionalNullable[datetime] = UNSET, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -667,6 +905,7 @@ def update( :param document_id: :param name: :param attributes: + :param expires_at: If set, the document will be automatically deleted after this date. :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 @@ -691,6 +930,7 @@ def update( update_document_request=models.UpdateDocumentRequest( name=name, attributes=attributes, + expires_at=expires_at, ), ) @@ -737,7 +977,7 @@ def update( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -758,7 +998,10 @@ def update( raise errors.SDKError("Unexpected response received", http_res) - async def update_async( + @deprecated( + "warning: ** DEPRECATED ** - Use the PATCH method instead. This PUT endpoint will be removed in a future version.." + ) + async def libraries_documents_update_v1_async( self, *, library_id: str, @@ -767,6 +1010,7 @@ async def update_async( attributes: OptionalNullable[ Union[Dict[str, models.Attributes], Dict[str, models.AttributesTypedDict]] ] = UNSET, + expires_at: OptionalNullable[datetime] = UNSET, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -780,6 +1024,7 @@ async def update_async( :param document_id: :param name: :param attributes: + :param expires_at: If set, the document will be automatically deleted after this date. :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 @@ -804,6 +1049,7 @@ async def update_async( update_document_request=models.UpdateDocumentRequest( name=name, attributes=attributes, + expires_at=expires_at, ), ) @@ -850,7 +1096,7 @@ async def update_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -946,7 +1192,7 @@ def delete( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1042,7 +1288,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1144,7 +1390,7 @@ def text_content( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1246,7 +1492,7 @@ async def text_content_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1342,7 +1588,7 @@ def status( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1438,7 +1684,7 @@ async def status_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1534,7 +1780,7 @@ def get_signed_url( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1630,7 +1876,7 @@ async def get_signed_url_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1726,7 +1972,7 @@ def extracted_text_signed_url( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1822,7 +2068,7 @@ async def extracted_text_signed_url_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1918,7 +2164,7 @@ def reprocess( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2014,7 +2260,7 @@ async def reprocess_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/embeddings.py b/src/mistralai/client/embeddings.py index 64337b4f..17eb9a57 100644 --- a/src/mistralai/client/embeddings.py +++ b/src/mistralai/client/embeddings.py @@ -105,7 +105,7 @@ def create( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -218,7 +218,7 @@ async def create_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/events.py b/src/mistralai/client/events.py index 3a4c4722..4ebb6505 100644 --- a/src/mistralai/client/events.py +++ b/src/mistralai/client/events.py @@ -116,7 +116,7 @@ def get_stream_events( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -252,7 +252,7 @@ async def get_stream_events_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -365,7 +365,7 @@ def get_workflow_events( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -468,7 +468,7 @@ async def get_workflow_events_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/executions.py b/src/mistralai/client/executions.py index e4b9f90b..aa22f09e 100644 --- a/src/mistralai/client/executions.py +++ b/src/mistralai/client/executions.py @@ -81,7 +81,7 @@ def get_workflow_execution( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -172,7 +172,7 @@ async def get_workflow_execution_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -266,7 +266,7 @@ def get_workflow_execution_history( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -360,7 +360,7 @@ async def get_workflow_execution_history_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -473,7 +473,7 @@ def signal_workflow_execution( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -586,7 +586,7 @@ async def signal_workflow_execution_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -699,7 +699,7 @@ def query_workflow_execution( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -812,7 +812,7 @@ async def query_workflow_execution_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -903,7 +903,7 @@ def terminate_workflow_execution( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -994,7 +994,7 @@ async def terminate_workflow_execution_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1088,7 +1088,7 @@ def batch_terminate_workflow_executions( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1182,7 +1182,7 @@ async def batch_terminate_workflow_executions_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1273,7 +1273,7 @@ def cancel_workflow_execution( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1364,7 +1364,7 @@ async def cancel_workflow_execution_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1458,7 +1458,7 @@ def batch_cancel_workflow_executions( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1552,7 +1552,7 @@ async def batch_cancel_workflow_executions_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1664,7 +1664,7 @@ def reset_workflow( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1776,7 +1776,7 @@ async def reset_workflow_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1889,7 +1889,7 @@ def update_workflow_execution( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2002,7 +2002,7 @@ async def update_workflow_execution_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2093,7 +2093,7 @@ def get_workflow_execution_trace_otel( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2186,7 +2186,7 @@ async def get_workflow_execution_trace_otel_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2279,7 +2279,7 @@ def get_workflow_execution_trace_summary( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2372,7 +2372,7 @@ async def get_workflow_execution_trace_summary_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2471,7 +2471,7 @@ def get_workflow_execution_trace_events( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2570,7 +2570,7 @@ async def get_workflow_execution_trace_events_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2671,7 +2671,7 @@ def stream( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -2781,7 +2781,7 @@ async def stream_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) diff --git a/src/mistralai/client/fields.py b/src/mistralai/client/fields.py index 17441ca6..5e701da9 100644 --- a/src/mistralai/client/fields.py +++ b/src/mistralai/client/fields.py @@ -74,7 +74,7 @@ def list( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -162,7 +162,7 @@ async def list_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -260,7 +260,7 @@ def fetch_options( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -358,7 +358,7 @@ async def fetch_options_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -469,7 +469,7 @@ def fetch_option_counts( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -580,7 +580,7 @@ async def fetch_option_counts_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/files.py b/src/mistralai/client/files.py index e4549c75..5f8396f5 100644 --- a/src/mistralai/client/files.py +++ b/src/mistralai/client/files.py @@ -112,7 +112,7 @@ def upload( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -225,7 +225,7 @@ async def upload_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -333,7 +333,7 @@ def list( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -441,7 +441,7 @@ async def list_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -528,7 +528,7 @@ def retrieve( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -615,7 +615,7 @@ async def retrieve_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -702,7 +702,7 @@ def delete( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -789,7 +789,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -876,7 +876,7 @@ def download( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -965,7 +965,7 @@ async def download_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -1055,7 +1055,7 @@ def get_signed_url( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1143,7 +1143,7 @@ async def get_signed_url_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/fim.py b/src/mistralai/client/fim.py index d25f79b1..d868bcff 100644 --- a/src/mistralai/client/fim.py +++ b/src/mistralai/client/fim.py @@ -126,7 +126,7 @@ def complete( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -260,7 +260,7 @@ async def complete_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -394,7 +394,7 @@ def stream( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -536,7 +536,7 @@ async def stream_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) diff --git a/src/mistralai/client/fine_tuning_jobs.py b/src/mistralai/client/fine_tuning_jobs.py index a6bf93a3..708cc537 100644 --- a/src/mistralai/client/fine_tuning_jobs.py +++ b/src/mistralai/client/fine_tuning_jobs.py @@ -113,7 +113,7 @@ def list( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -229,7 +229,7 @@ async def list_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -375,7 +375,7 @@ def create( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -523,7 +523,7 @@ async def create_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -612,7 +612,7 @@ def get( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -701,7 +701,7 @@ async def get_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -790,7 +790,7 @@ def cancel( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -879,7 +879,7 @@ async def cancel_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -968,7 +968,7 @@ def start( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1057,7 +1057,7 @@ async def start_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/ingestion_pipeline_configurations.py b/src/mistralai/client/ingestion_pipeline_configurations.py index adef39f9..dfd139ba 100644 --- a/src/mistralai/client/ingestion_pipeline_configurations.py +++ b/src/mistralai/client/ingestion_pipeline_configurations.py @@ -77,7 +77,7 @@ def list( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -159,7 +159,7 @@ async def list_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -258,7 +258,7 @@ def register( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -363,7 +363,7 @@ async def register_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -469,7 +469,7 @@ def update_run_info( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -575,7 +575,7 @@ async def update_run_info_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/judges.py b/src/mistralai/client/judges.py index 52c8899e..187eed0d 100644 --- a/src/mistralai/client/judges.py +++ b/src/mistralai/client/judges.py @@ -101,7 +101,7 @@ def create( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -214,7 +214,7 @@ async def create_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -319,7 +319,7 @@ def list( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -424,7 +424,7 @@ async def list_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -517,7 +517,7 @@ def fetch( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -610,7 +610,7 @@ async def fetch_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -703,7 +703,7 @@ def delete( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -796,7 +796,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -920,7 +920,7 @@ def update( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1044,7 +1044,7 @@ async def update_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1154,7 +1154,7 @@ def judge_conversation( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1264,7 +1264,7 @@ async def judge_conversation_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/libraries.py b/src/mistralai/client/libraries.py index 928c1ea8..3076d09c 100644 --- a/src/mistralai/client/libraries.py +++ b/src/mistralai/client/libraries.py @@ -11,6 +11,7 @@ from mistralai.client.utils import get_security_from_env from mistralai.client.utils.unmarshal_json_response import unmarshal_json_response from typing import Any, Mapping, Optional +from typing_extensions import deprecated class Libraries(BaseSDK): @@ -51,7 +52,7 @@ def list( :param page_size: :param page: :param search: Case-insensitive search on the library name. - :param filter_owned_by_me: Filter libraries by whether they were created by the current authenticated identity. Set to true for created by me, false for only libraries shared with me, or None to disable this filter. + :param filter_owned_by_me: Deprecated: this parameter will be removed in a future version. :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 @@ -113,7 +114,7 @@ def list( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -153,7 +154,7 @@ async def list_async( :param page_size: :param page: :param search: Case-insensitive search on the library name. - :param filter_owned_by_me: Filter libraries by whether they were created by the current authenticated identity. Set to true for created by me, false for only libraries shared with me, or None to disable this filter. + :param filter_owned_by_me: Deprecated: this parameter will be removed in a future version. :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 @@ -215,7 +216,7 @@ async def list_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -320,7 +321,7 @@ def create( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -425,7 +426,7 @@ async def create_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -518,7 +519,7 @@ def get( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -611,7 +612,7 @@ async def get_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -643,7 +644,7 @@ def delete( ) -> models.Library: r"""Delete a library and all of it's document. - Given a library id, deletes it together with all documents that have been uploaded to that library. + Given a library id, deletes it together with all documents that have been uploaded to that library. Warning: the response will change from 200 (returning the deleted library) to 204 No Content in a future version. :param library_id: :param retries: Override the default retry configuration for this method @@ -704,7 +705,7 @@ def delete( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -736,7 +737,7 @@ async def delete_async( ) -> models.Library: r"""Delete a library and all of it's document. - Given a library id, deletes it together with all documents that have been uploaded to that library. + Given a library id, deletes it together with all documents that have been uploaded to that library. Warning: the response will change from 200 (returning the deleted library) to 204 No Content in a future version. :param library_id: :param retries: Override the default retry configuration for this method @@ -797,7 +798,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -833,6 +834,225 @@ def update( Given a library id, you can update the name and description. + :param library_id: + :param name: + :param description: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.LibrariesPatchV1Request( + library_id=library_id, + update_library_request=models.UpdateLibraryRequest( + name=name, + description=description, + ), + ) + + req = self._build_request( + method="PATCH", + path="/v1/libraries/{library_id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + 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, + get_serialized_body=lambda: utils.serialize_request_body( + request.update_library_request, + False, + False, + "json", + models.UpdateLibraryRequest, + ), + 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="libraries_patch_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.Library, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def update_async( + self, + *, + library_id: str, + name: Optional[str] = None, + description: OptionalNullable[str] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.Library: + r"""Update a library. + + Given a library id, you can update the name and description. + + :param library_id: + :param name: + :param description: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.LibrariesPatchV1Request( + library_id=library_id, + update_library_request=models.UpdateLibraryRequest( + name=name, + description=description, + ), + ) + + req = self._build_request_async( + method="PATCH", + path="/v1/libraries/{library_id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + 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, + get_serialized_body=lambda: utils.serialize_request_body( + request.update_library_request, + False, + False, + "json", + models.UpdateLibraryRequest, + ), + 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="libraries_patch_v1", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.Library, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + @deprecated( + "warning: ** DEPRECATED ** - Use the PATCH method instead. This PUT endpoint will be removed in a future version.." + ) + def libraries_update_v1( + self, + *, + library_id: str, + name: Optional[str] = None, + description: OptionalNullable[str] = UNSET, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.Library: + r"""Update a library. + + Given a library id, you can update the name and description. + :param library_id: :param name: :param description: @@ -905,7 +1125,7 @@ def update( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -926,7 +1146,10 @@ def update( raise errors.SDKError("Unexpected response received", http_res) - async def update_async( + @deprecated( + "warning: ** DEPRECATED ** - Use the PATCH method instead. This PUT endpoint will be removed in a future version.." + ) + async def libraries_update_v1_async( self, *, library_id: str, @@ -1013,7 +1236,7 @@ async def update_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/metrics.py b/src/mistralai/client/metrics.py index 60597c40..d3814d6b 100644 --- a/src/mistralai/client/metrics.py +++ b/src/mistralai/client/metrics.py @@ -109,7 +109,7 @@ def get_workflow_metrics( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -227,7 +227,7 @@ async def get_workflow_metrics_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/models/__init__.py b/src/mistralai/client/models/__init__.py index ab36240c..6121091f 100644 --- a/src/mistralai/client/models/__init__.py +++ b/src/mistralai/client/models/__init__.py @@ -9,6 +9,13 @@ Or, OrTypedDict, ) +from .logicalexpression import ( + Expression, + ExpressionTypedDict, + LogicalExpression, + LogicalExpressionType, + LogicalExpressionTypedDict, +) from typing import Any, TYPE_CHECKING from mistralai.client.utils.dynamic_imports import lazy_getattr, lazy_dir @@ -348,6 +355,15 @@ ClassifierTrainingParameters, ClassifierTrainingParametersTypedDict, ) + from .clientcapabilities import ClientCapabilities, ClientCapabilitiesTypedDict + from .clienttaskscapability import ( + ClientTasksCapability, + ClientTasksCapabilityTypedDict, + ) + from .clienttasksrequestscapability import ( + ClientTasksRequestsCapability, + ClientTasksRequestsCapabilityTypedDict, + ) from .codeinterpretertool import CodeInterpreterTool, CodeInterpreterToolTypedDict from .completionargs import CompletionArgs, CompletionArgsTypedDict from .completionargsstop import CompletionArgsStop, CompletionArgsStopTypedDict @@ -388,11 +404,28 @@ CompletionTrainingParameters, CompletionTrainingParametersTypedDict, ) + from .connectionconfigtype import ConnectionConfigType from .connectioncredentials import ( ConnectionCredentials, ConnectionCredentialsTypedDict, ) + from .connectionpreference import ( + ConnectionPreference, + ConnectionPreferenceTypedDict, + ) from .connector import Connector, ConnectorTypedDict + from .connector_activate_for_organization_v1op import ( + ConnectorActivateForOrganizationV1Request, + ConnectorActivateForOrganizationV1RequestTypedDict, + ) + from .connector_activate_for_user_v1op import ( + ConnectorActivateForUserV1Request, + ConnectorActivateForUserV1RequestTypedDict, + ) + from .connector_activate_for_workspace_v1op import ( + ConnectorActivateForWorkspaceV1Request, + ConnectorActivateForWorkspaceV1RequestTypedDict, + ) from .connector_call_tool_v1op import ( ConnectorCallToolV1Request, ConnectorCallToolV1RequestTypedDict, @@ -409,6 +442,18 @@ ConnectorCreateOrUpdateWorkspaceCredentialsV1Request, ConnectorCreateOrUpdateWorkspaceCredentialsV1RequestTypedDict, ) + from .connector_deactivate_for_organization_v1op import ( + ConnectorDeactivateForOrganizationV1Request, + ConnectorDeactivateForOrganizationV1RequestTypedDict, + ) + from .connector_deactivate_for_user_v1op import ( + ConnectorDeactivateForUserV1Request, + ConnectorDeactivateForUserV1RequestTypedDict, + ) + from .connector_deactivate_for_workspace_v1op import ( + ConnectorDeactivateForWorkspaceV1Request, + ConnectorDeactivateForWorkspaceV1RequestTypedDict, + ) from .connector_delete_organization_credentials_v1op import ( ConnectorDeleteOrganizationCredentialsV1Request, ConnectorDeleteOrganizationCredentialsV1RequestTypedDict, @@ -471,6 +516,8 @@ ConnectorCallToolRequest, ConnectorCallToolRequestTypedDict, ) + from .connectorlocale import ConnectorLocale, ConnectorLocaleTypedDict + from .connectorprotocol import ConnectorProtocol from .connectorsqueryfilters import ( ConnectorsQueryFilters, ConnectorsQueryFiltersTypedDict, @@ -492,6 +539,7 @@ ConnectorToolResultMetadata, ConnectorToolResultMetadataTypedDict, ) + from .consumertype import ConsumerType from .contentchunk import ContentChunk, ContentChunkTypedDict, UnknownContentChunk from .conversationappendrequest import ( ConversationAppendRequest, @@ -625,6 +673,21 @@ CreateLibraryRequestTypedDict, OwnerType, ) + from .createsearchindexinforequest import ( + CreateSearchIndexInfoRequest, + CreateSearchIndexInfoRequestIndex, + CreateSearchIndexInfoRequestIndexTypedDict, + CreateSearchIndexInfoRequestStatus, + CreateSearchIndexInfoRequestTypedDict, + ) + from .createvespaschemarequest import ( + CreateVespaSchemaRequest, + CreateVespaSchemaRequestTypedDict, + ) + from .createvespasearchindexinforequest import ( + CreateVespaSearchIndexInfoRequest, + CreateVespaSearchIndexInfoRequestTypedDict, + ) from .credentialscreateorupdate import ( CredentialsCreateOrUpdate, CredentialsCreateOrUpdateTypedDict, @@ -750,6 +813,10 @@ from .documentlibrarytool import DocumentLibraryTool, DocumentLibraryToolTypedDict from .documenttextcontent import DocumentTextContent, DocumentTextContentTypedDict from .documenturlchunk import DocumentURLChunk, DocumentURLChunkTypedDict + from .elicitationcapability import ( + ElicitationCapability, + ElicitationCapabilityTypedDict, + ) from .embeddedresource import ( EmbeddedResource, EmbeddedResourceTypedDict, @@ -770,6 +837,7 @@ ) from .encodedpayloadoptions import EncodedPayloadOptions from .encodingformat import EncodingFormat + from .encryptedpatchvalue import EncryptedPatchValue, EncryptedPatchValueTypedDict from .entitytype import EntityType from .event import Event, EventTypedDict from .eventprogressstatus import EventProgressStatus @@ -985,6 +1053,17 @@ GetRunV1WorkflowsRunsRunIDGetRequest, GetRunV1WorkflowsRunsRunIDGetRequestTypedDict, ) + from .get_schedule_v1_workflows_schedules_schedule_id_getop import ( + GetScheduleV1WorkflowsSchedulesScheduleIDGetRequest, + GetScheduleV1WorkflowsSchedulesScheduleIDGetRequestTypedDict, + ) + from .get_schedules_v1_workflows_schedules_getop import ( + GetSchedulesV1WorkflowsSchedulesGetRequest, + GetSchedulesV1WorkflowsSchedulesGetRequestTypedDict, + GetSchedulesV1WorkflowsSchedulesGetResponse, + GetSchedulesV1WorkflowsSchedulesGetResponseTypedDict, + GetSchedulesV1WorkflowsSchedulesGetStatus, + ) from .get_similar_chat_completion_events_v1_observability_chat_completion_events_event_id_similar_events_getop import ( GetSimilarChatCompletionEventsV1ObservabilityChatCompletionEventsEventIDSimilarEventsGetRequest, GetSimilarChatCompletionEventsV1ObservabilityChatCompletionEventsEventIDSimilarEventsGetRequestTypedDict, @@ -1167,7 +1246,12 @@ ) from .jsonpatch import JSONPatch, JSONPatchTypedDict, UnknownJSONPatch from .jsonpatchadd import JSONPatchAdd, JSONPatchAddTypedDict - from .jsonpatchappend import JSONPatchAppend, JSONPatchAppendTypedDict + from .jsonpatchappend import ( + JSONPatchAppend, + JSONPatchAppendTypedDict, + JSONPatchAppendValue, + JSONPatchAppendValueTypedDict, + ) from .jsonpatchpayloadresponse import ( JSONPatchPayloadResponse, JSONPatchPayloadResponseTypedDict, @@ -1258,6 +1342,10 @@ LibrariesDocumentsListV1Request, LibrariesDocumentsListV1RequestTypedDict, ) + from .libraries_documents_patch_v1op import ( + LibrariesDocumentsPatchV1Request, + LibrariesDocumentsPatchV1RequestTypedDict, + ) from .libraries_documents_reprocess_v1op import ( LibrariesDocumentsReprocessV1Request, LibrariesDocumentsReprocessV1RequestTypedDict, @@ -1280,6 +1368,10 @@ LibrariesListV1Request, LibrariesListV1RequestTypedDict, ) + from .libraries_patch_v1op import ( + LibrariesPatchV1Request, + LibrariesPatchV1RequestTypedDict, + ) from .libraries_share_create_v1op import ( LibrariesShareCreateV1Request, LibrariesShareCreateV1RequestTypedDict, @@ -1371,10 +1463,36 @@ ListWorkflowEventResponseTypedDict, ) from .locationtype import LocationType + from .mcpprompt import MCPPrompt, MCPPromptTypedDict + from .mcpresource import MCPResource, MCPResourceTypedDict + from .mcpserverauthenticationrequirement import ( + MCPServerAuthenticationRequirement, + MCPServerAuthenticationRequirementTypedDict, + ) + from .mcpservercard import ( + MCPServerCard, + MCPServerCardTypedDict, + Prompts, + PromptsTypedDict, + Resources, + ResourcesTypedDict, + Tools, + ToolsTypedDict, + ) + from .mcpservercardmeta import MCPServerCardMeta, MCPServerCardMetaTypedDict from .mcpservericon import MCPServerIcon, MCPServerIconTypedDict + from .mcpserverremote import ( + MCPServerRemote, + MCPServerRemoteType, + MCPServerRemoteTypedDict, + ) + from .mcpserverremoteheader import ( + MCPServerRemoteHeader, + MCPServerRemoteHeaderTypedDict, + ) + from .mcpserverrepository import MCPServerRepository, MCPServerRepositoryTypedDict from .mcptool import MCPTool, MCPToolTypedDict from .mcptoolmeta import MCPToolMeta, MCPToolMetaTypedDict - from .mcpuitoolmeta import MCPUIToolMeta, MCPUIToolMetaTypedDict, Visibility from .messageentries import MessageEntries, MessageEntriesTypedDict from .messageinputcontentchunks import ( MessageInputContentChunks, @@ -1499,6 +1617,10 @@ ) from .paginationinfo import PaginationInfo, PaginationInfoTypedDict from .paginationresponse import PaginationResponse, PaginationResponseTypedDict + from .partialscheduledefinition import ( + PartialScheduleDefinition, + PartialScheduleDefinitionTypedDict, + ) from .pause_schedule_v1_workflows_schedules_schedule_id_pause_postop import ( PauseScheduleV1WorkflowsSchedulesScheduleIDPausePostRequest, PauseScheduleV1WorkflowsSchedulesScheduleIDPausePostRequestTypedDict, @@ -1526,11 +1648,17 @@ from .prediction import Prediction, PredictionTypedDict from .processingstatus import ProcessingStatus, ProcessingStatusTypedDict from .processstatus import ProcessStatus + from .promptargument import PromptArgument, PromptArgumentTypedDict + from .promptscapability import PromptsCapability, PromptsCapabilityTypedDict from .prompttokensdetails import PromptTokensDetails, PromptTokensDetailsTypedDict from .publicauthenticationmethod import ( PublicAuthenticationMethod, PublicAuthenticationMethodTypedDict, ) + from .publicconnectionconfig import ( + PublicConnectionConfig, + PublicConnectionConfigTypedDict, + ) from .query_workflow_execution_v1_workflows_executions_execution_id_queries_postop import ( QueryWorkflowExecutionV1WorkflowsExecutionsExecutionIDQueriesPostRequest, QueryWorkflowExecutionV1WorkflowsExecutionsExecutionIDQueriesPostRequestTypedDict, @@ -1602,6 +1730,8 @@ ) from .resetinvocationbody import ResetInvocationBody, ResetInvocationBodyTypedDict from .resourcelink import ResourceLink, ResourceLinkTypedDict + from .resourcescapability import ResourcesCapability, ResourcesCapabilityTypedDict + from .resourcetype import ResourceType from .resourcevisibility import ResourceVisibility from .responsedoneevent import ResponseDoneEvent, ResponseDoneEventTypedDict from .responseerrorevent import ResponseErrorEvent, ResponseErrorEventTypedDict @@ -1623,7 +1753,9 @@ UnknownResponseRetrieveModelV1ModelsModelIDGet, ) from .roles import Roles + from .rootscapability import RootsCapability, RootsCapabilityTypedDict from .sampletype import SampleType + from .samplingcapability import SamplingCapability, SamplingCapabilityTypedDict from .scalarmetric import ( ScalarMetric, ScalarMetricTypedDict, @@ -1664,7 +1796,25 @@ SearchChatCompletionEventsResponse, SearchChatCompletionEventsResponseTypedDict, ) + from .searchindexresponse import ( + SearchIndexResponse, + SearchIndexResponseIndex, + SearchIndexResponseIndexTypedDict, + SearchIndexResponseStatus, + SearchIndexResponseTypedDict, + UnknownSearchIndexResponseIndex, + ) from .security import Security, SecurityTypedDict + from .servercapabilities import ServerCapabilities, ServerCapabilitiesTypedDict + from .serverlocale import ServerLocale, ServerLocaleTypedDict + from .servertaskscapability import ( + ServerTasksCapability, + ServerTasksCapabilityTypedDict, + ) + from .servertasksrequestscapability import ( + ServerTasksRequestsCapability, + ServerTasksRequestsCapabilityTypedDict, + ) from .shareenum import ShareEnum from .sharing import Sharing, SharingTypedDict from .sharingdelete import SharingDelete, SharingDeleteTypedDict @@ -1733,6 +1883,18 @@ SystemMessageContentChunks, SystemMessageContentChunksTypedDict, ) + from .taskselicitationcapability import ( + TasksElicitationCapability, + TasksElicitationCapabilityTypedDict, + ) + from .taskssamplingcapability import ( + TasksSamplingCapability, + TasksSamplingCapabilityTypedDict, + ) + from .taskstoolscapability import ( + TasksToolsCapability, + TasksToolsCapabilityTypedDict, + ) from .tempogettraceresponse import ( TempoGetTraceResponse, TempoGetTraceResponseTypedDict, @@ -1806,6 +1968,14 @@ from .toolchoiceenum import ToolChoiceEnum from .toolconfiguration import ToolConfiguration, ToolConfigurationTypedDict from .toolexecution import TaskSupport, ToolExecution, ToolExecutionTypedDict + from .toolexecutionconfiguration import ( + RequiresConfirmation, + RequiresConfirmationTypedDict, + SkipConfirmation, + SkipConfirmationTypedDict, + ToolExecutionConfiguration, + ToolExecutionConfigurationTypedDict, + ) from .toolexecutiondeltaevent import ( ToolExecutionDeltaEvent, ToolExecutionDeltaEventName, @@ -1842,13 +2012,14 @@ ToolMessageContentTypedDict, ToolMessageTypedDict, ) + from .toolproperties import ToolProperties, ToolPropertiesTypedDict from .toolreferencechunk import ( ToolReferenceChunk, ToolReferenceChunkTool, ToolReferenceChunkToolTypedDict, ToolReferenceChunkTypedDict, ) - from .tooltype import ToolType + from .toolscapability import ToolsCapability, ToolsCapabilityTypedDict from .trainingfile import TrainingFile, TrainingFileTypedDict from .transcriptionresponse import ( TranscriptionResponse, @@ -1882,8 +2053,7 @@ TranscriptionStreamTextDelta, TranscriptionStreamTextDeltaTypedDict, ) - from .turbinetoollocale import TurbineToolLocale, TurbineToolLocaleTypedDict - from .turbinetoolmeta import TurbineToolMeta, TurbineToolMetaTypedDict + from .turbinemeta import TurbineMeta, TurbineMetaTypedDict from .unarchive_workflow_v1_workflows_workflow_identifier_unarchive_putop import ( UnarchiveWorkflowV1WorkflowsWorkflowIdentifierUnarchivePutRequest, UnarchiveWorkflowV1WorkflowsWorkflowIdentifierUnarchivePutRequestTypedDict, @@ -1916,6 +2086,10 @@ UpdateRunInfoV1RagIngestionPipelineConfigurationsIDRunInfoPutRequest, UpdateRunInfoV1RagIngestionPipelineConfigurationsIDRunInfoPutRequestTypedDict, ) + from .update_schedule_v1_workflows_schedules_schedule_id_patchop import ( + UpdateScheduleV1WorkflowsSchedulesScheduleIDPatchRequest, + UpdateScheduleV1WorkflowsSchedulesScheduleIDPatchRequestTypedDict, + ) from .update_voice_v1_audio_voices_voice_id_patchop import ( UpdateVoiceV1AudioVoicesVoiceIDPatchRequest, UpdateVoiceV1AudioVoicesVoiceIDPatchRequestTypedDict, @@ -1995,6 +2169,12 @@ ValidationError, ValidationErrorTypedDict, ) + from .vespaschemaresponse import VespaSchemaResponse, VespaSchemaResponseTypedDict + from .vespasearchindexinforesponse import ( + VespaSearchIndexInfoResponse, + VespaSearchIndexInfoResponseTypedDict, + ) + from .voiceappearance import VoiceAppearance, VoiceAppearanceTypedDict from .voicecreaterequest import VoiceCreateRequest, VoiceCreateRequestTypedDict from .voicelistresponse import VoiceListResponse, VoiceListResponseTypedDict from .voiceresponse import VoiceResponse, VoiceResponseTypedDict @@ -2018,6 +2198,23 @@ WorkflowBasicDefinition, WorkflowBasicDefinitionTypedDict, ) + from .workflowbulkarchiverequest import ( + WorkflowBulkArchiveRequest, + WorkflowBulkArchiveRequestTypedDict, + ) + from .workflowbulkarchiveresponse import ( + WorkflowBulkArchiveResponse, + WorkflowBulkArchiveResponseTypedDict, + ) + from .workflowbulkerror import WorkflowBulkError, WorkflowBulkErrorTypedDict + from .workflowbulkunarchiverequest import ( + WorkflowBulkUnarchiveRequest, + WorkflowBulkUnarchiveRequestTypedDict, + ) + from .workflowbulkunarchiveresponse import ( + WorkflowBulkUnarchiveResponse, + WorkflowBulkUnarchiveResponseTypedDict, + ) from .workflowcodedefinition import ( WorkflowCodeDefinition, WorkflowCodeDefinitionTypedDict, @@ -2153,6 +2350,10 @@ WorkflowScheduleResponse, WorkflowScheduleResponseTypedDict, ) + from .workflowscheduleupdaterequest import ( + WorkflowScheduleUpdateRequest, + WorkflowScheduleUpdateRequestTypedDict, + ) from .workflowtaskfailedattributes import ( WorkflowTaskFailedAttributes, WorkflowTaskFailedAttributesTypedDict, @@ -2187,6 +2388,7 @@ WorkflowWithWorkerStatusTypedDict, ) # Pydantic models with forward references FilterGroup.model_rebuild() +LogicalExpression.model_rebuild() __all__ = [ @@ -2424,6 +2626,12 @@ "ClassifierTargetTypedDict", "ClassifierTrainingParameters", "ClassifierTrainingParametersTypedDict", + "ClientCapabilities", + "ClientCapabilitiesTypedDict", + "ClientTasksCapability", + "ClientTasksCapabilityTypedDict", + "ClientTasksRequestsCapability", + "ClientTasksRequestsCapabilityTypedDict", "CodeInterpreterTool", "CodeInterpreterToolTypedDict", "CompletionArgs", @@ -2457,9 +2665,18 @@ "CompletionTrainingParametersTypedDict", "ConfidenceScoresGranularity", "Confirmation", + "ConnectionConfigType", "ConnectionCredentials", "ConnectionCredentialsTypedDict", + "ConnectionPreference", + "ConnectionPreferenceTypedDict", "Connector", + "ConnectorActivateForOrganizationV1Request", + "ConnectorActivateForOrganizationV1RequestTypedDict", + "ConnectorActivateForUserV1Request", + "ConnectorActivateForUserV1RequestTypedDict", + "ConnectorActivateForWorkspaceV1Request", + "ConnectorActivateForWorkspaceV1RequestTypedDict", "ConnectorAuthenticationHeader", "ConnectorAuthenticationHeaderTypedDict", "ConnectorCallToolRequest", @@ -2472,6 +2689,12 @@ "ConnectorCreateOrUpdateUserCredentialsV1RequestTypedDict", "ConnectorCreateOrUpdateWorkspaceCredentialsV1Request", "ConnectorCreateOrUpdateWorkspaceCredentialsV1RequestTypedDict", + "ConnectorDeactivateForOrganizationV1Request", + "ConnectorDeactivateForOrganizationV1RequestTypedDict", + "ConnectorDeactivateForUserV1Request", + "ConnectorDeactivateForUserV1RequestTypedDict", + "ConnectorDeactivateForWorkspaceV1Request", + "ConnectorDeactivateForWorkspaceV1RequestTypedDict", "ConnectorDeleteOrganizationCredentialsV1Request", "ConnectorDeleteOrganizationCredentialsV1RequestTypedDict", "ConnectorDeleteUserCredentialsV1Request", @@ -2496,6 +2719,9 @@ "ConnectorListV1RequestTypedDict", "ConnectorListWorkspaceCredentialsV1Request", "ConnectorListWorkspaceCredentialsV1RequestTypedDict", + "ConnectorLocale", + "ConnectorLocaleTypedDict", + "ConnectorProtocol", "ConnectorTool", "ConnectorToolCallMetadata", "ConnectorToolCallMetadataTypedDict", @@ -2513,6 +2739,7 @@ "ConnectorUpdateV1RequestTypedDict", "ConnectorsQueryFilters", "ConnectorsQueryFiltersTypedDict", + "ConsumerType", "ContentChunk", "ContentChunkTypedDict", "Context", @@ -2600,6 +2827,15 @@ "CreateJudgeRequestTypedDict", "CreateLibraryRequest", "CreateLibraryRequestTypedDict", + "CreateSearchIndexInfoRequest", + "CreateSearchIndexInfoRequestIndex", + "CreateSearchIndexInfoRequestIndexTypedDict", + "CreateSearchIndexInfoRequestStatus", + "CreateSearchIndexInfoRequestTypedDict", + "CreateVespaSchemaRequest", + "CreateVespaSchemaRequestTypedDict", + "CreateVespaSearchIndexInfoRequest", + "CreateVespaSearchIndexInfoRequestTypedDict", "CredentialsCreateOrUpdate", "CredentialsCreateOrUpdateTypedDict", "CredentialsResponse", @@ -2684,6 +2920,8 @@ "DocumentUnionTypedDict", "DocumentUpload", "DocumentUploadTypedDict", + "ElicitationCapability", + "ElicitationCapabilityTypedDict", "EmbeddedResource", "EmbeddedResourceTypedDict", "EmbeddingDtype", @@ -2697,6 +2935,8 @@ "EmbeddingResponseTypedDict", "EncodedPayloadOptions", "EncodingFormat", + "EncryptedPatchValue", + "EncryptedPatchValueTypedDict", "EntityType", "Entry", "EntryTypedDict", @@ -2715,6 +2955,8 @@ "ExportDatasetResponseTypedDict", "ExportDatasetToJsonlV1ObservabilityDatasetsDatasetIDExportsToJsonlGetRequest", "ExportDatasetToJsonlV1ObservabilityDatasetsDatasetIDExportsToJsonlGetRequestTypedDict", + "Expression", + "ExpressionTypedDict", "FIMCompletionRequest", "FIMCompletionRequestStop", "FIMCompletionRequestStopTypedDict", @@ -2833,6 +3075,13 @@ "GetRunHistoryV1WorkflowsRunsRunIDHistoryGetRequestTypedDict", "GetRunV1WorkflowsRunsRunIDGetRequest", "GetRunV1WorkflowsRunsRunIDGetRequestTypedDict", + "GetScheduleV1WorkflowsSchedulesScheduleIDGetRequest", + "GetScheduleV1WorkflowsSchedulesScheduleIDGetRequestTypedDict", + "GetSchedulesV1WorkflowsSchedulesGetRequest", + "GetSchedulesV1WorkflowsSchedulesGetRequestTypedDict", + "GetSchedulesV1WorkflowsSchedulesGetResponse", + "GetSchedulesV1WorkflowsSchedulesGetResponseTypedDict", + "GetSchedulesV1WorkflowsSchedulesGetStatus", "GetSignedURLResponse", "GetSignedURLResponseTypedDict", "GetSimilarChatCompletionEventsV1ObservabilityChatCompletionEventsEventIDSimilarEventsGetRequest", @@ -2911,6 +3160,8 @@ "JSONPatchAddTypedDict", "JSONPatchAppend", "JSONPatchAppendTypedDict", + "JSONPatchAppendValue", + "JSONPatchAppendValueTypedDict", "JSONPatchPayloadResponse", "JSONPatchPayloadResponseTypedDict", "JSONPatchPayloadValueResponse", @@ -3002,6 +3253,8 @@ "LibrariesDocumentsGetV1RequestTypedDict", "LibrariesDocumentsListV1Request", "LibrariesDocumentsListV1RequestTypedDict", + "LibrariesDocumentsPatchV1Request", + "LibrariesDocumentsPatchV1RequestTypedDict", "LibrariesDocumentsReprocessV1Request", "LibrariesDocumentsReprocessV1RequestTypedDict", "LibrariesDocumentsUpdateV1Request", @@ -3012,6 +3265,8 @@ "LibrariesGetV1RequestTypedDict", "LibrariesListV1Request", "LibrariesListV1RequestTypedDict", + "LibrariesPatchV1Request", + "LibrariesPatchV1RequestTypedDict", "LibrariesShareCreateV1Request", "LibrariesShareCreateV1RequestTypedDict", "LibrariesShareDeleteV1Request", @@ -3070,14 +3325,32 @@ "Loc", "LocTypedDict", "LocationType", + "LogicalExpression", + "LogicalExpressionType", + "LogicalExpressionTypedDict", + "MCPPrompt", + "MCPPromptTypedDict", + "MCPResource", + "MCPResourceTypedDict", + "MCPServerAuthenticationRequirement", + "MCPServerAuthenticationRequirementTypedDict", + "MCPServerCard", + "MCPServerCardMeta", + "MCPServerCardMetaTypedDict", + "MCPServerCardTypedDict", "MCPServerIcon", "MCPServerIconTypedDict", + "MCPServerRemote", + "MCPServerRemoteHeader", + "MCPServerRemoteHeaderTypedDict", + "MCPServerRemoteType", + "MCPServerRemoteTypedDict", + "MCPServerRepository", + "MCPServerRepositoryTypedDict", "MCPTool", "MCPToolMeta", "MCPToolMetaTypedDict", "MCPToolTypedDict", - "MCPUIToolMeta", - "MCPUIToolMetaTypedDict", "MessageEntries", "MessageEntriesTypedDict", "MessageInputContentChunks", @@ -3186,6 +3459,8 @@ "PaginationInfoTypedDict", "PaginationResponse", "PaginationResponseTypedDict", + "PartialScheduleDefinition", + "PartialScheduleDefinitionTypedDict", "PauseScheduleV1WorkflowsSchedulesScheduleIDPausePostRequest", "PauseScheduleV1WorkflowsSchedulesScheduleIDPausePostRequestTypedDict", "Payload", @@ -3205,10 +3480,18 @@ "ProcessStatus", "ProcessingStatus", "ProcessingStatusTypedDict", + "PromptArgument", + "PromptArgumentTypedDict", "PromptTokensDetails", "PromptTokensDetailsTypedDict", + "Prompts", + "PromptsCapability", + "PromptsCapabilityTypedDict", + "PromptsTypedDict", "PublicAuthenticationMethod", "PublicAuthenticationMethodTypedDict", + "PublicConnectionConfig", + "PublicConnectionConfigTypedDict", "QueryDefinition", "QueryDefinitionTypedDict", "QueryInvocationBody", @@ -3247,6 +3530,8 @@ "ReferenceID", "ReferenceIDTypedDict", "RequestSource", + "RequiresConfirmation", + "RequiresConfirmationTypedDict", "ResetInvocationBody", "ResetInvocationBodyTypedDict", "ResetWorkflowV1WorkflowsExecutionsExecutionIDResetPostRequest", @@ -3254,8 +3539,13 @@ "Resource", "ResourceLink", "ResourceLinkTypedDict", + "ResourceType", "ResourceTypedDict", "ResourceVisibility", + "Resources", + "ResourcesCapability", + "ResourcesCapabilityTypedDict", + "ResourcesTypedDict", "Response", "ResponseConnectorListToolsV1", "ResponseConnectorListToolsV1TypedDict", @@ -3283,8 +3573,12 @@ "RetrieveModelV1ModelsModelIDGetRequestTypedDict", "Role", "Roles", + "RootsCapability", + "RootsCapabilityTypedDict", "SSETypes", "SampleType", + "SamplingCapability", + "SamplingCapabilityTypedDict", "ScalarMetric", "ScalarMetricTypedDict", "ScalarMetricValue", @@ -3315,8 +3609,21 @@ "SearchChatCompletionEventsRequestTypedDict", "SearchChatCompletionEventsResponse", "SearchChatCompletionEventsResponseTypedDict", + "SearchIndexResponse", + "SearchIndexResponseIndex", + "SearchIndexResponseIndexTypedDict", + "SearchIndexResponseStatus", + "SearchIndexResponseTypedDict", "Security", "SecurityTypedDict", + "ServerCapabilities", + "ServerCapabilitiesTypedDict", + "ServerLocale", + "ServerLocaleTypedDict", + "ServerTasksCapability", + "ServerTasksCapabilityTypedDict", + "ServerTasksRequestsCapability", + "ServerTasksRequestsCapabilityTypedDict", "ShareEnum", "Sharing", "SharingDelete", @@ -3336,6 +3643,8 @@ "SignalWorkflowExecutionV1WorkflowsExecutionsExecutionIDSignalsPostRequestTypedDict", "SignalWorkflowResponse", "SignalWorkflowResponseTypedDict", + "SkipConfirmation", + "SkipConfirmationTypedDict", "Source", "SpeechOutputFormat", "SpeechRequest", @@ -3372,6 +3681,12 @@ "SystemMessageTypedDict", "TableFormat", "TaskSupport", + "TasksElicitationCapability", + "TasksElicitationCapabilityTypedDict", + "TasksSamplingCapability", + "TasksSamplingCapabilityTypedDict", + "TasksToolsCapability", + "TasksToolsCapabilityTypedDict", "TempoGetTraceResponse", "TempoGetTraceResponseTypedDict", "TempoTraceAttribute", @@ -3435,6 +3750,8 @@ "ToolConfiguration", "ToolConfigurationTypedDict", "ToolExecution", + "ToolExecutionConfiguration", + "ToolExecutionConfigurationTypedDict", "ToolExecutionDeltaEvent", "ToolExecutionDeltaEventName", "ToolExecutionDeltaEventNameTypedDict", @@ -3460,12 +3777,17 @@ "ToolMessageContent", "ToolMessageContentTypedDict", "ToolMessageTypedDict", + "ToolProperties", + "ToolPropertiesTypedDict", "ToolReferenceChunk", "ToolReferenceChunkTool", "ToolReferenceChunkToolTypedDict", "ToolReferenceChunkTypedDict", - "ToolType", "ToolTypedDict", + "Tools", + "ToolsCapability", + "ToolsCapabilityTypedDict", + "ToolsTypedDict", "TrainingFile", "TrainingFileTypedDict", "TranscriptionResponse", @@ -3485,10 +3807,8 @@ "TranscriptionStreamSegmentDeltaTypedDict", "TranscriptionStreamTextDelta", "TranscriptionStreamTextDeltaTypedDict", - "TurbineToolLocale", - "TurbineToolLocaleTypedDict", - "TurbineToolMeta", - "TurbineToolMetaTypedDict", + "TurbineMeta", + "TurbineMetaTypedDict", "UnarchiveModelResponse", "UnarchiveModelResponseTypedDict", "UnarchiveWorkflowV1WorkflowsWorkflowIdentifierUnarchivePutRequest", @@ -3516,6 +3836,7 @@ "UnknownPayload", "UnknownResponse", "UnknownResponseRetrieveModelV1ModelsModelIDGet", + "UnknownSearchIndexResponseIndex", "UnknownSpeechV1AudioSpeechPostData", "UnknownTranscriptionStreamEventsData", "UnscheduleWorkflowV1WorkflowsSchedulesScheduleIDDeleteRequest", @@ -3560,6 +3881,8 @@ "UpdateRunInfoTypedDict", "UpdateRunInfoV1RagIngestionPipelineConfigurationsIDRunInfoPutRequest", "UpdateRunInfoV1RagIngestionPipelineConfigurationsIDRunInfoPutRequestTypedDict", + "UpdateScheduleV1WorkflowsSchedulesScheduleIDPatchRequest", + "UpdateScheduleV1WorkflowsSchedulesScheduleIDPatchRequestTypedDict", "UpdateVoiceV1AudioVoicesVoiceIDPatchRequest", "UpdateVoiceV1AudioVoicesVoiceIDPatchRequestTypedDict", "UpdateWorkflowExecutionV1WorkflowsExecutionsExecutionIDUpdatesPostRequest", @@ -3578,7 +3901,12 @@ "UserMessageTypedDict", "ValidationError", "ValidationErrorTypedDict", - "Visibility", + "VespaSchemaResponse", + "VespaSchemaResponseTypedDict", + "VespaSearchIndexInfoResponse", + "VespaSearchIndexInfoResponseTypedDict", + "VoiceAppearance", + "VoiceAppearanceTypedDict", "VoiceCreateRequest", "VoiceCreateRequestTypedDict", "VoiceListResponse", @@ -3600,6 +3928,16 @@ "WorkflowArchiveResponseTypedDict", "WorkflowBasicDefinition", "WorkflowBasicDefinitionTypedDict", + "WorkflowBulkArchiveRequest", + "WorkflowBulkArchiveRequestTypedDict", + "WorkflowBulkArchiveResponse", + "WorkflowBulkArchiveResponseTypedDict", + "WorkflowBulkError", + "WorkflowBulkErrorTypedDict", + "WorkflowBulkUnarchiveRequest", + "WorkflowBulkUnarchiveRequestTypedDict", + "WorkflowBulkUnarchiveResponse", + "WorkflowBulkUnarchiveResponseTypedDict", "WorkflowCodeDefinition", "WorkflowCodeDefinitionTypedDict", "WorkflowEventType", @@ -3674,6 +4012,8 @@ "WorkflowScheduleRequestTypedDict", "WorkflowScheduleResponse", "WorkflowScheduleResponseTypedDict", + "WorkflowScheduleUpdateRequest", + "WorkflowScheduleUpdateRequestTypedDict", "WorkflowTaskFailedAttributes", "WorkflowTaskFailedAttributesTypedDict", "WorkflowTaskFailedResponse", @@ -3925,6 +4265,12 @@ "ClassifierTargetResultTypedDict": ".classifiertargetresult", "ClassifierTrainingParameters": ".classifiertrainingparameters", "ClassifierTrainingParametersTypedDict": ".classifiertrainingparameters", + "ClientCapabilities": ".clientcapabilities", + "ClientCapabilitiesTypedDict": ".clientcapabilities", + "ClientTasksCapability": ".clienttaskscapability", + "ClientTasksCapabilityTypedDict": ".clienttaskscapability", + "ClientTasksRequestsCapability": ".clienttasksrequestscapability", + "ClientTasksRequestsCapabilityTypedDict": ".clienttasksrequestscapability", "CodeInterpreterTool": ".codeinterpretertool", "CodeInterpreterToolTypedDict": ".codeinterpretertool", "CompletionArgs": ".completionargs", @@ -3960,10 +4306,19 @@ "CompletionResponseStreamChoiceTypedDict": ".completionresponsestreamchoice", "CompletionTrainingParameters": ".completiontrainingparameters", "CompletionTrainingParametersTypedDict": ".completiontrainingparameters", + "ConnectionConfigType": ".connectionconfigtype", "ConnectionCredentials": ".connectioncredentials", "ConnectionCredentialsTypedDict": ".connectioncredentials", + "ConnectionPreference": ".connectionpreference", + "ConnectionPreferenceTypedDict": ".connectionpreference", "Connector": ".connector", "ConnectorTypedDict": ".connector", + "ConnectorActivateForOrganizationV1Request": ".connector_activate_for_organization_v1op", + "ConnectorActivateForOrganizationV1RequestTypedDict": ".connector_activate_for_organization_v1op", + "ConnectorActivateForUserV1Request": ".connector_activate_for_user_v1op", + "ConnectorActivateForUserV1RequestTypedDict": ".connector_activate_for_user_v1op", + "ConnectorActivateForWorkspaceV1Request": ".connector_activate_for_workspace_v1op", + "ConnectorActivateForWorkspaceV1RequestTypedDict": ".connector_activate_for_workspace_v1op", "ConnectorCallToolV1Request": ".connector_call_tool_v1op", "ConnectorCallToolV1RequestTypedDict": ".connector_call_tool_v1op", "ConnectorCreateOrUpdateOrganizationCredentialsV1Request": ".connector_create_or_update_organization_credentials_v1op", @@ -3972,6 +4327,12 @@ "ConnectorCreateOrUpdateUserCredentialsV1RequestTypedDict": ".connector_create_or_update_user_credentials_v1op", "ConnectorCreateOrUpdateWorkspaceCredentialsV1Request": ".connector_create_or_update_workspace_credentials_v1op", "ConnectorCreateOrUpdateWorkspaceCredentialsV1RequestTypedDict": ".connector_create_or_update_workspace_credentials_v1op", + "ConnectorDeactivateForOrganizationV1Request": ".connector_deactivate_for_organization_v1op", + "ConnectorDeactivateForOrganizationV1RequestTypedDict": ".connector_deactivate_for_organization_v1op", + "ConnectorDeactivateForUserV1Request": ".connector_deactivate_for_user_v1op", + "ConnectorDeactivateForUserV1RequestTypedDict": ".connector_deactivate_for_user_v1op", + "ConnectorDeactivateForWorkspaceV1Request": ".connector_deactivate_for_workspace_v1op", + "ConnectorDeactivateForWorkspaceV1RequestTypedDict": ".connector_deactivate_for_workspace_v1op", "ConnectorDeleteOrganizationCredentialsV1Request": ".connector_delete_organization_credentials_v1op", "ConnectorDeleteOrganizationCredentialsV1RequestTypedDict": ".connector_delete_organization_credentials_v1op", "ConnectorDeleteUserCredentialsV1Request": ".connector_delete_user_credentials_v1op", @@ -4004,6 +4365,9 @@ "ConnectorAuthenticationHeaderTypedDict": ".connectorauthenticationheader", "ConnectorCallToolRequest": ".connectorcalltoolrequest", "ConnectorCallToolRequestTypedDict": ".connectorcalltoolrequest", + "ConnectorLocale": ".connectorlocale", + "ConnectorLocaleTypedDict": ".connectorlocale", + "ConnectorProtocol": ".connectorprotocol", "ConnectorsQueryFilters": ".connectorsqueryfilters", "ConnectorsQueryFiltersTypedDict": ".connectorsqueryfilters", "ConnectorTool": ".connectortool", @@ -4019,6 +4383,7 @@ "ConnectorToolLocaleTypedDict": ".connectortoollocale", "ConnectorToolResultMetadata": ".connectortoolresultmetadata", "ConnectorToolResultMetadataTypedDict": ".connectortoolresultmetadata", + "ConsumerType": ".consumertype", "ContentChunk": ".contentchunk", "ContentChunkTypedDict": ".contentchunk", "UnknownContentChunk": ".contentchunk", @@ -4111,6 +4476,15 @@ "CreateLibraryRequest": ".createlibraryrequest", "CreateLibraryRequestTypedDict": ".createlibraryrequest", "OwnerType": ".createlibraryrequest", + "CreateSearchIndexInfoRequest": ".createsearchindexinforequest", + "CreateSearchIndexInfoRequestIndex": ".createsearchindexinforequest", + "CreateSearchIndexInfoRequestIndexTypedDict": ".createsearchindexinforequest", + "CreateSearchIndexInfoRequestStatus": ".createsearchindexinforequest", + "CreateSearchIndexInfoRequestTypedDict": ".createsearchindexinforequest", + "CreateVespaSchemaRequest": ".createvespaschemarequest", + "CreateVespaSchemaRequestTypedDict": ".createvespaschemarequest", + "CreateVespaSearchIndexInfoRequest": ".createvespasearchindexinforequest", + "CreateVespaSearchIndexInfoRequestTypedDict": ".createvespasearchindexinforequest", "CredentialsCreateOrUpdate": ".credentialscreateorupdate", "CredentialsCreateOrUpdateTypedDict": ".credentialscreateorupdate", "CredentialsResponse": ".credentialsresponse", @@ -4197,6 +4571,8 @@ "DocumentTextContentTypedDict": ".documenttextcontent", "DocumentURLChunk": ".documenturlchunk", "DocumentURLChunkTypedDict": ".documenturlchunk", + "ElicitationCapability": ".elicitationcapability", + "ElicitationCapabilityTypedDict": ".elicitationcapability", "EmbeddedResource": ".embeddedresource", "EmbeddedResourceTypedDict": ".embeddedresource", "Resource": ".embeddedresource", @@ -4212,6 +4588,8 @@ "EmbeddingResponseDataTypedDict": ".embeddingresponsedata", "EncodedPayloadOptions": ".encodedpayloadoptions", "EncodingFormat": ".encodingformat", + "EncryptedPatchValue": ".encryptedpatchvalue", + "EncryptedPatchValueTypedDict": ".encryptedpatchvalue", "EntityType": ".entitytype", "Event": ".event", "EventTypedDict": ".event", @@ -4353,6 +4731,13 @@ "GetRunHistoryV1WorkflowsRunsRunIDHistoryGetRequestTypedDict": ".get_run_history_v1_workflows_runs_run_id_history_getop", "GetRunV1WorkflowsRunsRunIDGetRequest": ".get_run_v1_workflows_runs_run_id_getop", "GetRunV1WorkflowsRunsRunIDGetRequestTypedDict": ".get_run_v1_workflows_runs_run_id_getop", + "GetScheduleV1WorkflowsSchedulesScheduleIDGetRequest": ".get_schedule_v1_workflows_schedules_schedule_id_getop", + "GetScheduleV1WorkflowsSchedulesScheduleIDGetRequestTypedDict": ".get_schedule_v1_workflows_schedules_schedule_id_getop", + "GetSchedulesV1WorkflowsSchedulesGetRequest": ".get_schedules_v1_workflows_schedules_getop", + "GetSchedulesV1WorkflowsSchedulesGetRequestTypedDict": ".get_schedules_v1_workflows_schedules_getop", + "GetSchedulesV1WorkflowsSchedulesGetResponse": ".get_schedules_v1_workflows_schedules_getop", + "GetSchedulesV1WorkflowsSchedulesGetResponseTypedDict": ".get_schedules_v1_workflows_schedules_getop", + "GetSchedulesV1WorkflowsSchedulesGetStatus": ".get_schedules_v1_workflows_schedules_getop", "GetSimilarChatCompletionEventsV1ObservabilityChatCompletionEventsEventIDSimilarEventsGetRequest": ".get_similar_chat_completion_events_v1_observability_chat_completion_events_event_id_similar_events_getop", "GetSimilarChatCompletionEventsV1ObservabilityChatCompletionEventsEventIDSimilarEventsGetRequestTypedDict": ".get_similar_chat_completion_events_v1_observability_chat_completion_events_event_id_similar_events_getop", "GetStreamEventsV1WorkflowsEventsStreamGetRequest": ".get_stream_events_v1_workflows_events_stream_getop", @@ -4477,6 +4862,8 @@ "JSONPatchAddTypedDict": ".jsonpatchadd", "JSONPatchAppend": ".jsonpatchappend", "JSONPatchAppendTypedDict": ".jsonpatchappend", + "JSONPatchAppendValue": ".jsonpatchappend", + "JSONPatchAppendValueTypedDict": ".jsonpatchappend", "JSONPatchPayloadResponse": ".jsonpatchpayloadresponse", "JSONPatchPayloadResponseTypedDict": ".jsonpatchpayloadresponse", "JSONPatchPayloadValueResponse": ".jsonpatchpayloadvalueresponse", @@ -4535,6 +4922,8 @@ "LibrariesDocumentsGetV1RequestTypedDict": ".libraries_documents_get_v1op", "LibrariesDocumentsListV1Request": ".libraries_documents_list_v1op", "LibrariesDocumentsListV1RequestTypedDict": ".libraries_documents_list_v1op", + "LibrariesDocumentsPatchV1Request": ".libraries_documents_patch_v1op", + "LibrariesDocumentsPatchV1RequestTypedDict": ".libraries_documents_patch_v1op", "LibrariesDocumentsReprocessV1Request": ".libraries_documents_reprocess_v1op", "LibrariesDocumentsReprocessV1RequestTypedDict": ".libraries_documents_reprocess_v1op", "LibrariesDocumentsUpdateV1Request": ".libraries_documents_update_v1op", @@ -4547,6 +4936,8 @@ "LibrariesGetV1RequestTypedDict": ".libraries_get_v1op", "LibrariesListV1Request": ".libraries_list_v1op", "LibrariesListV1RequestTypedDict": ".libraries_list_v1op", + "LibrariesPatchV1Request": ".libraries_patch_v1op", + "LibrariesPatchV1RequestTypedDict": ".libraries_patch_v1op", "LibrariesShareCreateV1Request": ".libraries_share_create_v1op", "LibrariesShareCreateV1RequestTypedDict": ".libraries_share_create_v1op", "LibrariesShareDeleteV1Request": ".libraries_share_delete_v1op", @@ -4604,15 +4995,35 @@ "ListWorkflowEventResponseEventTypedDict": ".listworkfloweventresponse", "ListWorkflowEventResponseTypedDict": ".listworkfloweventresponse", "LocationType": ".locationtype", + "MCPPrompt": ".mcpprompt", + "MCPPromptTypedDict": ".mcpprompt", + "MCPResource": ".mcpresource", + "MCPResourceTypedDict": ".mcpresource", + "MCPServerAuthenticationRequirement": ".mcpserverauthenticationrequirement", + "MCPServerAuthenticationRequirementTypedDict": ".mcpserverauthenticationrequirement", + "MCPServerCard": ".mcpservercard", + "MCPServerCardTypedDict": ".mcpservercard", + "Prompts": ".mcpservercard", + "PromptsTypedDict": ".mcpservercard", + "Resources": ".mcpservercard", + "ResourcesTypedDict": ".mcpservercard", + "Tools": ".mcpservercard", + "ToolsTypedDict": ".mcpservercard", + "MCPServerCardMeta": ".mcpservercardmeta", + "MCPServerCardMetaTypedDict": ".mcpservercardmeta", "MCPServerIcon": ".mcpservericon", "MCPServerIconTypedDict": ".mcpservericon", + "MCPServerRemote": ".mcpserverremote", + "MCPServerRemoteType": ".mcpserverremote", + "MCPServerRemoteTypedDict": ".mcpserverremote", + "MCPServerRemoteHeader": ".mcpserverremoteheader", + "MCPServerRemoteHeaderTypedDict": ".mcpserverremoteheader", + "MCPServerRepository": ".mcpserverrepository", + "MCPServerRepositoryTypedDict": ".mcpserverrepository", "MCPTool": ".mcptool", "MCPToolTypedDict": ".mcptool", "MCPToolMeta": ".mcptoolmeta", "MCPToolMetaTypedDict": ".mcptoolmeta", - "MCPUIToolMeta": ".mcpuitoolmeta", - "MCPUIToolMetaTypedDict": ".mcpuitoolmeta", - "Visibility": ".mcpuitoolmeta", "MessageEntries": ".messageentries", "MessageEntriesTypedDict": ".messageentries", "MessageInputContentChunks": ".messageinputcontentchunks", @@ -4719,6 +5130,8 @@ "PaginationInfoTypedDict": ".paginationinfo", "PaginationResponse": ".paginationresponse", "PaginationResponseTypedDict": ".paginationresponse", + "PartialScheduleDefinition": ".partialscheduledefinition", + "PartialScheduleDefinitionTypedDict": ".partialscheduledefinition", "PauseScheduleV1WorkflowsSchedulesScheduleIDPausePostRequest": ".pause_schedule_v1_workflows_schedules_schedule_id_pause_postop", "PauseScheduleV1WorkflowsSchedulesScheduleIDPausePostRequestTypedDict": ".pause_schedule_v1_workflows_schedules_schedule_id_pause_postop", "PostDatasetRecordsFromCampaignV1ObservabilityDatasetsDatasetIDImportsFromCampaignPostRequest": ".post_dataset_records_from_campaign_v1_observability_datasets_dataset_id_imports_from_campaign_postop", @@ -4736,10 +5149,16 @@ "ProcessingStatus": ".processingstatus", "ProcessingStatusTypedDict": ".processingstatus", "ProcessStatus": ".processstatus", + "PromptArgument": ".promptargument", + "PromptArgumentTypedDict": ".promptargument", + "PromptsCapability": ".promptscapability", + "PromptsCapabilityTypedDict": ".promptscapability", "PromptTokensDetails": ".prompttokensdetails", "PromptTokensDetailsTypedDict": ".prompttokensdetails", "PublicAuthenticationMethod": ".publicauthenticationmethod", "PublicAuthenticationMethodTypedDict": ".publicauthenticationmethod", + "PublicConnectionConfig": ".publicconnectionconfig", + "PublicConnectionConfigTypedDict": ".publicconnectionconfig", "QueryWorkflowExecutionV1WorkflowsExecutionsExecutionIDQueriesPostRequest": ".query_workflow_execution_v1_workflows_executions_execution_id_queries_postop", "QueryWorkflowExecutionV1WorkflowsExecutionsExecutionIDQueriesPostRequestTypedDict": ".query_workflow_execution_v1_workflows_executions_execution_id_queries_postop", "QueryDefinition": ".querydefinition", @@ -4784,6 +5203,9 @@ "ResetInvocationBodyTypedDict": ".resetinvocationbody", "ResourceLink": ".resourcelink", "ResourceLinkTypedDict": ".resourcelink", + "ResourcesCapability": ".resourcescapability", + "ResourcesCapabilityTypedDict": ".resourcescapability", + "ResourceType": ".resourcetype", "ResourceVisibility": ".resourcevisibility", "ResponseDoneEvent": ".responsedoneevent", "ResponseDoneEventTypedDict": ".responsedoneevent", @@ -4802,7 +5224,11 @@ "RetrieveModelV1ModelsModelIDGetRequestTypedDict": ".retrieve_model_v1_models_model_id_getop", "UnknownResponseRetrieveModelV1ModelsModelIDGet": ".retrieve_model_v1_models_model_id_getop", "Roles": ".roles", + "RootsCapability": ".rootscapability", + "RootsCapabilityTypedDict": ".rootscapability", "SampleType": ".sampletype", + "SamplingCapability": ".samplingcapability", + "SamplingCapabilityTypedDict": ".samplingcapability", "ScalarMetric": ".scalarmetric", "ScalarMetricTypedDict": ".scalarmetric", "ScalarMetricValue": ".scalarmetric", @@ -4832,8 +5258,22 @@ "SearchChatCompletionEventsRequestTypedDict": ".searchchatcompletioneventsrequest", "SearchChatCompletionEventsResponse": ".searchchatcompletioneventsresponse", "SearchChatCompletionEventsResponseTypedDict": ".searchchatcompletioneventsresponse", + "SearchIndexResponse": ".searchindexresponse", + "SearchIndexResponseIndex": ".searchindexresponse", + "SearchIndexResponseIndexTypedDict": ".searchindexresponse", + "SearchIndexResponseStatus": ".searchindexresponse", + "SearchIndexResponseTypedDict": ".searchindexresponse", + "UnknownSearchIndexResponseIndex": ".searchindexresponse", "Security": ".security", "SecurityTypedDict": ".security", + "ServerCapabilities": ".servercapabilities", + "ServerCapabilitiesTypedDict": ".servercapabilities", + "ServerLocale": ".serverlocale", + "ServerLocaleTypedDict": ".serverlocale", + "ServerTasksCapability": ".servertaskscapability", + "ServerTasksCapabilityTypedDict": ".servertaskscapability", + "ServerTasksRequestsCapability": ".servertasksrequestscapability", + "ServerTasksRequestsCapabilityTypedDict": ".servertasksrequestscapability", "ShareEnum": ".shareenum", "Sharing": ".sharing", "SharingTypedDict": ".sharing", @@ -4888,6 +5328,12 @@ "SystemMessageTypedDict": ".systemmessage", "SystemMessageContentChunks": ".systemmessagecontentchunks", "SystemMessageContentChunksTypedDict": ".systemmessagecontentchunks", + "TasksElicitationCapability": ".taskselicitationcapability", + "TasksElicitationCapabilityTypedDict": ".taskselicitationcapability", + "TasksSamplingCapability": ".taskssamplingcapability", + "TasksSamplingCapabilityTypedDict": ".taskssamplingcapability", + "TasksToolsCapability": ".taskstoolscapability", + "TasksToolsCapabilityTypedDict": ".taskstoolscapability", "TempoGetTraceResponse": ".tempogettraceresponse", "TempoGetTraceResponseTypedDict": ".tempogettraceresponse", "TempoTraceAttribute": ".tempotraceattribute", @@ -4955,6 +5401,12 @@ "TaskSupport": ".toolexecution", "ToolExecution": ".toolexecution", "ToolExecutionTypedDict": ".toolexecution", + "RequiresConfirmation": ".toolexecutionconfiguration", + "RequiresConfirmationTypedDict": ".toolexecutionconfiguration", + "SkipConfirmation": ".toolexecutionconfiguration", + "SkipConfirmationTypedDict": ".toolexecutionconfiguration", + "ToolExecutionConfiguration": ".toolexecutionconfiguration", + "ToolExecutionConfigurationTypedDict": ".toolexecutionconfiguration", "ToolExecutionDeltaEvent": ".toolexecutiondeltaevent", "ToolExecutionDeltaEventName": ".toolexecutiondeltaevent", "ToolExecutionDeltaEventNameTypedDict": ".toolexecutiondeltaevent", @@ -4979,11 +5431,14 @@ "ToolMessageContent": ".toolmessage", "ToolMessageContentTypedDict": ".toolmessage", "ToolMessageTypedDict": ".toolmessage", + "ToolProperties": ".toolproperties", + "ToolPropertiesTypedDict": ".toolproperties", "ToolReferenceChunk": ".toolreferencechunk", "ToolReferenceChunkTool": ".toolreferencechunk", "ToolReferenceChunkToolTypedDict": ".toolreferencechunk", "ToolReferenceChunkTypedDict": ".toolreferencechunk", - "ToolType": ".tooltype", + "ToolsCapability": ".toolscapability", + "ToolsCapabilityTypedDict": ".toolscapability", "TrainingFile": ".trainingfile", "TrainingFileTypedDict": ".trainingfile", "TranscriptionResponse": ".transcriptionresponse", @@ -5004,10 +5459,8 @@ "TranscriptionStreamSegmentDeltaTypedDict": ".transcriptionstreamsegmentdelta", "TranscriptionStreamTextDelta": ".transcriptionstreamtextdelta", "TranscriptionStreamTextDeltaTypedDict": ".transcriptionstreamtextdelta", - "TurbineToolLocale": ".turbinetoollocale", - "TurbineToolLocaleTypedDict": ".turbinetoollocale", - "TurbineToolMeta": ".turbinetoolmeta", - "TurbineToolMetaTypedDict": ".turbinetoolmeta", + "TurbineMeta": ".turbinemeta", + "TurbineMetaTypedDict": ".turbinemeta", "UnarchiveWorkflowV1WorkflowsWorkflowIdentifierUnarchivePutRequest": ".unarchive_workflow_v1_workflows_workflow_identifier_unarchive_putop", "UnarchiveWorkflowV1WorkflowsWorkflowIdentifierUnarchivePutRequestTypedDict": ".unarchive_workflow_v1_workflows_workflow_identifier_unarchive_putop", "UnarchiveModelResponse": ".unarchivemodelresponse", @@ -5024,6 +5477,8 @@ "UpdateJudgeV1ObservabilityJudgesJudgeIDPutRequestTypedDict": ".update_judge_v1_observability_judges_judge_id_putop", "UpdateRunInfoV1RagIngestionPipelineConfigurationsIDRunInfoPutRequest": ".update_run_info_v1_rag_ingestion_pipeline_configurations_id_run_info_putop", "UpdateRunInfoV1RagIngestionPipelineConfigurationsIDRunInfoPutRequestTypedDict": ".update_run_info_v1_rag_ingestion_pipeline_configurations_id_run_info_putop", + "UpdateScheduleV1WorkflowsSchedulesScheduleIDPatchRequest": ".update_schedule_v1_workflows_schedules_schedule_id_patchop", + "UpdateScheduleV1WorkflowsSchedulesScheduleIDPatchRequestTypedDict": ".update_schedule_v1_workflows_schedules_schedule_id_patchop", "UpdateVoiceV1AudioVoicesVoiceIDPatchRequest": ".update_voice_v1_audio_voices_voice_id_patchop", "UpdateVoiceV1AudioVoicesVoiceIDPatchRequestTypedDict": ".update_voice_v1_audio_voices_voice_id_patchop", "UpdateWorkflowExecutionV1WorkflowsExecutionsExecutionIDUpdatesPostRequest": ".update_workflow_execution_v1_workflows_executions_execution_id_updates_postop", @@ -5078,6 +5533,12 @@ "LocTypedDict": ".validationerror", "ValidationError": ".validationerror", "ValidationErrorTypedDict": ".validationerror", + "VespaSchemaResponse": ".vespaschemaresponse", + "VespaSchemaResponseTypedDict": ".vespaschemaresponse", + "VespaSearchIndexInfoResponse": ".vespasearchindexinforesponse", + "VespaSearchIndexInfoResponseTypedDict": ".vespasearchindexinforesponse", + "VoiceAppearance": ".voiceappearance", + "VoiceAppearanceTypedDict": ".voiceappearance", "VoiceCreateRequest": ".voicecreaterequest", "VoiceCreateRequestTypedDict": ".voicecreaterequest", "VoiceListResponse": ".voicelistresponse", @@ -5100,6 +5561,16 @@ "WorkflowArchiveResponseTypedDict": ".workflowarchiveresponse", "WorkflowBasicDefinition": ".workflowbasicdefinition", "WorkflowBasicDefinitionTypedDict": ".workflowbasicdefinition", + "WorkflowBulkArchiveRequest": ".workflowbulkarchiverequest", + "WorkflowBulkArchiveRequestTypedDict": ".workflowbulkarchiverequest", + "WorkflowBulkArchiveResponse": ".workflowbulkarchiveresponse", + "WorkflowBulkArchiveResponseTypedDict": ".workflowbulkarchiveresponse", + "WorkflowBulkError": ".workflowbulkerror", + "WorkflowBulkErrorTypedDict": ".workflowbulkerror", + "WorkflowBulkUnarchiveRequest": ".workflowbulkunarchiverequest", + "WorkflowBulkUnarchiveRequestTypedDict": ".workflowbulkunarchiverequest", + "WorkflowBulkUnarchiveResponse": ".workflowbulkunarchiveresponse", + "WorkflowBulkUnarchiveResponseTypedDict": ".workflowbulkunarchiveresponse", "WorkflowCodeDefinition": ".workflowcodedefinition", "WorkflowCodeDefinitionTypedDict": ".workflowcodedefinition", "WorkflowEventType": ".workfloweventtype", @@ -5174,6 +5645,8 @@ "WorkflowScheduleRequestTypedDict": ".workflowschedulerequest", "WorkflowScheduleResponse": ".workflowscheduleresponse", "WorkflowScheduleResponseTypedDict": ".workflowscheduleresponse", + "WorkflowScheduleUpdateRequest": ".workflowscheduleupdaterequest", + "WorkflowScheduleUpdateRequestTypedDict": ".workflowscheduleupdaterequest", "WorkflowTaskFailedAttributes": ".workflowtaskfailedattributes", "WorkflowTaskFailedAttributesTypedDict": ".workflowtaskfailedattributes", "WorkflowTaskFailedResponse": ".workflowtaskfailedresponse", diff --git a/src/mistralai/client/models/authenticationconfiguration.py b/src/mistralai/client/models/authenticationconfiguration.py index 84f66591..79c69641 100644 --- a/src/mistralai/client/models/authenticationconfiguration.py +++ b/src/mistralai/client/models/authenticationconfiguration.py @@ -2,6 +2,7 @@ # @generated-id: 97b5056c29fb from __future__ import annotations +from .consumertype import ConsumerType from .outboundauthenticationtype import OutboundAuthenticationType from mistralai.client.types import BaseModel, UNSET_SENTINEL from pydantic import model_serializer @@ -12,6 +13,7 @@ class AuthenticationConfigurationTypedDict(TypedDict): name: str authentication_type: OutboundAuthenticationType + scope: ConsumerType is_default: NotRequired[bool] @@ -20,6 +22,8 @@ class AuthenticationConfiguration(BaseModel): authentication_type: OutboundAuthenticationType + scope: ConsumerType + is_default: Optional[bool] = False @model_serializer(mode="wrap") diff --git a/src/mistralai/client/models/clientcapabilities.py b/src/mistralai/client/models/clientcapabilities.py new file mode 100644 index 00000000..77271160 --- /dev/null +++ b/src/mistralai/client/models/clientcapabilities.py @@ -0,0 +1,88 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: b2ad660c5c9b + +from __future__ import annotations +from .clienttaskscapability import ClientTasksCapability, ClientTasksCapabilityTypedDict +from .elicitationcapability import ElicitationCapability, ElicitationCapabilityTypedDict +from .rootscapability import RootsCapability, RootsCapabilityTypedDict +from .samplingcapability import SamplingCapability, SamplingCapabilityTypedDict +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import NotRequired, TypedDict + + +class ClientCapabilitiesTypedDict(TypedDict): + r"""Capabilities a client may support.""" + + experimental: NotRequired[Nullable[Dict[str, Dict[str, Any]]]] + sampling: NotRequired[Nullable[SamplingCapabilityTypedDict]] + elicitation: NotRequired[Nullable[ElicitationCapabilityTypedDict]] + roots: NotRequired[Nullable[RootsCapabilityTypedDict]] + tasks: NotRequired[Nullable[ClientTasksCapabilityTypedDict]] + + +class ClientCapabilities(BaseModel): + r"""Capabilities a client may support.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + experimental: OptionalNullable[Dict[str, Dict[str, Any]]] = UNSET + + sampling: OptionalNullable[SamplingCapability] = UNSET + + elicitation: OptionalNullable[ElicitationCapability] = UNSET + + roots: OptionalNullable[RootsCapability] = UNSET + + tasks: OptionalNullable[ClientTasksCapability] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set( + ["experimental", "sampling", "elicitation", "roots", "tasks"] + ) + nullable_fields = set( + ["experimental", "sampling", "elicitation", "roots", "tasks"] + ) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m diff --git a/src/mistralai/client/models/clienttaskscapability.py b/src/mistralai/client/models/clienttaskscapability.py new file mode 100644 index 00000000..5256c3d5 --- /dev/null +++ b/src/mistralai/client/models/clienttaskscapability.py @@ -0,0 +1,78 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 83aeca444b21 + +from __future__ import annotations +from .clienttasksrequestscapability import ( + ClientTasksRequestsCapability, + ClientTasksRequestsCapabilityTypedDict, +) +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import NotRequired, TypedDict + + +class ClientTasksCapabilityTypedDict(TypedDict): + r"""Capability for client tasks operations.""" + + list: NotRequired[Nullable[Dict[str, Any]]] + cancel: NotRequired[Nullable[Dict[str, Any]]] + requests: NotRequired[Nullable[ClientTasksRequestsCapabilityTypedDict]] + + +class ClientTasksCapability(BaseModel): + r"""Capability for client tasks operations.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + list: OptionalNullable[Dict[str, Any]] = UNSET + + cancel: OptionalNullable[Dict[str, Any]] = UNSET + + requests: OptionalNullable[ClientTasksRequestsCapability] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["list", "cancel", "requests"]) + nullable_fields = set(["list", "cancel", "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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m diff --git a/src/mistralai/client/models/clienttasksrequestscapability.py b/src/mistralai/client/models/clienttasksrequestscapability.py new file mode 100644 index 00000000..38b9d6b1 --- /dev/null +++ b/src/mistralai/client/models/clienttasksrequestscapability.py @@ -0,0 +1,79 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 26148da505a0 + +from __future__ import annotations +from .taskselicitationcapability import ( + TasksElicitationCapability, + TasksElicitationCapabilityTypedDict, +) +from .taskssamplingcapability import ( + TasksSamplingCapability, + TasksSamplingCapabilityTypedDict, +) +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import NotRequired, TypedDict + + +class ClientTasksRequestsCapabilityTypedDict(TypedDict): + r"""Capability for tasks requests operations.""" + + sampling: NotRequired[Nullable[TasksSamplingCapabilityTypedDict]] + elicitation: NotRequired[Nullable[TasksElicitationCapabilityTypedDict]] + + +class ClientTasksRequestsCapability(BaseModel): + r"""Capability for tasks requests operations.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + sampling: OptionalNullable[TasksSamplingCapability] = UNSET + + elicitation: OptionalNullable[TasksElicitationCapability] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["sampling", "elicitation"]) + nullable_fields = set(["sampling", "elicitation"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m diff --git a/src/mistralai/client/models/connectionconfigtype.py b/src/mistralai/client/models/connectionconfigtype.py new file mode 100644 index 00000000..9ad1bee1 --- /dev/null +++ b/src/mistralai/client/models/connectionconfigtype.py @@ -0,0 +1,16 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 52923bfd57d3 + +from __future__ import annotations +from mistralai.client.types import UnrecognizedStr +from typing import Literal, Union + + +ConnectionConfigType = Union[ + Literal[ + "mcp", + "turbine", + "eolienne", + ], + UnrecognizedStr, +] diff --git a/src/mistralai/client/models/turbinetoolmeta.py b/src/mistralai/client/models/connectionpreference.py similarity index 56% rename from src/mistralai/client/models/turbinetoolmeta.py rename to src/mistralai/client/models/connectionpreference.py index bcd4d5f2..953ef17c 100644 --- a/src/mistralai/client/models/turbinetoolmeta.py +++ b/src/mistralai/client/models/connectionpreference.py @@ -1,9 +1,12 @@ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" -# @generated-id: cdb07c3837f7 +# @generated-id: 6b9389ac91e6 from __future__ import annotations -from .tooltype import ToolType -from .turbinetoollocale import TurbineToolLocale, TurbineToolLocaleTypedDict +from .consumertype import ConsumerType +from .toolexecutionconfiguration import ( + ToolExecutionConfiguration, + ToolExecutionConfigurationTypedDict, +) from mistralai.client.types import ( BaseModel, Nullable, @@ -15,26 +18,26 @@ from typing_extensions import NotRequired, TypedDict -class TurbineToolMetaTypedDict(TypedDict): - locale: NotRequired[Nullable[TurbineToolLocaleTypedDict]] - tool_type: NotRequired[Nullable[ToolType]] - timeout: NotRequired[Nullable[float]] - private_execution: NotRequired[Nullable[bool]] +class ConnectionPreferenceTypedDict(TypedDict): + name: str + tool_configuration: ToolExecutionConfigurationTypedDict + is_default: NotRequired[Nullable[bool]] + consumer_type: NotRequired[Nullable[ConsumerType]] -class TurbineToolMeta(BaseModel): - locale: OptionalNullable[TurbineToolLocale] = UNSET +class ConnectionPreference(BaseModel): + name: str - tool_type: OptionalNullable[ToolType] = UNSET + tool_configuration: ToolExecutionConfiguration - timeout: OptionalNullable[float] = UNSET + is_default: OptionalNullable[bool] = UNSET - private_execution: OptionalNullable[bool] = UNSET + consumer_type: OptionalNullable[ConsumerType] = UNSET @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = set(["locale", "tool_type", "timeout", "private_execution"]) - nullable_fields = set(["locale", "tool_type", "timeout", "private_execution"]) + optional_fields = set(["is_default", "consumer_type"]) + nullable_fields = set(["is_default", "consumer_type"]) serialized = handler(self) m = {} diff --git a/src/mistralai/client/models/connector.py b/src/mistralai/client/models/connector.py index 9d8b6000..ce9e0837 100644 --- a/src/mistralai/client/models/connector.py +++ b/src/mistralai/client/models/connector.py @@ -2,6 +2,25 @@ # @generated-id: 1a4facac922d from __future__ import annotations +from .authenticationconfiguration import ( + AuthenticationConfiguration, + AuthenticationConfigurationTypedDict, +) +from .connectionpreference import ConnectionPreference, ConnectionPreferenceTypedDict +from .connectorlocale import ConnectorLocale, ConnectorLocaleTypedDict +from .connectorprotocol import ConnectorProtocol +from .connectortool import ConnectorTool, ConnectorToolTypedDict +from .mcpservercard import MCPServerCard, MCPServerCardTypedDict +from .publicauthenticationmethod import ( + PublicAuthenticationMethod, + PublicAuthenticationMethodTypedDict, +) +from .publicconnectionconfig import ( + PublicConnectionConfig, + PublicConnectionConfigTypedDict, +) +from .resourcetype import ResourceType +from .resourcevisibility import ResourceVisibility from datetime import datetime from mistralai.client.types import ( BaseModel, @@ -11,6 +30,7 @@ UNSET_SENTINEL, ) from pydantic import model_serializer +from typing import List, Optional from typing_extensions import NotRequired, TypedDict @@ -20,9 +40,30 @@ class ConnectorTypedDict(TypedDict): description: str created_at: datetime modified_at: datetime + owner_type: ResourceType + visibility: ResourceVisibility + private_tool_execution: bool title: NotRequired[Nullable[str]] server: NotRequired[Nullable[str]] - auth_type: NotRequired[Nullable[str]] + protocol: NotRequired[ConnectorProtocol] + icon_url: NotRequired[Nullable[str]] + server_card: NotRequired[Nullable[MCPServerCardTypedDict]] + owner_id: NotRequired[Nullable[str]] + locale: NotRequired[Nullable[ConnectorLocaleTypedDict]] + system_prompt: NotRequired[Nullable[str]] + supported_auth_methods: NotRequired[ + Nullable[List[PublicAuthenticationMethodTypedDict]] + ] + connection_preferences: NotRequired[Nullable[List[ConnectionPreferenceTypedDict]]] + connection_credentials: NotRequired[ + Nullable[List[AuthenticationConfigurationTypedDict]] + ] + active: NotRequired[Nullable[bool]] + mistral: NotRequired[bool] + is_authenticated: NotRequired[Nullable[bool]] + tools: NotRequired[Nullable[List[ConnectorToolTypedDict]]] + system_prompt_route: NotRequired[Nullable[str]] + connection_config: NotRequired[Nullable[PublicConnectionConfigTypedDict]] class Connector(BaseModel): @@ -36,16 +77,88 @@ class Connector(BaseModel): modified_at: datetime + owner_type: ResourceType + + visibility: ResourceVisibility + + private_tool_execution: bool + title: OptionalNullable[str] = UNSET server: OptionalNullable[str] = UNSET - auth_type: OptionalNullable[str] = UNSET + protocol: Optional[ConnectorProtocol] = None + + icon_url: OptionalNullable[str] = UNSET + + server_card: OptionalNullable[MCPServerCard] = UNSET + + owner_id: OptionalNullable[str] = UNSET + + locale: OptionalNullable[ConnectorLocale] = UNSET + + system_prompt: OptionalNullable[str] = UNSET + + supported_auth_methods: OptionalNullable[List[PublicAuthenticationMethod]] = UNSET + + connection_preferences: OptionalNullable[List[ConnectionPreference]] = UNSET + + connection_credentials: OptionalNullable[List[AuthenticationConfiguration]] = UNSET + + active: OptionalNullable[bool] = UNSET + + mistral: Optional[bool] = False + + is_authenticated: OptionalNullable[bool] = UNSET + + tools: OptionalNullable[List[ConnectorTool]] = UNSET + + system_prompt_route: OptionalNullable[str] = UNSET + + connection_config: OptionalNullable[PublicConnectionConfig] = UNSET @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = set(["title", "server", "auth_type"]) - nullable_fields = set(["title", "server", "auth_type"]) + optional_fields = set( + [ + "title", + "server", + "protocol", + "icon_url", + "server_card", + "owner_id", + "locale", + "system_prompt", + "supported_auth_methods", + "connection_preferences", + "connection_credentials", + "active", + "mistral", + "is_authenticated", + "tools", + "system_prompt_route", + "connection_config", + ] + ) + nullable_fields = set( + [ + "title", + "server", + "icon_url", + "server_card", + "owner_id", + "locale", + "system_prompt", + "supported_auth_methods", + "connection_preferences", + "connection_credentials", + "active", + "is_authenticated", + "tools", + "system_prompt_route", + "connection_config", + ] + ) serialized = handler(self) m = {} diff --git a/src/mistralai/client/models/connector_activate_for_organization_v1op.py b/src/mistralai/client/models/connector_activate_for_organization_v1op.py new file mode 100644 index 00000000..1b0ec3b0 --- /dev/null +++ b/src/mistralai/client/models/connector_activate_for_organization_v1op.py @@ -0,0 +1,61 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 9b35397dd5cc + +from __future__ import annotations +from .toolexecutionconfiguration import ( + ToolExecutionConfiguration, + ToolExecutionConfigurationTypedDict, +) +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from mistralai.client.utils import FieldMetadata, PathParamMetadata, RequestMetadata +from pydantic import model_serializer +from typing_extensions import Annotated, NotRequired, TypedDict + + +class ConnectorActivateForOrganizationV1RequestTypedDict(TypedDict): + connector_id: str + tool_execution_configuration: NotRequired[ + Nullable[ToolExecutionConfigurationTypedDict] + ] + + +class ConnectorActivateForOrganizationV1Request(BaseModel): + connector_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + + tool_execution_configuration: Annotated[ + OptionalNullable[ToolExecutionConfiguration], + FieldMetadata(request=RequestMetadata(media_type="application/json")), + ] = UNSET + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["ToolExecutionConfiguration"]) + nullable_fields = set(["ToolExecutionConfiguration"]) + 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 diff --git a/src/mistralai/client/models/connector_activate_for_user_v1op.py b/src/mistralai/client/models/connector_activate_for_user_v1op.py new file mode 100644 index 00000000..e30126d4 --- /dev/null +++ b/src/mistralai/client/models/connector_activate_for_user_v1op.py @@ -0,0 +1,61 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 6bf45c78cfea + +from __future__ import annotations +from .toolexecutionconfiguration import ( + ToolExecutionConfiguration, + ToolExecutionConfigurationTypedDict, +) +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from mistralai.client.utils import FieldMetadata, PathParamMetadata, RequestMetadata +from pydantic import model_serializer +from typing_extensions import Annotated, NotRequired, TypedDict + + +class ConnectorActivateForUserV1RequestTypedDict(TypedDict): + connector_id: str + tool_execution_configuration: NotRequired[ + Nullable[ToolExecutionConfigurationTypedDict] + ] + + +class ConnectorActivateForUserV1Request(BaseModel): + connector_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + + tool_execution_configuration: Annotated[ + OptionalNullable[ToolExecutionConfiguration], + FieldMetadata(request=RequestMetadata(media_type="application/json")), + ] = UNSET + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["ToolExecutionConfiguration"]) + nullable_fields = set(["ToolExecutionConfiguration"]) + 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 diff --git a/src/mistralai/client/models/connector_activate_for_workspace_v1op.py b/src/mistralai/client/models/connector_activate_for_workspace_v1op.py new file mode 100644 index 00000000..00fe6699 --- /dev/null +++ b/src/mistralai/client/models/connector_activate_for_workspace_v1op.py @@ -0,0 +1,61 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: b6392712ddaf + +from __future__ import annotations +from .toolexecutionconfiguration import ( + ToolExecutionConfiguration, + ToolExecutionConfigurationTypedDict, +) +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from mistralai.client.utils import FieldMetadata, PathParamMetadata, RequestMetadata +from pydantic import model_serializer +from typing_extensions import Annotated, NotRequired, TypedDict + + +class ConnectorActivateForWorkspaceV1RequestTypedDict(TypedDict): + connector_id: str + tool_execution_configuration: NotRequired[ + Nullable[ToolExecutionConfigurationTypedDict] + ] + + +class ConnectorActivateForWorkspaceV1Request(BaseModel): + connector_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + + tool_execution_configuration: Annotated[ + OptionalNullable[ToolExecutionConfiguration], + FieldMetadata(request=RequestMetadata(media_type="application/json")), + ] = UNSET + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["ToolExecutionConfiguration"]) + nullable_fields = set(["ToolExecutionConfiguration"]) + 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 diff --git a/src/mistralai/client/models/connector_deactivate_for_organization_v1op.py b/src/mistralai/client/models/connector_deactivate_for_organization_v1op.py new file mode 100644 index 00000000..4c5c5458 --- /dev/null +++ b/src/mistralai/client/models/connector_deactivate_for_organization_v1op.py @@ -0,0 +1,17 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 850bece829b0 + +from __future__ import annotations +from mistralai.client.types import BaseModel +from mistralai.client.utils import FieldMetadata, PathParamMetadata +from typing_extensions import Annotated, TypedDict + + +class ConnectorDeactivateForOrganizationV1RequestTypedDict(TypedDict): + connector_id: str + + +class ConnectorDeactivateForOrganizationV1Request(BaseModel): + connector_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] diff --git a/src/mistralai/client/models/connector_deactivate_for_user_v1op.py b/src/mistralai/client/models/connector_deactivate_for_user_v1op.py new file mode 100644 index 00000000..5d998877 --- /dev/null +++ b/src/mistralai/client/models/connector_deactivate_for_user_v1op.py @@ -0,0 +1,17 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 1df4227a54f7 + +from __future__ import annotations +from mistralai.client.types import BaseModel +from mistralai.client.utils import FieldMetadata, PathParamMetadata +from typing_extensions import Annotated, TypedDict + + +class ConnectorDeactivateForUserV1RequestTypedDict(TypedDict): + connector_id: str + + +class ConnectorDeactivateForUserV1Request(BaseModel): + connector_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] diff --git a/src/mistralai/client/models/connector_deactivate_for_workspace_v1op.py b/src/mistralai/client/models/connector_deactivate_for_workspace_v1op.py new file mode 100644 index 00000000..9f02d887 --- /dev/null +++ b/src/mistralai/client/models/connector_deactivate_for_workspace_v1op.py @@ -0,0 +1,17 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: d82c1a5321cc + +from __future__ import annotations +from mistralai.client.types import BaseModel +from mistralai.client.utils import FieldMetadata, PathParamMetadata +from typing_extensions import Annotated, TypedDict + + +class ConnectorDeactivateForWorkspaceV1RequestTypedDict(TypedDict): + connector_id: str + + +class ConnectorDeactivateForWorkspaceV1Request(BaseModel): + connector_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] diff --git a/src/mistralai/client/models/connector_get_v1op.py b/src/mistralai/client/models/connector_get_v1op.py index 780afac9..beb27872 100644 --- a/src/mistralai/client/models/connector_get_v1op.py +++ b/src/mistralai/client/models/connector_get_v1op.py @@ -11,10 +11,10 @@ class ConnectorGetV1RequestTypedDict(TypedDict): connector_id_or_name: str + fetch_user_data: NotRequired[bool] + r"""Fetch the user-level data associated with the connector (e.g. connection credentials).""" fetch_customer_data: NotRequired[bool] r"""Fetch the customer data associated with the connector (e.g. customer secrets / config).""" - fetch_connection_secrets: NotRequired[bool] - r"""Fetch the general connection secrets associated with the connector.""" class ConnectorGetV1Request(BaseModel): @@ -22,21 +22,21 @@ class ConnectorGetV1Request(BaseModel): str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) ] - fetch_customer_data: Annotated[ + fetch_user_data: Annotated[ Optional[bool], FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), ] = False - r"""Fetch the customer data associated with the connector (e.g. customer secrets / config).""" + r"""Fetch the user-level data associated with the connector (e.g. connection credentials).""" - fetch_connection_secrets: Annotated[ + fetch_customer_data: Annotated[ Optional[bool], FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), ] = False - r"""Fetch the general connection secrets associated with the connector.""" + r"""Fetch the customer data associated with the connector (e.g. customer secrets / config).""" @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = set(["fetch_customer_data", "fetch_connection_secrets"]) + optional_fields = set(["fetch_user_data", "fetch_customer_data"]) serialized = handler(self) m = {} diff --git a/src/mistralai/client/models/connectorlocale.py b/src/mistralai/client/models/connectorlocale.py new file mode 100644 index 00000000..373e9e84 --- /dev/null +++ b/src/mistralai/client/models/connectorlocale.py @@ -0,0 +1,21 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: f987f5207d2e + +from __future__ import annotations +from mistralai.client.types import BaseModel +from typing import Dict +from typing_extensions import TypedDict + + +class ConnectorLocaleTypedDict(TypedDict): + name: Dict[str, str] + description: Dict[str, str] + usage_sentence: Dict[str, str] + + +class ConnectorLocale(BaseModel): + name: Dict[str, str] + + description: Dict[str, str] + + usage_sentence: Dict[str, str] diff --git a/src/mistralai/client/models/tooltype.py b/src/mistralai/client/models/connectorprotocol.py similarity index 67% rename from src/mistralai/client/models/tooltype.py rename to src/mistralai/client/models/connectorprotocol.py index 1a7781fc..042f2352 100644 --- a/src/mistralai/client/models/tooltype.py +++ b/src/mistralai/client/models/connectorprotocol.py @@ -1,17 +1,16 @@ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" -# @generated-id: cbe8c44aee50 +# @generated-id: c35853b1b79f from __future__ import annotations from mistralai.client.types import UnrecognizedStr from typing import Literal, Union -ToolType = Union[ +ConnectorProtocol = Union[ Literal[ - "rag", - "image", - "code", - "event", + "mcp", + "http", + "turbine", ], UnrecognizedStr, ] diff --git a/src/mistralai/client/models/connectorsqueryfilters.py b/src/mistralai/client/models/connectorsqueryfilters.py index f10d6897..860caf43 100644 --- a/src/mistralai/client/models/connectorsqueryfilters.py +++ b/src/mistralai/client/models/connectorsqueryfilters.py @@ -11,29 +11,21 @@ ) from mistralai.client.utils import FieldMetadata from pydantic import model_serializer -from typing import Optional from typing_extensions import Annotated, NotRequired, TypedDict class ConnectorsQueryFiltersTypedDict(TypedDict): active: NotRequired[Nullable[bool]] r"""Filter for active connectors for a given user, workspace and organization.""" - fetch_connection_secrets: NotRequired[bool] - r"""Fetch connection secrets.""" class ConnectorsQueryFilters(BaseModel): active: Annotated[OptionalNullable[bool], FieldMetadata(query=True)] = UNSET r"""Filter for active connectors for a given user, workspace and organization.""" - fetch_connection_secrets: Annotated[Optional[bool], FieldMetadata(query=True)] = ( - False - ) - r"""Fetch connection secrets.""" - @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = set(["active", "fetch_connection_secrets"]) + optional_fields = set(["active"]) nullable_fields = set(["active"]) serialized = handler(self) m = {} diff --git a/src/mistralai/client/models/consumertype.py b/src/mistralai/client/models/consumertype.py new file mode 100644 index 00000000..ac091e5e --- /dev/null +++ b/src/mistralai/client/models/consumertype.py @@ -0,0 +1,17 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: d18230da2fdd + +from __future__ import annotations +from mistralai.client.types import UnrecognizedStr +from typing import Literal, Union + + +ConsumerType = Union[ + Literal[ + "user", + "org", + "workspace", + "system", + ], + UnrecognizedStr, +] diff --git a/src/mistralai/client/models/createconnectorrequest.py b/src/mistralai/client/models/createconnectorrequest.py index 18060ca3..ac732104 100644 --- a/src/mistralai/client/models/createconnectorrequest.py +++ b/src/mistralai/client/models/createconnectorrequest.py @@ -11,9 +11,12 @@ UNSET, UNSET_SENTINEL, ) +from mistralai.client.utils import validate_const +import pydantic from pydantic import model_serializer -from typing import Any, Dict, Optional -from typing_extensions import NotRequired, TypedDict +from pydantic.functional_validators import AfterValidator +from typing import Any, Dict, Literal, Optional +from typing_extensions import Annotated, NotRequired, TypedDict class CreateConnectorRequestTypedDict(TypedDict): @@ -23,6 +26,7 @@ class CreateConnectorRequestTypedDict(TypedDict): r"""The description of the connector.""" server: str r"""The url of the MCP server.""" + protocol: Literal["mcp"] title: NotRequired[Nullable[str]] r"""Optional human-readable title for the connector.""" icon_url: NotRequired[Nullable[str]] @@ -46,6 +50,11 @@ class CreateConnectorRequest(BaseModel): server: str r"""The url of the MCP server.""" + protocol: Annotated[ + Annotated[Optional[Literal["mcp"]], AfterValidator(validate_const("mcp"))], + pydantic.Field(alias="protocol"), + ] = "mcp" + title: OptionalNullable[str] = UNSET r"""Optional human-readable title for the connector.""" @@ -66,7 +75,15 @@ class CreateConnectorRequest(BaseModel): @model_serializer(mode="wrap") def serialize_model(self, handler): optional_fields = set( - ["title", "icon_url", "visibility", "headers", "auth_data", "system_prompt"] + [ + "protocol", + "title", + "icon_url", + "visibility", + "headers", + "auth_data", + "system_prompt", + ] ) nullable_fields = set( ["title", "icon_url", "headers", "auth_data", "system_prompt"] @@ -91,3 +108,9 @@ def serialize_model(self, handler): m[k] = val return m + + +try: + CreateConnectorRequest.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/createlibraryrequest.py b/src/mistralai/client/models/createlibraryrequest.py index e0357e92..2bbb1e18 100644 --- a/src/mistralai/client/models/createlibraryrequest.py +++ b/src/mistralai/client/models/createlibraryrequest.py @@ -9,9 +9,10 @@ UNSET, UNSET_SENTINEL, ) +import pydantic from pydantic import model_serializer from typing import Literal -from typing_extensions import NotRequired, TypedDict +from typing_extensions import Annotated, NotRequired, TypedDict OwnerType = Literal[ @@ -34,7 +35,12 @@ class CreateLibraryRequest(BaseModel): description: OptionalNullable[str] = UNSET - chunk_size: OptionalNullable[int] = UNSET + chunk_size: Annotated[ + OptionalNullable[int], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] = UNSET r"""The size of the chunks (in characters) to split document text into. Must be between 256 and 32768.""" owner_type: OptionalNullable[OwnerType] = UNSET diff --git a/src/mistralai/client/models/createsearchindexinforequest.py b/src/mistralai/client/models/createsearchindexinforequest.py new file mode 100644 index 00000000..f527f72d --- /dev/null +++ b/src/mistralai/client/models/createsearchindexinforequest.py @@ -0,0 +1,72 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 3f424a7063b0 + +from __future__ import annotations +from .createvespasearchindexinforequest import ( + CreateVespaSearchIndexInfoRequest, + CreateVespaSearchIndexInfoRequestTypedDict, +) +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from pydantic import model_serializer +from typing import Literal, Optional +from typing_extensions import NotRequired, TypedDict + + +CreateSearchIndexInfoRequestStatus = Literal[ + "online", + "offline", +] + + +CreateSearchIndexInfoRequestIndexTypedDict = CreateVespaSearchIndexInfoRequestTypedDict + + +CreateSearchIndexInfoRequestIndex = CreateVespaSearchIndexInfoRequest + + +class CreateSearchIndexInfoRequestTypedDict(TypedDict): + name: str + index: CreateSearchIndexInfoRequestIndexTypedDict + document_count: NotRequired[Nullable[int]] + status: NotRequired[CreateSearchIndexInfoRequestStatus] + + +class CreateSearchIndexInfoRequest(BaseModel): + name: str + + index: CreateSearchIndexInfoRequestIndex + + document_count: OptionalNullable[int] = UNSET + + status: Optional[CreateSearchIndexInfoRequestStatus] = "offline" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["document_count", "status"]) + nullable_fields = set(["document_count"]) + 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 diff --git a/src/mistralai/client/models/createvespaschemarequest.py b/src/mistralai/client/models/createvespaschemarequest.py new file mode 100644 index 00000000..cac99bc3 --- /dev/null +++ b/src/mistralai/client/models/createvespaschemarequest.py @@ -0,0 +1,49 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: d44c0c466535 + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from pydantic import model_serializer +from typing_extensions import NotRequired, TypedDict + + +class CreateVespaSchemaRequestTypedDict(TypedDict): + name: str + document_count: NotRequired[Nullable[int]] + + +class CreateVespaSchemaRequest(BaseModel): + name: str + + document_count: OptionalNullable[int] = UNSET + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["document_count"]) + nullable_fields = set(["document_count"]) + 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 diff --git a/src/mistralai/client/models/createvespasearchindexinforequest.py b/src/mistralai/client/models/createvespasearchindexinforequest.py new file mode 100644 index 00000000..50006d38 --- /dev/null +++ b/src/mistralai/client/models/createvespasearchindexinforequest.py @@ -0,0 +1,43 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 866143560866 + +from __future__ import annotations +from .createvespaschemarequest import ( + CreateVespaSchemaRequest, + CreateVespaSchemaRequestTypedDict, +) +from mistralai.client.types import BaseModel +from mistralai.client.utils import validate_const +import pydantic +from pydantic.functional_validators import AfterValidator +from typing import List, Literal +from typing_extensions import Annotated, TypedDict + + +class CreateVespaSearchIndexInfoRequestTypedDict(TypedDict): + k8s_cluster: str + k8s_namespace: str + vespa_instance_name: str + schemas: List[CreateVespaSchemaRequestTypedDict] + type: Literal["vespa"] + + +class CreateVespaSearchIndexInfoRequest(BaseModel): + k8s_cluster: str + + k8s_namespace: str + + vespa_instance_name: str + + schemas: List[CreateVespaSchemaRequest] + + type: Annotated[ + Annotated[Literal["vespa"], AfterValidator(validate_const("vespa"))], + pydantic.Field(alias="type"), + ] = "vespa" + + +try: + CreateVespaSearchIndexInfoRequest.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/document.py b/src/mistralai/client/models/document.py index 8d1aea88..c04512c1 100644 --- a/src/mistralai/client/models/document.py +++ b/src/mistralai/client/models/document.py @@ -11,9 +11,10 @@ UNSET, UNSET_SENTINEL, ) +import pydantic from pydantic import model_serializer from typing import Any, Dict -from typing_extensions import NotRequired, TypedDict +from typing_extensions import Annotated, NotRequired, TypedDict class DocumentTypedDict(TypedDict): @@ -37,6 +38,8 @@ class DocumentTypedDict(TypedDict): tokens_processing_summary: NotRequired[Nullable[int]] url: NotRequired[Nullable[str]] attributes: NotRequired[Nullable[Dict[str, Any]]] + expires_at: NotRequired[Nullable[datetime]] + r"""If set, the document will be automatically deleted after this date.""" class Document(BaseModel): @@ -44,7 +47,12 @@ class Document(BaseModel): library_id: str - hash: Nullable[str] + hash: Annotated[ + Nullable[str], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] mime_type: Nullable[str] @@ -62,7 +70,12 @@ class Document(BaseModel): uploaded_by_type: str - processing_status: str + processing_status: Annotated[ + str, + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] tokens_processing_total: int @@ -72,14 +85,27 @@ class Document(BaseModel): number_of_pages: OptionalNullable[int] = UNSET - tokens_processing_main_content: OptionalNullable[int] = UNSET + tokens_processing_main_content: Annotated[ + OptionalNullable[int], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] = UNSET - tokens_processing_summary: OptionalNullable[int] = UNSET + tokens_processing_summary: Annotated[ + OptionalNullable[int], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] = UNSET url: OptionalNullable[str] = UNSET attributes: OptionalNullable[Dict[str, Any]] = UNSET + expires_at: OptionalNullable[datetime] = UNSET + r"""If set, the document will be automatically deleted after this date.""" + @model_serializer(mode="wrap") def serialize_model(self, handler): optional_fields = set( @@ -91,6 +117,7 @@ def serialize_model(self, handler): "tokens_processing_summary", "url", "attributes", + "expires_at", ] ) nullable_fields = set( @@ -107,6 +134,7 @@ def serialize_model(self, handler): "tokens_processing_summary", "url", "attributes", + "expires_at", ] ) serialized = handler(self) diff --git a/src/mistralai/client/models/elicitationcapability.py b/src/mistralai/client/models/elicitationcapability.py new file mode 100644 index 00000000..12808436 --- /dev/null +++ b/src/mistralai/client/models/elicitationcapability.py @@ -0,0 +1,77 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 63a9b5cfa2f2 + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import NotRequired, TypedDict + + +class ElicitationCapabilityTypedDict(TypedDict): + r"""Capability for elicitation operations. + + Clients must support at least one mode (form or url). + """ + + form: NotRequired[Nullable[Dict[str, Any]]] + url: NotRequired[Nullable[Dict[str, Any]]] + + +class ElicitationCapability(BaseModel): + r"""Capability for elicitation operations. + + Clients must support at least one mode (form or url). + """ + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + form: OptionalNullable[Dict[str, Any]] = UNSET + + url: OptionalNullable[Dict[str, Any]] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["form", "url"]) + nullable_fields = set(["form", "url"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m diff --git a/src/mistralai/client/models/encryptedpatchvalue.py b/src/mistralai/client/models/encryptedpatchvalue.py new file mode 100644 index 00000000..970bd59b --- /dev/null +++ b/src/mistralai/client/models/encryptedpatchvalue.py @@ -0,0 +1,48 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 311803d1f28e + +from __future__ import annotations +from mistralai.client.types import BaseModel +from mistralai.client.utils import validate_const +import pydantic +from pydantic.functional_validators import AfterValidator +from typing import Literal +from typing_extensions import Annotated, TypedDict + + +class EncryptedPatchValueTypedDict(TypedDict): + r"""Wrapper for encrypted patch values in selective json_patch encryption. + + When partial encryption mode is enabled and a patch targets an EncryptedStrField, + the patch value is encrypted and wrapped in this structure. + + The type field acts as a discriminator to distinguish this from user data. + """ + + value: str + type: Literal["__encrypted__"] + + +class EncryptedPatchValue(BaseModel): + r"""Wrapper for encrypted patch values in selective json_patch encryption. + + When partial encryption mode is enabled and a patch targets an EncryptedStrField, + the patch value is encrypted and wrapped in this structure. + + The type field acts as a discriminator to distinguish this from user data. + """ + + value: str + + type: Annotated[ + Annotated[ + Literal["__encrypted__"], AfterValidator(validate_const("__encrypted__")) + ], + pydantic.Field(alias="type"), + ] = "__encrypted__" + + +try: + EncryptedPatchValue.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/filtergroup.py b/src/mistralai/client/models/filtergroup.py index 4e9815b7..3439df66 100644 --- a/src/mistralai/client/models/filtergroup.py +++ b/src/mistralai/client/models/filtergroup.py @@ -16,6 +16,14 @@ from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict +OrTypedDict = TypeAliasType( + "OrTypedDict", Union["FilterGroupTypedDict", FilterConditionTypedDict] +) + + +Or = TypeAliasType("Or", Union["FilterGroup", FilterCondition]) + + class FilterGroupTypedDict(TypedDict): and_: NotRequired[Nullable[List[AndTypedDict]]] or_: NotRequired[Nullable[List[OrTypedDict]]] @@ -52,14 +60,6 @@ def serialize_model(self, handler): return m -OrTypedDict = TypeAliasType( - "OrTypedDict", Union["FilterGroupTypedDict", FilterConditionTypedDict] -) - - -Or = TypeAliasType("Or", Union["FilterGroup", FilterCondition]) - - AndTypedDict = TypeAliasType( "AndTypedDict", Union["FilterGroupTypedDict", FilterConditionTypedDict] ) diff --git a/src/mistralai/client/models/get_schedule_v1_workflows_schedules_schedule_id_getop.py b/src/mistralai/client/models/get_schedule_v1_workflows_schedules_schedule_id_getop.py new file mode 100644 index 00000000..d22d0515 --- /dev/null +++ b/src/mistralai/client/models/get_schedule_v1_workflows_schedules_schedule_id_getop.py @@ -0,0 +1,17 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: cb775bc63ffd + +from __future__ import annotations +from mistralai.client.types import BaseModel +from mistralai.client.utils import FieldMetadata, PathParamMetadata +from typing_extensions import Annotated, TypedDict + + +class GetScheduleV1WorkflowsSchedulesScheduleIDGetRequestTypedDict(TypedDict): + schedule_id: str + + +class GetScheduleV1WorkflowsSchedulesScheduleIDGetRequest(BaseModel): + schedule_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] diff --git a/src/mistralai/client/models/get_schedules_v1_workflows_schedules_getop.py b/src/mistralai/client/models/get_schedules_v1_workflows_schedules_getop.py new file mode 100644 index 00000000..62f8ece2 --- /dev/null +++ b/src/mistralai/client/models/get_schedules_v1_workflows_schedules_getop.py @@ -0,0 +1,113 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: b5f0210eca23 + +from __future__ import annotations +from .workflowschedulelistresponse import ( + WorkflowScheduleListResponse, + WorkflowScheduleListResponseTypedDict, +) +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from mistralai.client.utils import FieldMetadata, QueryParamMetadata +from pydantic import model_serializer +from typing import Awaitable, Callable, Literal, Optional, Union +from typing_extensions import Annotated, NotRequired, TypedDict + + +GetSchedulesV1WorkflowsSchedulesGetStatus = Literal[ + "active", + "paused", +] +r"""Filter by schedule status: 'active' or 'paused'""" + + +class GetSchedulesV1WorkflowsSchedulesGetRequestTypedDict(TypedDict): + workflow_name: NotRequired[Nullable[str]] + r"""Filter by workflow name""" + user_id: NotRequired[Nullable[str]] + r"""Filter by user ID. Pass 'current' to resolve to the authenticated user's ID.""" + status: NotRequired[Nullable[GetSchedulesV1WorkflowsSchedulesGetStatus]] + r"""Filter by schedule status: 'active' or 'paused'""" + page_size: NotRequired[Nullable[int]] + r"""Number of items per page. Omitting this parameter fetches all results at once (deprecated — pass page_size to use pagination).""" + next_page_token: NotRequired[Nullable[str]] + r"""Token for the next page of results""" + + +class GetSchedulesV1WorkflowsSchedulesGetRequest(BaseModel): + workflow_name: Annotated[ + OptionalNullable[str], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = UNSET + r"""Filter by workflow name""" + + user_id: Annotated[ + OptionalNullable[str], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = UNSET + r"""Filter by user ID. Pass 'current' to resolve to the authenticated user's ID.""" + + status: Annotated[ + OptionalNullable[GetSchedulesV1WorkflowsSchedulesGetStatus], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = UNSET + r"""Filter by schedule status: 'active' or 'paused'""" + + page_size: Annotated[ + OptionalNullable[int], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = UNSET + r"""Number of items per page. Omitting this parameter fetches all results at once (deprecated — pass page_size to use pagination).""" + + next_page_token: Annotated[ + OptionalNullable[str], + FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), + ] = UNSET + r"""Token for the next page of results""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set( + ["workflow_name", "user_id", "status", "page_size", "next_page_token"] + ) + nullable_fields = set( + ["workflow_name", "user_id", "status", "page_size", "next_page_token"] + ) + 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 GetSchedulesV1WorkflowsSchedulesGetResponseTypedDict(TypedDict): + result: WorkflowScheduleListResponseTypedDict + + +class GetSchedulesV1WorkflowsSchedulesGetResponse(BaseModel): + next: Union[ + Callable[[], Optional[GetSchedulesV1WorkflowsSchedulesGetResponse]], + Callable[[], Awaitable[Optional[GetSchedulesV1WorkflowsSchedulesGetResponse]]], + ] + + result: WorkflowScheduleListResponse diff --git a/src/mistralai/client/models/jsonpatchappend.py b/src/mistralai/client/models/jsonpatchappend.py index 7181ddac..185f7bb7 100644 --- a/src/mistralai/client/models/jsonpatchappend.py +++ b/src/mistralai/client/models/jsonpatchappend.py @@ -2,19 +2,32 @@ # @generated-id: 61801f21f4b0 from __future__ import annotations +from .encryptedpatchvalue import EncryptedPatchValue, EncryptedPatchValueTypedDict from mistralai.client.types import BaseModel from mistralai.client.utils import validate_const import pydantic from pydantic.functional_validators import AfterValidator -from typing import Literal -from typing_extensions import Annotated, TypedDict +from typing import Literal, Union +from typing_extensions import Annotated, TypeAliasType, TypedDict + + +JSONPatchAppendValueTypedDict = TypeAliasType( + "JSONPatchAppendValueTypedDict", Union[EncryptedPatchValueTypedDict, str] +) +r"""The value to use for the operation. A string to append to the existing value, or an EncryptedPatchValue wrapper when encryption is applied.""" + + +JSONPatchAppendValue = TypeAliasType( + "JSONPatchAppendValue", Union[EncryptedPatchValue, str] +) +r"""The value to use for the operation. A string to append to the existing value, or an EncryptedPatchValue wrapper when encryption is applied.""" class JSONPatchAppendTypedDict(TypedDict): path: str r"""A JSON Pointer (RFC 6901) identifying the target location within the document. Can be a string path (e.g., '/foo/bar'), '/', '', or an empty list [] for root-level operations.""" - value: str - r"""The value to use for the operation. A string to append to the existing value""" + value: JSONPatchAppendValueTypedDict + r"""The value to use for the operation. A string to append to the existing value, or an EncryptedPatchValue wrapper when encryption is applied.""" op: Literal["append"] r"""'append' is an extension for efficient string concatenation in streaming scenarios.""" @@ -23,8 +36,8 @@ class JSONPatchAppend(BaseModel): path: str r"""A JSON Pointer (RFC 6901) identifying the target location within the document. Can be a string path (e.g., '/foo/bar'), '/', '', or an empty list [] for root-level operations.""" - value: str - r"""The value to use for the operation. A string to append to the existing value""" + value: JSONPatchAppendValue + r"""The value to use for the operation. A string to append to the existing value, or an EncryptedPatchValue wrapper when encryption is applied.""" op: Annotated[ Annotated[Literal["append"], AfterValidator(validate_const("append"))], diff --git a/src/mistralai/client/models/libraries_documents_list_v1op.py b/src/mistralai/client/models/libraries_documents_list_v1op.py index afc474cb..57e2736b 100644 --- a/src/mistralai/client/models/libraries_documents_list_v1op.py +++ b/src/mistralai/client/models/libraries_documents_list_v1op.py @@ -10,6 +10,7 @@ UNSET_SENTINEL, ) from mistralai.client.utils import FieldMetadata, PathParamMetadata, QueryParamMetadata +import pydantic from pydantic import model_serializer from typing import Optional from typing_extensions import Annotated, NotRequired, TypedDict @@ -21,6 +22,7 @@ class LibrariesDocumentsListV1RequestTypedDict(TypedDict): page_size: NotRequired[int] page: NotRequired[int] filters_attributes: NotRequired[Nullable[str]] + r"""Deprecated: this parameter will be removed in a future version.""" sort_by: NotRequired[str] sort_order: NotRequired[str] @@ -47,8 +49,12 @@ class LibrariesDocumentsListV1Request(BaseModel): filters_attributes: Annotated[ OptionalNullable[str], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), ] = UNSET + r"""Deprecated: this parameter will be removed in a future version.""" sort_by: Annotated[ Optional[str], diff --git a/src/mistralai/client/models/libraries_documents_patch_v1op.py b/src/mistralai/client/models/libraries_documents_patch_v1op.py new file mode 100644 index 00000000..0ae4efaf --- /dev/null +++ b/src/mistralai/client/models/libraries_documents_patch_v1op.py @@ -0,0 +1,29 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 31b2201bbfe2 + +from __future__ import annotations +from .updatedocumentrequest import UpdateDocumentRequest, UpdateDocumentRequestTypedDict +from mistralai.client.types import BaseModel +from mistralai.client.utils import FieldMetadata, PathParamMetadata, RequestMetadata +from typing_extensions import Annotated, TypedDict + + +class LibrariesDocumentsPatchV1RequestTypedDict(TypedDict): + library_id: str + document_id: str + update_document_request: UpdateDocumentRequestTypedDict + + +class LibrariesDocumentsPatchV1Request(BaseModel): + library_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + + document_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + + update_document_request: Annotated[ + UpdateDocumentRequest, + FieldMetadata(request=RequestMetadata(media_type="application/json")), + ] diff --git a/src/mistralai/client/models/libraries_list_v1op.py b/src/mistralai/client/models/libraries_list_v1op.py index cac06dad..328ac72c 100644 --- a/src/mistralai/client/models/libraries_list_v1op.py +++ b/src/mistralai/client/models/libraries_list_v1op.py @@ -10,6 +10,7 @@ UNSET_SENTINEL, ) from mistralai.client.utils import FieldMetadata, QueryParamMetadata +import pydantic from pydantic import model_serializer from typing import Optional from typing_extensions import Annotated, NotRequired, TypedDict @@ -21,7 +22,7 @@ class LibrariesListV1RequestTypedDict(TypedDict): search: NotRequired[Nullable[str]] r"""Case-insensitive search on the library name.""" filter_owned_by_me: NotRequired[Nullable[bool]] - r"""Filter libraries by whether they were created by the current authenticated identity. Set to true for created by me, false for only libraries shared with me, or None to disable this filter.""" + r"""Deprecated: this parameter will be removed in a future version.""" class LibrariesListV1Request(BaseModel): @@ -43,9 +44,12 @@ class LibrariesListV1Request(BaseModel): filter_owned_by_me: Annotated[ OptionalNullable[bool], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), FieldMetadata(query=QueryParamMetadata(style="form", explode=True)), ] = UNSET - r"""Filter libraries by whether they were created by the current authenticated identity. Set to true for created by me, false for only libraries shared with me, or None to disable this filter.""" + r"""Deprecated: this parameter will be removed in a future version.""" @model_serializer(mode="wrap") def serialize_model(self, handler): diff --git a/src/mistralai/client/models/libraries_patch_v1op.py b/src/mistralai/client/models/libraries_patch_v1op.py new file mode 100644 index 00000000..2fbaea67 --- /dev/null +++ b/src/mistralai/client/models/libraries_patch_v1op.py @@ -0,0 +1,24 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 2b189be3c57a + +from __future__ import annotations +from .updatelibraryrequest import UpdateLibraryRequest, UpdateLibraryRequestTypedDict +from mistralai.client.types import BaseModel +from mistralai.client.utils import FieldMetadata, PathParamMetadata, RequestMetadata +from typing_extensions import Annotated, TypedDict + + +class LibrariesPatchV1RequestTypedDict(TypedDict): + library_id: str + update_library_request: UpdateLibraryRequestTypedDict + + +class LibrariesPatchV1Request(BaseModel): + library_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + + update_library_request: Annotated[ + UpdateLibraryRequest, + FieldMetadata(request=RequestMetadata(media_type="application/json")), + ] diff --git a/src/mistralai/client/models/library.py b/src/mistralai/client/models/library.py index 0e09cfaa..4ec8604c 100644 --- a/src/mistralai/client/models/library.py +++ b/src/mistralai/client/models/library.py @@ -52,17 +52,42 @@ class Library(BaseModel): nb_documents: int - chunk_size: Nullable[int] + chunk_size: Annotated[ + Nullable[int], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] - emoji: OptionalNullable[str] = UNSET + emoji: Annotated[ + OptionalNullable[str], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] = UNSET description: OptionalNullable[str] = UNSET - generated_description: OptionalNullable[str] = UNSET + generated_description: Annotated[ + OptionalNullable[str], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] = UNSET - explicit_user_members_count: OptionalNullable[int] = UNSET + explicit_user_members_count: Annotated[ + OptionalNullable[int], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] = UNSET - explicit_workspace_members_count: OptionalNullable[int] = UNSET + explicit_workspace_members_count: Annotated[ + OptionalNullable[int], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] = UNSET org_sharing_role: Annotated[ OptionalNullable[str], @@ -71,7 +96,12 @@ class Library(BaseModel): ), ] = UNSET - generated_name: OptionalNullable[str] = UNSET + generated_name: Annotated[ + OptionalNullable[str], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] = UNSET r"""Generated Name""" @model_serializer(mode="wrap") diff --git a/src/mistralai/client/models/logicalexpression.py b/src/mistralai/client/models/logicalexpression.py new file mode 100644 index 00000000..1b87693c --- /dev/null +++ b/src/mistralai/client/models/logicalexpression.py @@ -0,0 +1,39 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 48d46c10b453 + +from __future__ import annotations +from .toolproperties import ToolProperties, ToolPropertiesTypedDict +from mistralai.client.types import BaseModel, UnrecognizedStr +from typing import List, Literal, Union +from typing_extensions import TypeAliasType, TypedDict + + +LogicalExpressionType = Union[ + Literal[ + "and", + "or", + ], + UnrecognizedStr, +] + + +class LogicalExpressionTypedDict(TypedDict): + type: LogicalExpressionType + expressions: List[ExpressionTypedDict] + + +class LogicalExpression(BaseModel): + type: LogicalExpressionType + + expressions: List[Expression] + + +ExpressionTypedDict = TypeAliasType( + "ExpressionTypedDict", + Union[ToolPropertiesTypedDict, "LogicalExpressionTypedDict", List[str]], +) + + +Expression = TypeAliasType( + "Expression", Union[ToolProperties, "LogicalExpression", List[str]] +) diff --git a/src/mistralai/client/models/mcpprompt.py b/src/mistralai/client/models/mcpprompt.py new file mode 100644 index 00000000..fd5fb0d8 --- /dev/null +++ b/src/mistralai/client/models/mcpprompt.py @@ -0,0 +1,89 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: eac4133413b2 + +from __future__ import annotations +from .mcpservericon import MCPServerIcon, MCPServerIconTypedDict +from .promptargument import PromptArgument, PromptArgumentTypedDict +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict, List +from typing_extensions import Annotated, NotRequired, TypedDict + + +class MCPPromptTypedDict(TypedDict): + name: str + title: NotRequired[Nullable[str]] + description: NotRequired[Nullable[str]] + arguments: NotRequired[Nullable[List[PromptArgumentTypedDict]]] + icons: NotRequired[Nullable[List[MCPServerIconTypedDict]]] + meta: NotRequired[Nullable[Dict[str, Any]]] + + +class MCPPrompt(BaseModel): + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + name: str + + title: OptionalNullable[str] = UNSET + + description: OptionalNullable[str] = UNSET + + arguments: OptionalNullable[List[PromptArgument]] = UNSET + + icons: OptionalNullable[List[MCPServerIcon]] = UNSET + + meta: Annotated[OptionalNullable[Dict[str, Any]], pydantic.Field(alias="_meta")] = ( + UNSET + ) + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["title", "description", "arguments", "icons", "_meta"]) + nullable_fields = set(["title", "description", "arguments", "icons", "_meta"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m + + +try: + MCPPrompt.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/mcpresource.py b/src/mistralai/client/models/mcpresource.py new file mode 100644 index 00000000..77df5857 --- /dev/null +++ b/src/mistralai/client/models/mcpresource.py @@ -0,0 +1,120 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 4922063d1d29 + +from __future__ import annotations +from .annotations import Annotations, AnnotationsTypedDict +from .mcpservericon import MCPServerIcon, MCPServerIconTypedDict +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict, List +from typing_extensions import Annotated, NotRequired, TypedDict + + +class MCPResourceTypedDict(TypedDict): + name: str + uri: str + title: NotRequired[Nullable[str]] + description: NotRequired[Nullable[str]] + mime_type: NotRequired[Nullable[str]] + size: NotRequired[Nullable[int]] + icons: NotRequired[Nullable[List[MCPServerIconTypedDict]]] + annotations: NotRequired[Nullable[AnnotationsTypedDict]] + meta: NotRequired[Nullable[Dict[str, Any]]] + + +class MCPResource(BaseModel): + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + name: str + + uri: str + + title: OptionalNullable[str] = UNSET + + description: OptionalNullable[str] = UNSET + + mime_type: Annotated[OptionalNullable[str], pydantic.Field(alias="mimeType")] = ( + UNSET + ) + + size: OptionalNullable[int] = UNSET + + icons: OptionalNullable[List[MCPServerIcon]] = UNSET + + annotations: OptionalNullable[Annotations] = UNSET + + meta: Annotated[OptionalNullable[Dict[str, Any]], pydantic.Field(alias="_meta")] = ( + UNSET + ) + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set( + [ + "title", + "description", + "mimeType", + "size", + "icons", + "annotations", + "_meta", + ] + ) + nullable_fields = set( + [ + "title", + "description", + "mimeType", + "size", + "icons", + "annotations", + "_meta", + ] + ) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m + + +try: + MCPResource.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/mcpserverauthenticationrequirement.py b/src/mistralai/client/models/mcpserverauthenticationrequirement.py new file mode 100644 index 00000000..280315a7 --- /dev/null +++ b/src/mistralai/client/models/mcpserverauthenticationrequirement.py @@ -0,0 +1,43 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 688772457c1d + +from __future__ import annotations +from mistralai.client.types import BaseModel, UNSET_SENTINEL +from pydantic import model_serializer +from typing import List, Optional +from typing_extensions import NotRequired, TypedDict + + +class MCPServerAuthenticationRequirementTypedDict(TypedDict): + r"""Authentication requirements for a remote transport (SEP-2127).""" + + required: bool + r"""Whether authentication is mandatory""" + schemes: NotRequired[List[str]] + r"""Supported schemes (e.g. ['bearer', 'oauth2'])""" + + +class MCPServerAuthenticationRequirement(BaseModel): + r"""Authentication requirements for a remote transport (SEP-2127).""" + + required: bool + r"""Whether authentication is mandatory""" + + schemes: Optional[List[str]] = None + r"""Supported schemes (e.g. ['bearer', 'oauth2'])""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["schemes"]) + 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/mistralai/client/models/mcpservercard.py b/src/mistralai/client/models/mcpservercard.py new file mode 100644 index 00000000..3e66b954 --- /dev/null +++ b/src/mistralai/client/models/mcpservercard.py @@ -0,0 +1,188 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 3d8e787f97f3 + +from __future__ import annotations +from .clientcapabilities import ClientCapabilities, ClientCapabilitiesTypedDict +from .mcpprompt import MCPPrompt, MCPPromptTypedDict +from .mcpresource import MCPResource, MCPResourceTypedDict +from .mcpservercardmeta import MCPServerCardMeta, MCPServerCardMetaTypedDict +from .mcpservericon import MCPServerIcon, MCPServerIconTypedDict +from .mcpserverremote import MCPServerRemote, MCPServerRemoteTypedDict +from .mcpserverrepository import MCPServerRepository, MCPServerRepositoryTypedDict +from .mcptoolmeta import MCPToolMeta, MCPToolMetaTypedDict +from .servercapabilities import ServerCapabilities, ServerCapabilitiesTypedDict +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict, List, Optional, Union +from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict + + +ResourcesTypedDict = TypeAliasType( + "ResourcesTypedDict", Union[str, List[MCPResourceTypedDict]] +) + + +Resources = TypeAliasType("Resources", Union[str, List[MCPResource]]) + + +ToolsTypedDict = TypeAliasType("ToolsTypedDict", Union[str, List[MCPToolMetaTypedDict]]) + + +Tools = TypeAliasType("Tools", Union[str, List[MCPToolMeta]]) + + +PromptsTypedDict = TypeAliasType( + "PromptsTypedDict", Union[str, List[MCPPromptTypedDict]] +) + + +Prompts = TypeAliasType("Prompts", Union[str, List[MCPPrompt]]) + + +class MCPServerCardTypedDict(TypedDict): + name: str + r"""Server identifier in reverse-DNS format with exactly one /""" + version: str + r"""Server version (semantic versioning preferred)""" + dollar_schema: NotRequired[Nullable[str]] + r"""URL to the JSON schema definition""" + capabilities: NotRequired[ServerCapabilitiesTypedDict] + r"""Capabilities that a server may support.""" + title: NotRequired[Nullable[str]] + description: NotRequired[Nullable[str]] + website_url: NotRequired[Nullable[str]] + repository: NotRequired[Nullable[MCPServerRepositoryTypedDict]] + icons: NotRequired[Nullable[List[MCPServerIconTypedDict]]] + remotes: NotRequired[Nullable[List[MCPServerRemoteTypedDict]]] + requires: NotRequired[Nullable[ClientCapabilitiesTypedDict]] + resources: NotRequired[Nullable[ResourcesTypedDict]] + tools: NotRequired[Nullable[ToolsTypedDict]] + prompts: NotRequired[Nullable[PromptsTypedDict]] + meta: NotRequired[Nullable[MCPServerCardMetaTypedDict]] + + +class MCPServerCard(BaseModel): + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + name: str + r"""Server identifier in reverse-DNS format with exactly one /""" + + version: str + r"""Server version (semantic versioning preferred)""" + + dollar_schema: Annotated[OptionalNullable[str], pydantic.Field(alias="$schema")] = ( + UNSET + ) + r"""URL to the JSON schema definition""" + + capabilities: Optional[ServerCapabilities] = None + r"""Capabilities that a server may support.""" + + title: OptionalNullable[str] = UNSET + + description: OptionalNullable[str] = UNSET + + website_url: Annotated[ + OptionalNullable[str], pydantic.Field(alias="websiteUrl") + ] = UNSET + + repository: OptionalNullable[MCPServerRepository] = UNSET + + icons: OptionalNullable[List[MCPServerIcon]] = UNSET + + remotes: OptionalNullable[List[MCPServerRemote]] = UNSET + + requires: OptionalNullable[ClientCapabilities] = UNSET + + resources: OptionalNullable[Resources] = UNSET + + tools: OptionalNullable[Tools] = UNSET + + prompts: OptionalNullable[Prompts] = UNSET + + meta: Annotated[ + OptionalNullable[MCPServerCardMeta], pydantic.Field(alias="_meta") + ] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set( + [ + "$schema", + "capabilities", + "title", + "description", + "websiteUrl", + "repository", + "icons", + "remotes", + "requires", + "resources", + "tools", + "prompts", + "_meta", + ] + ) + nullable_fields = set( + [ + "$schema", + "title", + "description", + "websiteUrl", + "repository", + "icons", + "remotes", + "requires", + "resources", + "tools", + "prompts", + "_meta", + ] + ) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m + + +try: + MCPServerCard.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/mcpuitoolmeta.py b/src/mistralai/client/models/mcpservercardmeta.py similarity index 67% rename from src/mistralai/client/models/mcpuitoolmeta.py rename to src/mistralai/client/models/mcpservercardmeta.py index 287192a6..daf592f9 100644 --- a/src/mistralai/client/models/mcpuitoolmeta.py +++ b/src/mistralai/client/models/mcpservercardmeta.py @@ -1,51 +1,45 @@ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" -# @generated-id: 7c54fb6157a9 +# @generated-id: 0f095765c6aa from __future__ import annotations +from .turbinemeta import TurbineMeta, TurbineMetaTypedDict from mistralai.client.types import ( BaseModel, Nullable, OptionalNullable, UNSET, UNSET_SENTINEL, - UnrecognizedStr, ) import pydantic from pydantic import ConfigDict, model_serializer -from typing import Any, Dict, List, Literal, Union +from typing import Any, Dict from typing_extensions import Annotated, NotRequired, TypedDict -Visibility = Union[ - Literal[ - "model", - "app", - ], - UnrecognizedStr, -] +class MCPServerCardMetaTypedDict(TypedDict): + r"""Typed _meta for MCP server cards. + Only the 'turbine' field is typed. Other fields are allowed via extra=\"allow\". + """ -class MCPUIToolMetaTypedDict(TypedDict): - r"""UI metadata for tools that reference UI resources.""" + ai_mistral_turbine: NotRequired[Nullable[TurbineMetaTypedDict]] - resource_uri: NotRequired[Nullable[str]] - visibility: NotRequired[Nullable[List[Visibility]]] +class MCPServerCardMeta(BaseModel): + r"""Typed _meta for MCP server cards. -class MCPUIToolMeta(BaseModel): - r"""UI metadata for tools that reference UI resources.""" + Only the 'turbine' field is typed. Other fields are allowed via extra=\"allow\". + """ model_config = ConfigDict( populate_by_name=True, arbitrary_types_allowed=True, extra="allow" ) __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) - resource_uri: Annotated[ - OptionalNullable[str], pydantic.Field(alias="resourceUri") + ai_mistral_turbine: Annotated[ + OptionalNullable[TurbineMeta], pydantic.Field(alias="ai.mistral/turbine") ] = UNSET - visibility: OptionalNullable[List[Visibility]] = UNSET - @property def additional_properties(self): return self.__pydantic_extra__ @@ -56,8 +50,8 @@ def additional_properties(self, value): @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = set(["resourceUri", "visibility"]) - nullable_fields = set(["resourceUri", "visibility"]) + optional_fields = set(["ai.mistral/turbine"]) + nullable_fields = set(["ai.mistral/turbine"]) serialized = handler(self) m = {} @@ -84,6 +78,6 @@ def serialize_model(self, handler): try: - MCPUIToolMeta.model_rebuild() + MCPServerCardMeta.model_rebuild() except NameError: pass diff --git a/src/mistralai/client/models/mcpserverremote.py b/src/mistralai/client/models/mcpserverremote.py new file mode 100644 index 00000000..9099207c --- /dev/null +++ b/src/mistralai/client/models/mcpserverremote.py @@ -0,0 +1,96 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: b20e4512dbe2 + +from __future__ import annotations +from .mcpserverauthenticationrequirement import ( + MCPServerAuthenticationRequirement, + MCPServerAuthenticationRequirementTypedDict, +) +from .mcpserverremoteheader import MCPServerRemoteHeader, MCPServerRemoteHeaderTypedDict +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, + UnrecognizedStr, +) +import pydantic +from pydantic import model_serializer +from typing import List, Literal, Union +from typing_extensions import Annotated, NotRequired, TypedDict + + +MCPServerRemoteType = Union[ + Literal[ + "streamable-http", + "sse", + ], + UnrecognizedStr, +] +r"""Transport type""" + + +class MCPServerRemoteTypedDict(TypedDict): + r"""Remote transport endpoint (SEP-2127).""" + + type: MCPServerRemoteType + r"""Transport type""" + url: str + r"""Transport endpoint URL""" + supported_protocol_versions: NotRequired[Nullable[List[str]]] + headers: NotRequired[Nullable[List[MCPServerRemoteHeaderTypedDict]]] + authentication: NotRequired[Nullable[MCPServerAuthenticationRequirementTypedDict]] + + +class MCPServerRemote(BaseModel): + r"""Remote transport endpoint (SEP-2127).""" + + type: MCPServerRemoteType + r"""Transport type""" + + url: str + r"""Transport endpoint URL""" + + supported_protocol_versions: Annotated[ + OptionalNullable[List[str]], pydantic.Field(alias="supportedProtocolVersions") + ] = UNSET + + headers: OptionalNullable[List[MCPServerRemoteHeader]] = UNSET + + authentication: OptionalNullable[MCPServerAuthenticationRequirement] = UNSET + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set( + ["supportedProtocolVersions", "headers", "authentication"] + ) + nullable_fields = set( + ["supportedProtocolVersions", "headers", "authentication"] + ) + 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 + + +try: + MCPServerRemote.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/mcpserverremoteheader.py b/src/mistralai/client/models/mcpserverremoteheader.py new file mode 100644 index 00000000..efd1c1fd --- /dev/null +++ b/src/mistralai/client/models/mcpserverremoteheader.py @@ -0,0 +1,81 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: adaf8d89cbcb + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import model_serializer +from typing import List +from typing_extensions import Annotated, NotRequired, TypedDict + + +class MCPServerRemoteHeaderTypedDict(TypedDict): + r"""Header definition for a remote transport (SEP-2127).""" + + name: str + r"""Header name""" + description: str + r"""Human-readable description of the header""" + is_required: NotRequired[Nullable[bool]] + is_secret: NotRequired[Nullable[bool]] + default: NotRequired[Nullable[str]] + choices: NotRequired[Nullable[List[str]]] + + +class MCPServerRemoteHeader(BaseModel): + r"""Header definition for a remote transport (SEP-2127).""" + + name: str + r"""Header name""" + + description: str + r"""Human-readable description of the header""" + + is_required: Annotated[ + OptionalNullable[bool], pydantic.Field(alias="isRequired") + ] = UNSET + + is_secret: Annotated[OptionalNullable[bool], pydantic.Field(alias="isSecret")] = ( + UNSET + ) + + default: OptionalNullable[str] = UNSET + + choices: OptionalNullable[List[str]] = UNSET + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["isRequired", "isSecret", "default", "choices"]) + nullable_fields = set(["isRequired", "isSecret", "default", "choices"]) + 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 + + +try: + MCPServerRemoteHeader.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/mcpserverrepository.py b/src/mistralai/client/models/mcpserverrepository.py new file mode 100644 index 00000000..eb564992 --- /dev/null +++ b/src/mistralai/client/models/mcpserverrepository.py @@ -0,0 +1,60 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 431ce897e113 + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from pydantic import model_serializer +from typing_extensions import NotRequired, TypedDict + + +class MCPServerRepositoryTypedDict(TypedDict): + r"""Source repository information (SEP-2127).""" + + url: str + r"""Repository URL""" + source: str + r"""Source identifier (e.g. 'github')""" + subfolder: NotRequired[Nullable[str]] + + +class MCPServerRepository(BaseModel): + r"""Source repository information (SEP-2127).""" + + url: str + r"""Repository URL""" + + source: str + r"""Source identifier (e.g. 'github')""" + + subfolder: OptionalNullable[str] = UNSET + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["subfolder"]) + nullable_fields = set(["subfolder"]) + 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 diff --git a/src/mistralai/client/models/mcptoolmeta.py b/src/mistralai/client/models/mcptoolmeta.py index edbf39a9..ddd7771b 100644 --- a/src/mistralai/client/models/mcptoolmeta.py +++ b/src/mistralai/client/models/mcptoolmeta.py @@ -2,8 +2,9 @@ # @generated-id: 07cf1c0762c9 from __future__ import annotations -from .mcpuitoolmeta import MCPUIToolMeta, MCPUIToolMetaTypedDict -from .turbinetoolmeta import TurbineToolMeta, TurbineToolMetaTypedDict +from .mcpservericon import MCPServerIcon, MCPServerIconTypedDict +from .toolannotations import ToolAnnotations, ToolAnnotationsTypedDict +from .toolexecution import ToolExecution, ToolExecutionTypedDict from mistralai.client.types import ( BaseModel, Nullable, @@ -13,37 +14,50 @@ ) import pydantic from pydantic import ConfigDict, model_serializer -from typing import Any, Dict +from typing import Any, Dict, List from typing_extensions import Annotated, NotRequired, TypedDict class MCPToolMetaTypedDict(TypedDict): - r"""Typed _meta for MCP tools. - - Only the 'ui' field is typed. Other fields are allowed via extra=\"allow\". - """ - - ui: NotRequired[Nullable[MCPUIToolMetaTypedDict]] - ai_mistral_turbine: NotRequired[Nullable[TurbineToolMetaTypedDict]] + name: str + input_schema: Dict[str, Any] + title: NotRequired[Nullable[str]] + description: NotRequired[Nullable[str]] + output_schema: NotRequired[Nullable[Dict[str, Any]]] + icons: NotRequired[Nullable[List[MCPServerIconTypedDict]]] + annotations: NotRequired[Nullable[ToolAnnotationsTypedDict]] + meta: NotRequired[Nullable[MCPToolMetaTypedDict]] + execution: NotRequired[Nullable[ToolExecutionTypedDict]] class MCPToolMeta(BaseModel): - r"""Typed _meta for MCP tools. - - Only the 'ui' field is typed. Other fields are allowed via extra=\"allow\". - """ - model_config = ConfigDict( populate_by_name=True, arbitrary_types_allowed=True, extra="allow" ) __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) - ui: OptionalNullable[MCPUIToolMeta] = UNSET + name: str + + input_schema: Annotated[Dict[str, Any], pydantic.Field(alias="inputSchema")] + + title: OptionalNullable[str] = UNSET - ai_mistral_turbine: Annotated[ - OptionalNullable[TurbineToolMeta], pydantic.Field(alias="ai.mistral/turbine") + description: OptionalNullable[str] = UNSET + + output_schema: Annotated[ + OptionalNullable[Dict[str, Any]], pydantic.Field(alias="outputSchema") ] = UNSET + icons: OptionalNullable[List[MCPServerIcon]] = UNSET + + annotations: OptionalNullable[ToolAnnotations] = UNSET + + meta: Annotated[OptionalNullable[MCPToolMeta], pydantic.Field(alias="_meta")] = ( + UNSET + ) + + execution: OptionalNullable[ToolExecution] = UNSET + @property def additional_properties(self): return self.__pydantic_extra__ @@ -54,8 +68,28 @@ def additional_properties(self, value): @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = set(["ui", "ai.mistral/turbine"]) - nullable_fields = set(["ui", "ai.mistral/turbine"]) + optional_fields = set( + [ + "title", + "description", + "outputSchema", + "icons", + "annotations", + "_meta", + "execution", + ] + ) + nullable_fields = set( + [ + "title", + "description", + "outputSchema", + "icons", + "annotations", + "_meta", + "execution", + ] + ) serialized = handler(self) m = {} diff --git a/src/mistralai/client/models/partialscheduledefinition.py b/src/mistralai/client/models/partialscheduledefinition.py new file mode 100644 index 00000000..1120dd14 --- /dev/null +++ b/src/mistralai/client/models/partialscheduledefinition.py @@ -0,0 +1,139 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: ce1ded792ff5 + +from __future__ import annotations +from .schedulecalendar import ScheduleCalendar, ScheduleCalendarTypedDict +from .scheduleinterval import ScheduleInterval, ScheduleIntervalTypedDict +from .schedulepolicy import SchedulePolicy, SchedulePolicyTypedDict +from datetime import datetime +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from pydantic import model_serializer +from typing import Any, List, Optional +from typing_extensions import NotRequired, TypedDict + + +class PartialScheduleDefinitionTypedDict(TypedDict): + r"""Schedule definition for partial updates. + + All fields are optional (inherited from _ScheduleRequestBase). Only explicitly-set + fields are applied during an update; unset fields preserve the existing schedule values. + """ + + input: NotRequired[Any] + r"""Input to provide to the workflow when starting it.""" + calendars: NotRequired[List[ScheduleCalendarTypedDict]] + r"""Calendar-based specification of times.""" + intervals: NotRequired[List[ScheduleIntervalTypedDict]] + r"""Interval-based specification of times.""" + cron_expressions: NotRequired[List[str]] + r"""Cron-based specification of times.""" + skip: NotRequired[List[ScheduleCalendarTypedDict]] + r"""Set of calendar times to skip.""" + start_at: NotRequired[Nullable[datetime]] + r"""Time after which the first action may be run.""" + end_at: NotRequired[Nullable[datetime]] + r"""Time after which no more actions will be run.""" + jitter: NotRequired[Nullable[str]] + r"""Jitter to apply each action. + + An action's scheduled time will be incremented by a random value between 0 + and this value if present (but not past the next schedule). + + """ + time_zone_name: NotRequired[Nullable[str]] + r"""IANA time zone name, for example ``US/Central``.""" + policy: NotRequired[SchedulePolicyTypedDict] + max_executions: NotRequired[Nullable[int]] + r"""Maximum number of times this schedule will trigger a workflow execution. Once this limit is reached, no further executions are triggered automatically. null means unlimited.""" + + +class PartialScheduleDefinition(BaseModel): + r"""Schedule definition for partial updates. + + All fields are optional (inherited from _ScheduleRequestBase). Only explicitly-set + fields are applied during an update; unset fields preserve the existing schedule values. + """ + + input: Optional[Any] = None + r"""Input to provide to the workflow when starting it.""" + + calendars: Optional[List[ScheduleCalendar]] = None + r"""Calendar-based specification of times.""" + + intervals: Optional[List[ScheduleInterval]] = None + r"""Interval-based specification of times.""" + + cron_expressions: Optional[List[str]] = None + r"""Cron-based specification of times.""" + + skip: Optional[List[ScheduleCalendar]] = None + r"""Set of calendar times to skip.""" + + start_at: OptionalNullable[datetime] = UNSET + r"""Time after which the first action may be run.""" + + end_at: OptionalNullable[datetime] = UNSET + r"""Time after which no more actions will be run.""" + + jitter: OptionalNullable[str] = UNSET + r"""Jitter to apply each action. + + An action's scheduled time will be incremented by a random value between 0 + and this value if present (but not past the next schedule). + + """ + + time_zone_name: OptionalNullable[str] = UNSET + r"""IANA time zone name, for example ``US/Central``.""" + + policy: Optional[SchedulePolicy] = None + + max_executions: OptionalNullable[int] = UNSET + r"""Maximum number of times this schedule will trigger a workflow execution. Once this limit is reached, no further executions are triggered automatically. null means unlimited.""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set( + [ + "input", + "calendars", + "intervals", + "cron_expressions", + "skip", + "start_at", + "end_at", + "jitter", + "time_zone_name", + "policy", + "max_executions", + ] + ) + nullable_fields = set( + ["start_at", "end_at", "jitter", "time_zone_name", "max_executions"] + ) + 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 diff --git a/src/mistralai/client/models/processingstatus.py b/src/mistralai/client/models/processingstatus.py index 7e93308f..73308b46 100644 --- a/src/mistralai/client/models/processingstatus.py +++ b/src/mistralai/client/models/processingstatus.py @@ -4,7 +4,8 @@ from __future__ import annotations from .processstatus import ProcessStatus from mistralai.client.types import BaseModel -from typing_extensions import TypedDict +import pydantic +from typing_extensions import Annotated, TypedDict class ProcessingStatusTypedDict(TypedDict): @@ -18,4 +19,9 @@ class ProcessingStatus(BaseModel): process_status: ProcessStatus - processing_status: str + processing_status: Annotated[ + str, + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] diff --git a/src/mistralai/client/models/promptargument.py b/src/mistralai/client/models/promptargument.py new file mode 100644 index 00000000..1f73b59f --- /dev/null +++ b/src/mistralai/client/models/promptargument.py @@ -0,0 +1,74 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 52e5c885f761 + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import NotRequired, TypedDict + + +class PromptArgumentTypedDict(TypedDict): + r"""An argument for a prompt template.""" + + name: str + description: NotRequired[Nullable[str]] + required: NotRequired[Nullable[bool]] + + +class PromptArgument(BaseModel): + r"""An argument for a prompt template.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + name: str + + description: OptionalNullable[str] = UNSET + + required: OptionalNullable[bool] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["description", "required"]) + nullable_fields = set(["description", "required"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m diff --git a/src/mistralai/client/models/promptscapability.py b/src/mistralai/client/models/promptscapability.py new file mode 100644 index 00000000..f4ddf63e --- /dev/null +++ b/src/mistralai/client/models/promptscapability.py @@ -0,0 +1,76 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 15c552f53adf + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import Annotated, NotRequired, TypedDict + + +class PromptsCapabilityTypedDict(TypedDict): + r"""Capability for prompts operations.""" + + list_changed: NotRequired[Nullable[bool]] + + +class PromptsCapability(BaseModel): + r"""Capability for prompts operations.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + list_changed: Annotated[ + OptionalNullable[bool], pydantic.Field(alias="listChanged") + ] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["listChanged"]) + nullable_fields = set(["listChanged"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m + + +try: + PromptsCapability.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/publicconnectionconfig.py b/src/mistralai/client/models/publicconnectionconfig.py new file mode 100644 index 00000000..94fd6708 --- /dev/null +++ b/src/mistralai/client/models/publicconnectionconfig.py @@ -0,0 +1,57 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 03c2460e04ac + +from __future__ import annotations +from .connectionconfigtype import ConnectionConfigType +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from pydantic import model_serializer +from typing import Dict, Optional +from typing_extensions import NotRequired, TypedDict + + +class PublicConnectionConfigTypedDict(TypedDict): + type: NotRequired[ConnectionConfigType] + base_url: NotRequired[Nullable[str]] + headers: NotRequired[Nullable[Dict[str, str]]] + signed: NotRequired[Nullable[bool]] + + +class PublicConnectionConfig(BaseModel): + type: Optional[ConnectionConfigType] = None + + base_url: OptionalNullable[str] = UNSET + + headers: OptionalNullable[Dict[str, str]] = UNSET + + signed: OptionalNullable[bool] = UNSET + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["type", "base_url", "headers", "signed"]) + nullable_fields = set(["base_url", "headers", "signed"]) + 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 diff --git a/src/mistralai/client/models/resourcescapability.py b/src/mistralai/client/models/resourcescapability.py new file mode 100644 index 00000000..39bd1a0b --- /dev/null +++ b/src/mistralai/client/models/resourcescapability.py @@ -0,0 +1,79 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: d109cd5fe17d + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import Annotated, NotRequired, TypedDict + + +class ResourcesCapabilityTypedDict(TypedDict): + r"""Capability for resources operations.""" + + subscribe: NotRequired[Nullable[bool]] + list_changed: NotRequired[Nullable[bool]] + + +class ResourcesCapability(BaseModel): + r"""Capability for resources operations.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + subscribe: OptionalNullable[bool] = UNSET + + list_changed: Annotated[ + OptionalNullable[bool], pydantic.Field(alias="listChanged") + ] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["subscribe", "listChanged"]) + nullable_fields = set(["subscribe", "listChanged"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m + + +try: + ResourcesCapability.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/resourcetype.py b/src/mistralai/client/models/resourcetype.py new file mode 100644 index 00000000..435c917c --- /dev/null +++ b/src/mistralai/client/models/resourcetype.py @@ -0,0 +1,17 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 58cbbc423f90 + +from __future__ import annotations +from mistralai.client.types import UnrecognizedInt +from typing import Literal, Union + + +ResourceType = Union[ + Literal[ + 1, + 2, + 3, + 4, + ], + UnrecognizedInt, +] diff --git a/src/mistralai/client/models/rootscapability.py b/src/mistralai/client/models/rootscapability.py new file mode 100644 index 00000000..37b25d65 --- /dev/null +++ b/src/mistralai/client/models/rootscapability.py @@ -0,0 +1,76 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: f1514b6dd416 + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import Annotated, NotRequired, TypedDict + + +class RootsCapabilityTypedDict(TypedDict): + r"""Capability for root operations.""" + + list_changed: NotRequired[Nullable[bool]] + + +class RootsCapability(BaseModel): + r"""Capability for root operations.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + list_changed: Annotated[ + OptionalNullable[bool], pydantic.Field(alias="listChanged") + ] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["listChanged"]) + nullable_fields = set(["listChanged"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m + + +try: + RootsCapability.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/samplingcapability.py b/src/mistralai/client/models/samplingcapability.py new file mode 100644 index 00000000..46aa3be5 --- /dev/null +++ b/src/mistralai/client/models/samplingcapability.py @@ -0,0 +1,71 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 0a7af0cc3968 + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import NotRequired, TypedDict + + +class SamplingCapabilityTypedDict(TypedDict): + r"""Sampling capability structure, allowing fine-grained capability advertisement.""" + + context: NotRequired[Nullable[Dict[str, Any]]] + tools: NotRequired[Nullable[Dict[str, Any]]] + + +class SamplingCapability(BaseModel): + r"""Sampling capability structure, allowing fine-grained capability advertisement.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + context: OptionalNullable[Dict[str, Any]] = UNSET + + tools: OptionalNullable[Dict[str, Any]] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["context", "tools"]) + nullable_fields = set(["context", "tools"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m diff --git a/src/mistralai/client/models/scheduledefinition.py b/src/mistralai/client/models/scheduledefinition.py index 58102293..3c018552 100644 --- a/src/mistralai/client/models/scheduledefinition.py +++ b/src/mistralai/client/models/scheduledefinition.py @@ -51,10 +51,10 @@ class ScheduleDefinitionTypedDict(TypedDict): time_zone_name: NotRequired[Nullable[str]] r"""IANA time zone name, for example ``US/Central``.""" policy: NotRequired[SchedulePolicyTypedDict] - schedule_id: NotRequired[Nullable[str]] - r"""Unique identifier for the schedule.""" max_executions: NotRequired[Nullable[int]] r"""Maximum number of times this schedule will trigger a workflow execution. Once this limit is reached, no further executions are triggered automatically. null means unlimited.""" + schedule_id: NotRequired[Nullable[str]] + r"""Unique identifier for the schedule.""" class ScheduleDefinition(BaseModel): @@ -100,12 +100,12 @@ class ScheduleDefinition(BaseModel): policy: Optional[SchedulePolicy] = None - schedule_id: OptionalNullable[str] = UNSET - r"""Unique identifier for the schedule.""" - max_executions: OptionalNullable[int] = UNSET r"""Maximum number of times this schedule will trigger a workflow execution. Once this limit is reached, no further executions are triggered automatically. null means unlimited.""" + schedule_id: OptionalNullable[str] = UNSET + r"""Unique identifier for the schedule.""" + @model_serializer(mode="wrap") def serialize_model(self, handler): optional_fields = set( @@ -119,8 +119,8 @@ def serialize_model(self, handler): "jitter", "time_zone_name", "policy", - "schedule_id", "max_executions", + "schedule_id", ] ) nullable_fields = set( @@ -129,8 +129,8 @@ def serialize_model(self, handler): "end_at", "jitter", "time_zone_name", - "schedule_id", "max_executions", + "schedule_id", ] ) serialized = handler(self) diff --git a/src/mistralai/client/models/searchindexresponse.py b/src/mistralai/client/models/searchindexresponse.py new file mode 100644 index 00000000..0e62aa32 --- /dev/null +++ b/src/mistralai/client/models/searchindexresponse.py @@ -0,0 +1,72 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 054688d20a3b + +from __future__ import annotations +from .vespasearchindexinforesponse import ( + VespaSearchIndexInfoResponse, + VespaSearchIndexInfoResponseTypedDict, +) +from datetime import datetime +from mistralai.client.types import BaseModel, UnrecognizedStr +from pydantic import ConfigDict +from typing import Any, Literal, Union +from typing_extensions import TypedDict + + +SearchIndexResponseStatus = Union[ + Literal[ + "online", + "offline", + ], + UnrecognizedStr, +] + + +SearchIndexResponseIndexTypedDict = VespaSearchIndexInfoResponseTypedDict + + +class UnknownSearchIndexResponseIndex(BaseModel): + r"""A SearchIndexResponseIndex variant the SDK doesn't recognize. Preserves the raw payload.""" + + type: Literal["UNKNOWN"] = "UNKNOWN" + raw: Any + is_unknown: Literal[True] = True + + model_config = ConfigDict(frozen=True) + + +_SEARCH_INDEX_RESPONSE_INDEX_VARIANTS: dict[str, Any] = { + "vespa": VespaSearchIndexInfoResponse, +} + + +SearchIndexResponseIndex = VespaSearchIndexInfoResponse + + +class SearchIndexResponseTypedDict(TypedDict): + id: str + name: str + creator_id: str + document_count: int + status: SearchIndexResponseStatus + created_at: datetime + modified_at: datetime + index: SearchIndexResponseIndexTypedDict + + +class SearchIndexResponse(BaseModel): + id: str + + name: str + + creator_id: str + + document_count: int + + status: SearchIndexResponseStatus + + created_at: datetime + + modified_at: datetime + + index: SearchIndexResponseIndex diff --git a/src/mistralai/client/models/servercapabilities.py b/src/mistralai/client/models/servercapabilities.py new file mode 100644 index 00000000..ccfbf932 --- /dev/null +++ b/src/mistralai/client/models/servercapabilities.py @@ -0,0 +1,110 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 9e5832ea005a + +from __future__ import annotations +from .promptscapability import PromptsCapability, PromptsCapabilityTypedDict +from .resourcescapability import ResourcesCapability, ResourcesCapabilityTypedDict +from .servertaskscapability import ServerTasksCapability, ServerTasksCapabilityTypedDict +from .toolscapability import ToolsCapability, ToolsCapabilityTypedDict +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import NotRequired, TypedDict + + +class ServerCapabilitiesTypedDict(TypedDict): + r"""Capabilities that a server may support.""" + + experimental: NotRequired[Nullable[Dict[str, Dict[str, Any]]]] + logging: NotRequired[Nullable[Dict[str, Any]]] + prompts: NotRequired[Nullable[PromptsCapabilityTypedDict]] + resources: NotRequired[Nullable[ResourcesCapabilityTypedDict]] + tools: NotRequired[Nullable[ToolsCapabilityTypedDict]] + completions: NotRequired[Nullable[Dict[str, Any]]] + tasks: NotRequired[Nullable[ServerTasksCapabilityTypedDict]] + + +class ServerCapabilities(BaseModel): + r"""Capabilities that a server may support.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + experimental: OptionalNullable[Dict[str, Dict[str, Any]]] = UNSET + + logging: OptionalNullable[Dict[str, Any]] = UNSET + + prompts: OptionalNullable[PromptsCapability] = UNSET + + resources: OptionalNullable[ResourcesCapability] = UNSET + + tools: OptionalNullable[ToolsCapability] = UNSET + + completions: OptionalNullable[Dict[str, Any]] = UNSET + + tasks: OptionalNullable[ServerTasksCapability] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set( + [ + "experimental", + "logging", + "prompts", + "resources", + "tools", + "completions", + "tasks", + ] + ) + nullable_fields = set( + [ + "experimental", + "logging", + "prompts", + "resources", + "tools", + "completions", + "tasks", + ] + ) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m diff --git a/src/mistralai/client/models/turbinetoollocale.py b/src/mistralai/client/models/serverlocale.py similarity index 95% rename from src/mistralai/client/models/turbinetoollocale.py rename to src/mistralai/client/models/serverlocale.py index 42682ee1..1b73a749 100644 --- a/src/mistralai/client/models/turbinetoollocale.py +++ b/src/mistralai/client/models/serverlocale.py @@ -1,5 +1,5 @@ """Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" -# @generated-id: 2699936a7546 +# @generated-id: 5b70fcb88050 from __future__ import annotations from mistralai.client.types import ( @@ -14,7 +14,7 @@ from typing_extensions import NotRequired, TypedDict -class TurbineToolLocaleTypedDict(TypedDict): +class ServerLocaleTypedDict(TypedDict): name: NotRequired[Nullable[Dict[str, str]]] description: NotRequired[Nullable[Dict[str, str]]] usage_sentence: NotRequired[Nullable[Dict[str, str]]] @@ -22,7 +22,7 @@ class TurbineToolLocaleTypedDict(TypedDict): done_description: NotRequired[Nullable[Dict[str, str]]] -class TurbineToolLocale(BaseModel): +class ServerLocale(BaseModel): name: OptionalNullable[Dict[str, str]] = UNSET description: OptionalNullable[Dict[str, str]] = UNSET diff --git a/src/mistralai/client/models/servertaskscapability.py b/src/mistralai/client/models/servertaskscapability.py new file mode 100644 index 00000000..7d2c2927 --- /dev/null +++ b/src/mistralai/client/models/servertaskscapability.py @@ -0,0 +1,78 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: fff9567cb403 + +from __future__ import annotations +from .servertasksrequestscapability import ( + ServerTasksRequestsCapability, + ServerTasksRequestsCapabilityTypedDict, +) +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import NotRequired, TypedDict + + +class ServerTasksCapabilityTypedDict(TypedDict): + r"""Capability for server tasks operations.""" + + list: NotRequired[Nullable[Dict[str, Any]]] + cancel: NotRequired[Nullable[Dict[str, Any]]] + requests: NotRequired[Nullable[ServerTasksRequestsCapabilityTypedDict]] + + +class ServerTasksCapability(BaseModel): + r"""Capability for server tasks operations.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + list: OptionalNullable[Dict[str, Any]] = UNSET + + cancel: OptionalNullable[Dict[str, Any]] = UNSET + + requests: OptionalNullable[ServerTasksRequestsCapability] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["list", "cancel", "requests"]) + nullable_fields = set(["list", "cancel", "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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m diff --git a/src/mistralai/client/models/servertasksrequestscapability.py b/src/mistralai/client/models/servertasksrequestscapability.py new file mode 100644 index 00000000..2568507f --- /dev/null +++ b/src/mistralai/client/models/servertasksrequestscapability.py @@ -0,0 +1,69 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 23cc8415f619 + +from __future__ import annotations +from .taskstoolscapability import TasksToolsCapability, TasksToolsCapabilityTypedDict +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import NotRequired, TypedDict + + +class ServerTasksRequestsCapabilityTypedDict(TypedDict): + r"""Capability for tasks requests operations.""" + + tools: NotRequired[Nullable[TasksToolsCapabilityTypedDict]] + + +class ServerTasksRequestsCapability(BaseModel): + r"""Capability for tasks requests operations.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + tools: OptionalNullable[TasksToolsCapability] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["tools"]) + nullable_fields = set(["tools"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m diff --git a/src/mistralai/client/models/sharing.py b/src/mistralai/client/models/sharing.py index efa16203..4260f175 100644 --- a/src/mistralai/client/models/sharing.py +++ b/src/mistralai/client/models/sharing.py @@ -9,8 +9,9 @@ UNSET, UNSET_SENTINEL, ) +import pydantic from pydantic import model_serializer -from typing_extensions import NotRequired, TypedDict +from typing_extensions import Annotated, NotRequired, TypedDict class SharingTypedDict(TypedDict): @@ -25,7 +26,12 @@ class SharingTypedDict(TypedDict): class Sharing(BaseModel): library_id: str - org_id: str + org_id: Annotated[ + str, + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] role: str @@ -33,7 +39,12 @@ class Sharing(BaseModel): share_with_uuid: Nullable[str] - user_id: OptionalNullable[str] = UNSET + user_id: Annotated[ + OptionalNullable[str], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] = UNSET @model_serializer(mode="wrap") def serialize_model(self, handler): diff --git a/src/mistralai/client/models/sharingdelete.py b/src/mistralai/client/models/sharingdelete.py index 3472a506..67399831 100644 --- a/src/mistralai/client/models/sharingdelete.py +++ b/src/mistralai/client/models/sharingdelete.py @@ -10,8 +10,9 @@ UNSET, UNSET_SENTINEL, ) +import pydantic from pydantic import model_serializer -from typing_extensions import NotRequired, TypedDict +from typing_extensions import Annotated, NotRequired, TypedDict class SharingDeleteTypedDict(TypedDict): @@ -29,7 +30,12 @@ class SharingDelete(BaseModel): share_with_type: EntityType r"""The type of entity, used to share a library.""" - org_id: OptionalNullable[str] = UNSET + org_id: Annotated[ + OptionalNullable[str], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] = UNSET @model_serializer(mode="wrap") def serialize_model(self, handler): diff --git a/src/mistralai/client/models/sharingrequest.py b/src/mistralai/client/models/sharingrequest.py index 7c2d435c..94de31c1 100644 --- a/src/mistralai/client/models/sharingrequest.py +++ b/src/mistralai/client/models/sharingrequest.py @@ -11,8 +11,9 @@ UNSET, UNSET_SENTINEL, ) +import pydantic from pydantic import model_serializer -from typing_extensions import NotRequired, TypedDict +from typing_extensions import Annotated, NotRequired, TypedDict class SharingRequestTypedDict(TypedDict): @@ -33,7 +34,12 @@ class SharingRequest(BaseModel): share_with_type: EntityType r"""The type of entity, used to share a library.""" - org_id: OptionalNullable[str] = UNSET + org_id: Annotated[ + OptionalNullable[str], + pydantic.Field( + deprecated="warning: ** DEPRECATED ** - This will be removed in a future release, please migrate away from it as soon as possible." + ), + ] = UNSET @model_serializer(mode="wrap") def serialize_model(self, handler): diff --git a/src/mistralai/client/models/taskselicitationcapability.py b/src/mistralai/client/models/taskselicitationcapability.py new file mode 100644 index 00000000..768f36f1 --- /dev/null +++ b/src/mistralai/client/models/taskselicitationcapability.py @@ -0,0 +1,68 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 19504f19f5f3 + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import NotRequired, TypedDict + + +class TasksElicitationCapabilityTypedDict(TypedDict): + r"""Capability for tasks elicitation operations.""" + + create: NotRequired[Nullable[Dict[str, Any]]] + + +class TasksElicitationCapability(BaseModel): + r"""Capability for tasks elicitation operations.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + create: OptionalNullable[Dict[str, Any]] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["create"]) + nullable_fields = set(["create"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m diff --git a/src/mistralai/client/models/taskssamplingcapability.py b/src/mistralai/client/models/taskssamplingcapability.py new file mode 100644 index 00000000..e051fd75 --- /dev/null +++ b/src/mistralai/client/models/taskssamplingcapability.py @@ -0,0 +1,76 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: fe3e6aaee007 + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import Annotated, NotRequired, TypedDict + + +class TasksSamplingCapabilityTypedDict(TypedDict): + r"""Capability for tasks sampling operations.""" + + create_message: NotRequired[Nullable[Dict[str, Any]]] + + +class TasksSamplingCapability(BaseModel): + r"""Capability for tasks sampling operations.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + create_message: Annotated[ + OptionalNullable[Dict[str, Any]], pydantic.Field(alias="createMessage") + ] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["createMessage"]) + nullable_fields = set(["createMessage"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m + + +try: + TasksSamplingCapability.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/taskstoolscapability.py b/src/mistralai/client/models/taskstoolscapability.py new file mode 100644 index 00000000..88d799c1 --- /dev/null +++ b/src/mistralai/client/models/taskstoolscapability.py @@ -0,0 +1,68 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: ac9448f661ce + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import NotRequired, TypedDict + + +class TasksToolsCapabilityTypedDict(TypedDict): + r"""Capability for tasks tools operations.""" + + call: NotRequired[Nullable[Dict[str, Any]]] + + +class TasksToolsCapability(BaseModel): + r"""Capability for tasks tools operations.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + call: OptionalNullable[Dict[str, Any]] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["call"]) + nullable_fields = set(["call"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m diff --git a/src/mistralai/client/models/toolexecutionconfiguration.py b/src/mistralai/client/models/toolexecutionconfiguration.py new file mode 100644 index 00000000..ce65ad31 --- /dev/null +++ b/src/mistralai/client/models/toolexecutionconfiguration.py @@ -0,0 +1,84 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 1c9369616b21 + +from __future__ import annotations +from .logicalexpression import LogicalExpression, LogicalExpressionTypedDict +from .toolproperties import ToolProperties, ToolPropertiesTypedDict +from mistralai.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 + + +RequiresConfirmationTypedDict = TypeAliasType( + "RequiresConfirmationTypedDict", + Union[ToolPropertiesTypedDict, LogicalExpressionTypedDict, List[str]], +) + + +RequiresConfirmation = TypeAliasType( + "RequiresConfirmation", Union[ToolProperties, LogicalExpression, List[str]] +) + + +SkipConfirmationTypedDict = TypeAliasType( + "SkipConfirmationTypedDict", + Union[ToolPropertiesTypedDict, LogicalExpressionTypedDict, List[str]], +) + + +SkipConfirmation = TypeAliasType( + "SkipConfirmation", Union[ToolProperties, LogicalExpression, List[str]] +) + + +class ToolExecutionConfigurationTypedDict(TypedDict): + requires_confirmation: NotRequired[Nullable[RequiresConfirmationTypedDict]] + skip_confirmation: NotRequired[Nullable[SkipConfirmationTypedDict]] + include: NotRequired[Nullable[List[str]]] + exclude: NotRequired[Nullable[List[str]]] + + +class ToolExecutionConfiguration(BaseModel): + requires_confirmation: OptionalNullable[RequiresConfirmation] = UNSET + + skip_confirmation: OptionalNullable[SkipConfirmation] = UNSET + + include: OptionalNullable[List[str]] = UNSET + + exclude: OptionalNullable[List[str]] = UNSET + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set( + ["requires_confirmation", "skip_confirmation", "include", "exclude"] + ) + nullable_fields = set( + ["requires_confirmation", "skip_confirmation", "include", "exclude"] + ) + 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 diff --git a/src/mistralai/client/models/toolproperties.py b/src/mistralai/client/models/toolproperties.py new file mode 100644 index 00000000..d3bf9789 --- /dev/null +++ b/src/mistralai/client/models/toolproperties.py @@ -0,0 +1,29 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 3a33561f76fc + +from __future__ import annotations +from mistralai.client.types import BaseModel, Nullable, UNSET_SENTINEL +from pydantic import model_serializer +from typing_extensions import TypedDict + + +class ToolPropertiesTypedDict(TypedDict): + read_only: Nullable[bool] + + +class ToolProperties(BaseModel): + read_only: Nullable[bool] + + @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 diff --git a/src/mistralai/client/models/toolscapability.py b/src/mistralai/client/models/toolscapability.py new file mode 100644 index 00000000..94e5ddc8 --- /dev/null +++ b/src/mistralai/client/models/toolscapability.py @@ -0,0 +1,76 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 2feda23ea584 + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +import pydantic +from pydantic import ConfigDict, model_serializer +from typing import Any, Dict +from typing_extensions import Annotated, NotRequired, TypedDict + + +class ToolsCapabilityTypedDict(TypedDict): + r"""Capability for tools operations.""" + + list_changed: NotRequired[Nullable[bool]] + + +class ToolsCapability(BaseModel): + r"""Capability for tools operations.""" + + model_config = ConfigDict( + populate_by_name=True, arbitrary_types_allowed=True, extra="allow" + ) + __pydantic_extra__: Dict[str, Any] = pydantic.Field(init=False) + + list_changed: Annotated[ + OptionalNullable[bool], pydantic.Field(alias="listChanged") + ] = UNSET + + @property + def additional_properties(self): + return self.__pydantic_extra__ + + @additional_properties.setter + def additional_properties(self, value): + self.__pydantic_extra__ = value # pyright: ignore[reportIncompatibleVariableOverride] + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["listChanged"]) + nullable_fields = set(["listChanged"]) + 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)) + serialized.pop(k, serialized.pop(n, None)) + 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 + for k, v in serialized.items(): + m[k] = v + + return m + + +try: + ToolsCapability.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/turbinemeta.py b/src/mistralai/client/models/turbinemeta.py new file mode 100644 index 00000000..5084c05f --- /dev/null +++ b/src/mistralai/client/models/turbinemeta.py @@ -0,0 +1,50 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 084d588caa1e + +from __future__ import annotations +from .serverlocale import ServerLocale, ServerLocaleTypedDict +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from pydantic import model_serializer +from typing_extensions import NotRequired, TypedDict + + +class TurbineMetaTypedDict(TypedDict): + system_prompt_name: NotRequired[Nullable[str]] + locale: NotRequired[Nullable[ServerLocaleTypedDict]] + + +class TurbineMeta(BaseModel): + system_prompt_name: OptionalNullable[str] = UNSET + + locale: OptionalNullable[ServerLocale] = UNSET + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["system_prompt_name", "locale"]) + nullable_fields = set(["system_prompt_name", "locale"]) + 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 diff --git a/src/mistralai/client/models/update_schedule_v1_workflows_schedules_schedule_id_patchop.py b/src/mistralai/client/models/update_schedule_v1_workflows_schedules_schedule_id_patchop.py new file mode 100644 index 00000000..5e3a1be4 --- /dev/null +++ b/src/mistralai/client/models/update_schedule_v1_workflows_schedules_schedule_id_patchop.py @@ -0,0 +1,27 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 6aaa918af7f4 + +from __future__ import annotations +from .workflowscheduleupdaterequest import ( + WorkflowScheduleUpdateRequest, + WorkflowScheduleUpdateRequestTypedDict, +) +from mistralai.client.types import BaseModel +from mistralai.client.utils import FieldMetadata, PathParamMetadata, RequestMetadata +from typing_extensions import Annotated, TypedDict + + +class UpdateScheduleV1WorkflowsSchedulesScheduleIDPatchRequestTypedDict(TypedDict): + schedule_id: str + workflow_schedule_update_request: WorkflowScheduleUpdateRequestTypedDict + + +class UpdateScheduleV1WorkflowsSchedulesScheduleIDPatchRequest(BaseModel): + schedule_id: Annotated[ + str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False)) + ] + + workflow_schedule_update_request: Annotated[ + WorkflowScheduleUpdateRequest, + FieldMetadata(request=RequestMetadata(media_type="application/json")), + ] diff --git a/src/mistralai/client/models/updateconnectorrequest.py b/src/mistralai/client/models/updateconnectorrequest.py index 145091d4..81f09ea9 100644 --- a/src/mistralai/client/models/updateconnectorrequest.py +++ b/src/mistralai/client/models/updateconnectorrequest.py @@ -3,6 +3,7 @@ from __future__ import annotations from .authdata import AuthData, AuthDataTypedDict +from .connectorprotocol import ConnectorProtocol from mistralai.client.types import ( BaseModel, Nullable, @@ -26,6 +27,8 @@ class UpdateConnectorRequestTypedDict(TypedDict): r"""The optional url of the icon you want to associate to the connector.""" system_prompt: NotRequired[Nullable[str]] r"""Optional system prompt for the connector.""" + protocol: NotRequired[Nullable[ConnectorProtocol]] + r"""Protocol of the connector.""" connection_config: NotRequired[Nullable[Dict[str, Any]]] r"""Optional new connection config.""" connection_secrets: NotRequired[Nullable[Dict[str, Any]]] @@ -54,6 +57,9 @@ class UpdateConnectorRequest(BaseModel): system_prompt: OptionalNullable[str] = UNSET r"""Optional system prompt for the connector.""" + protocol: OptionalNullable[ConnectorProtocol] = UNSET + r"""Protocol of the connector.""" + connection_config: OptionalNullable[Dict[str, Any]] = UNSET r"""Optional new connection config.""" @@ -78,6 +84,7 @@ def serialize_model(self, handler): "description", "icon_url", "system_prompt", + "protocol", "connection_config", "connection_secrets", "server", @@ -92,6 +99,7 @@ def serialize_model(self, handler): "description", "icon_url", "system_prompt", + "protocol", "connection_config", "connection_secrets", "server", diff --git a/src/mistralai/client/models/updatedocumentrequest.py b/src/mistralai/client/models/updatedocumentrequest.py index 5f67ea69..07c6f5e3 100644 --- a/src/mistralai/client/models/updatedocumentrequest.py +++ b/src/mistralai/client/models/updatedocumentrequest.py @@ -34,6 +34,8 @@ class UpdateDocumentRequestTypedDict(TypedDict): name: NotRequired[str] attributes: NotRequired[Nullable[Dict[str, AttributesTypedDict]]] + expires_at: NotRequired[Nullable[datetime]] + r"""If set, the document will be automatically deleted after this date.""" class UpdateDocumentRequest(BaseModel): @@ -41,10 +43,13 @@ class UpdateDocumentRequest(BaseModel): attributes: OptionalNullable[Dict[str, Attributes]] = UNSET + expires_at: OptionalNullable[datetime] = UNSET + r"""If set, the document will be automatically deleted after this date.""" + @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = set(["name", "attributes"]) - nullable_fields = set(["attributes"]) + optional_fields = set(["name", "attributes", "expires_at"]) + nullable_fields = set(["attributes", "expires_at"]) serialized = handler(self) m = {} diff --git a/src/mistralai/client/models/vespaschemaresponse.py b/src/mistralai/client/models/vespaschemaresponse.py new file mode 100644 index 00000000..440967d1 --- /dev/null +++ b/src/mistralai/client/models/vespaschemaresponse.py @@ -0,0 +1,32 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: fbab188e672e + +from __future__ import annotations +from mistralai.client.types import BaseModel, Nullable, UNSET_SENTINEL +from pydantic import model_serializer +from typing_extensions import TypedDict + + +class VespaSchemaResponseTypedDict(TypedDict): + name: str + document_count: Nullable[int] + + +class VespaSchemaResponse(BaseModel): + name: str + + document_count: Nullable[int] + + @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 diff --git a/src/mistralai/client/models/vespasearchindexinforesponse.py b/src/mistralai/client/models/vespasearchindexinforesponse.py new file mode 100644 index 00000000..a3cce354 --- /dev/null +++ b/src/mistralai/client/models/vespasearchindexinforesponse.py @@ -0,0 +1,40 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: ee7484f75a7c + +from __future__ import annotations +from .vespaschemaresponse import VespaSchemaResponse, VespaSchemaResponseTypedDict +from mistralai.client.types import BaseModel +from mistralai.client.utils import validate_const +import pydantic +from pydantic.functional_validators import AfterValidator +from typing import List, Literal +from typing_extensions import Annotated, TypedDict + + +class VespaSearchIndexInfoResponseTypedDict(TypedDict): + k8s_cluster: str + k8s_namespace: str + vespa_instance_name: str + schemas: List[VespaSchemaResponseTypedDict] + type: Literal["vespa"] + + +class VespaSearchIndexInfoResponse(BaseModel): + k8s_cluster: str + + k8s_namespace: str + + vespa_instance_name: str + + schemas: List[VespaSchemaResponse] + + type: Annotated[ + Annotated[Literal["vespa"], AfterValidator(validate_const("vespa"))], + pydantic.Field(alias="type"), + ] = "vespa" + + +try: + VespaSearchIndexInfoResponse.model_rebuild() +except NameError: + pass diff --git a/src/mistralai/client/models/voiceappearance.py b/src/mistralai/client/models/voiceappearance.py new file mode 100644 index 00000000..a9d4f2a8 --- /dev/null +++ b/src/mistralai/client/models/voiceappearance.py @@ -0,0 +1,59 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 945a81bc2582 + +from __future__ import annotations +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from pydantic import model_serializer +from typing_extensions import NotRequired, TypedDict + + +class VoiceAppearanceTypedDict(TypedDict): + skin_color: NotRequired[Nullable[str]] + hair_color: NotRequired[Nullable[str]] + background_color: NotRequired[Nullable[str]] + avatar_id: NotRequired[Nullable[str]] + + +class VoiceAppearance(BaseModel): + skin_color: OptionalNullable[str] = UNSET + + hair_color: OptionalNullable[str] = UNSET + + background_color: OptionalNullable[str] = UNSET + + avatar_id: OptionalNullable[str] = UNSET + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set( + ["skin_color", "hair_color", "background_color", "avatar_id"] + ) + nullable_fields = set( + ["skin_color", "hair_color", "background_color", "avatar_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)) + 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 diff --git a/src/mistralai/client/models/voicecreaterequest.py b/src/mistralai/client/models/voicecreaterequest.py index 99df178d..ec94523f 100644 --- a/src/mistralai/client/models/voicecreaterequest.py +++ b/src/mistralai/client/models/voicecreaterequest.py @@ -2,6 +2,7 @@ # @generated-id: 9a1752117dec from __future__ import annotations +from .voiceappearance import VoiceAppearance, VoiceAppearanceTypedDict from mistralai.client.types import ( BaseModel, Nullable, @@ -26,6 +27,8 @@ class VoiceCreateRequestTypedDict(TypedDict): age: NotRequired[Nullable[int]] tags: NotRequired[Nullable[List[str]]] color: NotRequired[Nullable[str]] + description: NotRequired[Nullable[str]] + appearance: NotRequired[Nullable[VoiceAppearanceTypedDict]] retention_notice: NotRequired[int] sample_filename: NotRequired[Nullable[str]] r"""Original filename for extension detection""" @@ -51,6 +54,10 @@ class VoiceCreateRequest(BaseModel): color: OptionalNullable[str] = UNSET + description: OptionalNullable[str] = UNSET + + appearance: OptionalNullable[VoiceAppearance] = UNSET + retention_notice: Optional[int] = 30 sample_filename: OptionalNullable[str] = UNSET @@ -66,12 +73,23 @@ def serialize_model(self, handler): "age", "tags", "color", + "description", + "appearance", "retention_notice", "sample_filename", ] ) nullable_fields = set( - ["slug", "gender", "age", "tags", "color", "sample_filename"] + [ + "slug", + "gender", + "age", + "tags", + "color", + "description", + "appearance", + "sample_filename", + ] ) serialized = handler(self) m = {} diff --git a/src/mistralai/client/models/voiceresponse.py b/src/mistralai/client/models/voiceresponse.py index 6fa3987b..818bd257 100644 --- a/src/mistralai/client/models/voiceresponse.py +++ b/src/mistralai/client/models/voiceresponse.py @@ -2,6 +2,7 @@ # @generated-id: 24138e419fae from __future__ import annotations +from .voiceappearance import VoiceAppearance, VoiceAppearanceTypedDict from datetime import datetime from mistralai.client.types import ( BaseModel, @@ -28,6 +29,8 @@ class VoiceResponseTypedDict(TypedDict): age: NotRequired[Nullable[int]] tags: NotRequired[Nullable[List[str]]] color: NotRequired[Nullable[str]] + description: NotRequired[Nullable[str]] + appearance: NotRequired[Nullable[VoiceAppearanceTypedDict]] retention_notice: NotRequired[int] @@ -54,14 +57,39 @@ class VoiceResponse(BaseModel): color: OptionalNullable[str] = UNSET + description: OptionalNullable[str] = UNSET + + appearance: OptionalNullable[VoiceAppearance] = UNSET + retention_notice: Optional[int] = 30 @model_serializer(mode="wrap") def serialize_model(self, handler): optional_fields = set( - ["slug", "languages", "gender", "age", "tags", "color", "retention_notice"] + [ + "slug", + "languages", + "gender", + "age", + "tags", + "color", + "description", + "appearance", + "retention_notice", + ] + ) + nullable_fields = set( + [ + "slug", + "gender", + "age", + "tags", + "color", + "description", + "appearance", + "user_id", + ] ) - nullable_fields = set(["slug", "gender", "age", "tags", "color", "user_id"]) serialized = handler(self) m = {} diff --git a/src/mistralai/client/models/voiceupdaterequest.py b/src/mistralai/client/models/voiceupdaterequest.py index 717316b0..4239d016 100644 --- a/src/mistralai/client/models/voiceupdaterequest.py +++ b/src/mistralai/client/models/voiceupdaterequest.py @@ -2,6 +2,7 @@ # @generated-id: 798f8ff225de from __future__ import annotations +from .voiceappearance import VoiceAppearance, VoiceAppearanceTypedDict from mistralai.client.types import ( BaseModel, Nullable, @@ -22,6 +23,8 @@ class VoiceUpdateRequestTypedDict(TypedDict): gender: NotRequired[Nullable[str]] age: NotRequired[Nullable[int]] tags: NotRequired[Nullable[List[str]]] + description: NotRequired[Nullable[str]] + appearance: NotRequired[Nullable[VoiceAppearanceTypedDict]] class VoiceUpdateRequest(BaseModel): @@ -37,10 +40,18 @@ class VoiceUpdateRequest(BaseModel): tags: OptionalNullable[List[str]] = UNSET + description: OptionalNullable[str] = UNSET + + appearance: OptionalNullable[VoiceAppearance] = UNSET + @model_serializer(mode="wrap") def serialize_model(self, handler): - optional_fields = set(["name", "languages", "gender", "age", "tags"]) - nullable_fields = set(["name", "languages", "gender", "age", "tags"]) + optional_fields = set( + ["name", "languages", "gender", "age", "tags", "description", "appearance"] + ) + nullable_fields = set( + ["name", "languages", "gender", "age", "tags", "description", "appearance"] + ) serialized = handler(self) m = {} diff --git a/src/mistralai/client/models/workflowbulkarchiverequest.py b/src/mistralai/client/models/workflowbulkarchiverequest.py new file mode 100644 index 00000000..fb208919 --- /dev/null +++ b/src/mistralai/client/models/workflowbulkarchiverequest.py @@ -0,0 +1,17 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 0e0bf7feeede + +from __future__ import annotations +from mistralai.client.types import BaseModel +from typing import List +from typing_extensions import TypedDict + + +class WorkflowBulkArchiveRequestTypedDict(TypedDict): + workflow_ids: List[str] + r"""List of workflow IDs to archive""" + + +class WorkflowBulkArchiveRequest(BaseModel): + workflow_ids: List[str] + r"""List of workflow IDs to archive""" diff --git a/src/mistralai/client/models/workflowbulkarchiveresponse.py b/src/mistralai/client/models/workflowbulkarchiveresponse.py new file mode 100644 index 00000000..506724b3 --- /dev/null +++ b/src/mistralai/client/models/workflowbulkarchiveresponse.py @@ -0,0 +1,41 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 132f69064b86 + +from __future__ import annotations +from .workflow import Workflow, WorkflowTypedDict +from .workflowbulkerror import WorkflowBulkError, WorkflowBulkErrorTypedDict +from mistralai.client.types import BaseModel, UNSET_SENTINEL +from pydantic import model_serializer +from typing import List, Optional +from typing_extensions import NotRequired, TypedDict + + +class WorkflowBulkArchiveResponseTypedDict(TypedDict): + archived: List[WorkflowTypedDict] + r"""Workflows that were successfully archived or were already archived""" + errored: NotRequired[List[WorkflowBulkErrorTypedDict]] + r"""Workflows that could not be archived and the corresponding error messages""" + + +class WorkflowBulkArchiveResponse(BaseModel): + archived: List[Workflow] + r"""Workflows that were successfully archived or were already archived""" + + errored: Optional[List[WorkflowBulkError]] = None + r"""Workflows that could not be archived and the corresponding error messages""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["errored"]) + 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/mistralai/client/models/workflowbulkerror.py b/src/mistralai/client/models/workflowbulkerror.py new file mode 100644 index 00000000..076c938a --- /dev/null +++ b/src/mistralai/client/models/workflowbulkerror.py @@ -0,0 +1,59 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 61b9b62c7fd6 + +from __future__ import annotations +from .workflow import Workflow, WorkflowTypedDict +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from pydantic import model_serializer +from typing_extensions import NotRequired, TypedDict + + +class WorkflowBulkErrorTypedDict(TypedDict): + workflow_id: str + r"""The requested workflow ID""" + message: str + r"""Error message describing why the operation failed""" + workflow: NotRequired[Nullable[WorkflowTypedDict]] + r"""The workflow, if found""" + + +class WorkflowBulkError(BaseModel): + workflow_id: str + r"""The requested workflow ID""" + + message: str + r"""Error message describing why the operation failed""" + + workflow: OptionalNullable[Workflow] = UNSET + r"""The workflow, if found""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["workflow"]) + nullable_fields = set(["workflow"]) + 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 diff --git a/src/mistralai/client/models/workflowbulkunarchiverequest.py b/src/mistralai/client/models/workflowbulkunarchiverequest.py new file mode 100644 index 00000000..6ffecd91 --- /dev/null +++ b/src/mistralai/client/models/workflowbulkunarchiverequest.py @@ -0,0 +1,17 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: b04414883bed + +from __future__ import annotations +from mistralai.client.types import BaseModel +from typing import List +from typing_extensions import TypedDict + + +class WorkflowBulkUnarchiveRequestTypedDict(TypedDict): + workflow_ids: List[str] + r"""List of workflow IDs to unarchive""" + + +class WorkflowBulkUnarchiveRequest(BaseModel): + workflow_ids: List[str] + r"""List of workflow IDs to unarchive""" diff --git a/src/mistralai/client/models/workflowbulkunarchiveresponse.py b/src/mistralai/client/models/workflowbulkunarchiveresponse.py new file mode 100644 index 00000000..f2ab3727 --- /dev/null +++ b/src/mistralai/client/models/workflowbulkunarchiveresponse.py @@ -0,0 +1,41 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 34554c6df2e3 + +from __future__ import annotations +from .workflow import Workflow, WorkflowTypedDict +from .workflowbulkerror import WorkflowBulkError, WorkflowBulkErrorTypedDict +from mistralai.client.types import BaseModel, UNSET_SENTINEL +from pydantic import model_serializer +from typing import List, Optional +from typing_extensions import NotRequired, TypedDict + + +class WorkflowBulkUnarchiveResponseTypedDict(TypedDict): + unarchived: List[WorkflowTypedDict] + r"""Workflows that were successfully unarchived or were already unarchived""" + errored: NotRequired[List[WorkflowBulkErrorTypedDict]] + r"""Workflows that could not be unarchived and the corresponding error messages""" + + +class WorkflowBulkUnarchiveResponse(BaseModel): + unarchived: List[Workflow] + r"""Workflows that were successfully unarchived or were already unarchived""" + + errored: Optional[List[WorkflowBulkError]] = None + r"""Workflows that could not be unarchived and the corresponding error messages""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["errored"]) + 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/mistralai/client/models/workflowschedulelistresponse.py b/src/mistralai/client/models/workflowschedulelistresponse.py index 3c9eb3d7..21341eca 100644 --- a/src/mistralai/client/models/workflowschedulelistresponse.py +++ b/src/mistralai/client/models/workflowschedulelistresponse.py @@ -6,16 +6,53 @@ ScheduleDefinitionOutput, ScheduleDefinitionOutputTypedDict, ) -from mistralai.client.types import BaseModel +from mistralai.client.types import ( + BaseModel, + Nullable, + OptionalNullable, + UNSET, + UNSET_SENTINEL, +) +from pydantic import model_serializer from typing import List -from typing_extensions import TypedDict +from typing_extensions import NotRequired, TypedDict class WorkflowScheduleListResponseTypedDict(TypedDict): schedules: List[ScheduleDefinitionOutputTypedDict] r"""A list of workflow schedules""" + next_page_token: NotRequired[Nullable[str]] + r"""Token for the next page of results""" class WorkflowScheduleListResponse(BaseModel): schedules: List[ScheduleDefinitionOutput] r"""A list of workflow schedules""" + + next_page_token: OptionalNullable[str] = UNSET + r"""Token for the next page of results""" + + @model_serializer(mode="wrap") + def serialize_model(self, handler): + optional_fields = set(["next_page_token"]) + nullable_fields = set(["next_page_token"]) + 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 diff --git a/src/mistralai/client/models/workflowscheduleupdaterequest.py b/src/mistralai/client/models/workflowscheduleupdaterequest.py new file mode 100644 index 00000000..b43dc96f --- /dev/null +++ b/src/mistralai/client/models/workflowscheduleupdaterequest.py @@ -0,0 +1,28 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: 72ca0f5e6c08 + +from __future__ import annotations +from .partialscheduledefinition import ( + PartialScheduleDefinition, + PartialScheduleDefinitionTypedDict, +) +from mistralai.client.types import BaseModel +from typing_extensions import TypedDict + + +class WorkflowScheduleUpdateRequestTypedDict(TypedDict): + schedule: PartialScheduleDefinitionTypedDict + r"""Schedule definition for partial updates. + + All fields are optional (inherited from _ScheduleRequestBase). Only explicitly-set + fields are applied during an update; unset fields preserve the existing schedule values. + """ + + +class WorkflowScheduleUpdateRequest(BaseModel): + schedule: PartialScheduleDefinition + r"""Schedule definition for partial updates. + + All fields are optional (inherited from _ScheduleRequestBase). Only explicitly-set + fields are applied during an update; unset fields preserve the existing schedule values. + """ diff --git a/src/mistralai/client/models_.py b/src/mistralai/client/models_.py index 2a00325f..6263ead9 100644 --- a/src/mistralai/client/models_.py +++ b/src/mistralai/client/models_.py @@ -88,7 +88,7 @@ def list( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -184,7 +184,7 @@ async def list_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -277,7 +277,7 @@ def retrieve( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -372,7 +372,7 @@ async def retrieve_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -467,7 +467,7 @@ def delete( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -560,7 +560,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -668,7 +668,7 @@ def update( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -772,7 +772,7 @@ async def update_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -861,7 +861,7 @@ def archive( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -948,7 +948,7 @@ async def archive_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1035,7 +1035,7 @@ def unarchive( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1122,7 +1122,7 @@ async def unarchive_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/ocr.py b/src/mistralai/client/ocr.py index c290b1bb..e0bc4e0e 100644 --- a/src/mistralai/client/ocr.py +++ b/src/mistralai/client/ocr.py @@ -132,7 +132,7 @@ def process( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -272,7 +272,7 @@ async def process_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/rag.py b/src/mistralai/client/rag.py index 091b0270..934b2374 100644 --- a/src/mistralai/client/rag.py +++ b/src/mistralai/client/rag.py @@ -6,11 +6,13 @@ from mistralai.client.ingestion_pipeline_configurations import ( IngestionPipelineConfigurations, ) +from mistralai.client.search_indexes import SearchIndexes from typing import Optional class Rag(BaseSDK): ingestion_pipeline_configurations: IngestionPipelineConfigurations + search_indexes: SearchIndexes def __init__( self, sdk_config: SDKConfiguration, parent_ref: Optional[object] = None @@ -23,3 +25,6 @@ def _init_sdks(self): self.ingestion_pipeline_configurations = IngestionPipelineConfigurations( self.sdk_configuration, parent_ref=self.parent_ref ) + self.search_indexes = SearchIndexes( + self.sdk_configuration, parent_ref=self.parent_ref + ) diff --git a/src/mistralai/client/records.py b/src/mistralai/client/records.py index 2ac04c2f..5a4c3c84 100644 --- a/src/mistralai/client/records.py +++ b/src/mistralai/client/records.py @@ -81,7 +81,7 @@ def fetch( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -174,7 +174,7 @@ async def fetch_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -267,7 +267,7 @@ def delete( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -360,7 +360,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -456,7 +456,7 @@ def bulk_delete( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -552,7 +552,7 @@ async def bulk_delete_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -661,7 +661,7 @@ def judge( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -770,7 +770,7 @@ async def judge_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -875,7 +875,7 @@ def update_payload( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -980,7 +980,7 @@ async def update_payload_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1085,7 +1085,7 @@ def update_properties( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1190,7 +1190,7 @@ async def update_properties_async( ), ), request=req, - error_status_codes=["400", "404", "408", "409", "422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/runs.py b/src/mistralai/client/runs.py index d1a242fb..01507e33 100644 --- a/src/mistralai/client/runs.py +++ b/src/mistralai/client/runs.py @@ -102,7 +102,7 @@ def list_runs( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -120,8 +120,8 @@ def next_func() -> Optional[models.ListRunsV1WorkflowsRunsGetResponse]: results = JSONPath("$.executions").parse(body) if len(results) == 0 or len(results[0]) == 0: return None - limit = request.page_size if isinstance(request.page_size, int) else 50 - if len(results[0]) < limit: + limit_ = request.page_size if isinstance(request.page_size, int) else 50 + if len(results[0]) < limit_: return None return self.list_runs( @@ -249,7 +249,7 @@ async def list_runs_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -272,8 +272,8 @@ async def empty_result(): results = JSONPath("$.executions").parse(body) if len(results) == 0 or len(results[0]) == 0: return empty_result() - limit = request.page_size if isinstance(request.page_size, int) else 50 - if len(results[0]) < limit: + limit_ = request.page_size if isinstance(request.page_size, int) else 50 + if len(results[0]) < limit_: return empty_result() return self.list_runs_async( @@ -381,7 +381,7 @@ def get_run( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -472,7 +472,7 @@ async def get_run_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -566,7 +566,7 @@ def get_run_history( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -660,7 +660,7 @@ async def get_run_history_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/schedules.py b/src/mistralai/client/schedules.py index 9b013acd..c56e4973 100644 --- a/src/mistralai/client/schedules.py +++ b/src/mistralai/client/schedules.py @@ -2,25 +2,38 @@ # @generated-id: d3b4fe452390 from .basesdk import BaseSDK +from jsonpath import JSONPath from mistralai.client import errors, models, utils from mistralai.client._hooks import HookContext from mistralai.client.types import OptionalNullable, UNSET from mistralai.client.utils import get_security_from_env from mistralai.client.utils.unmarshal_json_response import unmarshal_json_response -from typing import Any, Mapping, Optional, Union +from typing import Any, Awaitable, Dict, List, Mapping, Optional, Union class Schedules(BaseSDK): def get_schedules( self, *, + workflow_name: OptionalNullable[str] = UNSET, + user_id: OptionalNullable[str] = UNSET, + status: OptionalNullable[ + models.GetSchedulesV1WorkflowsSchedulesGetStatus + ] = UNSET, + page_size: OptionalNullable[int] = UNSET, + next_page_token: OptionalNullable[str] = UNSET, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, http_headers: Optional[Mapping[str, str]] = None, - ) -> models.WorkflowScheduleListResponse: + ) -> Optional[models.GetSchedulesV1WorkflowsSchedulesGetResponse]: r"""Get Schedules + :param workflow_name: Filter by workflow name + :param user_id: Filter by user ID. Pass 'current' to resolve to the authenticated user's ID. + :param status: Filter by schedule status: 'active' or 'paused' + :param page_size: Number of items per page. Omitting this parameter fetches all results at once (deprecated — pass page_size to use pagination). + :param next_page_token: Token for the next page of results :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 @@ -38,12 +51,21 @@ def get_schedules( base_url = server_url else: base_url = self._get_url(base_url, url_variables) + + request = models.GetSchedulesV1WorkflowsSchedulesGetRequest( + workflow_name=workflow_name, + user_id=user_id, + status=status, + page_size=page_size, + next_page_token=next_page_token, + ) + req = self._build_request( method="GET", path="/v1/workflows/schedules", base_url=base_url, url_variables=url_variables, - request=None, + request=request, request_body_required=False, request_has_path_params=False, request_has_query_params=True, @@ -74,14 +96,53 @@ def get_schedules( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) + def next_func() -> Optional[models.GetSchedulesV1WorkflowsSchedulesGetResponse]: + body = utils.unmarshal_json(http_res.text, Union[Dict[Any, Any], List[Any]]) + + next_cursor = JSONPath("$.next_page_token").parse(body) + + if len(next_cursor) == 0: + return None + + next_cursor = next_cursor[0] + if next_cursor is None or str(next_cursor).strip() == "": + return None + results = JSONPath("$.schedules").parse(body) + if len(results) == 0 or len(results[0]) == 0: + return None + limit_ = request.page_size if isinstance(request.page_size, int) else 0 + if len(results[0]) < limit_: + return None + + return self.get_schedules( + workflow_name=workflow_name, + user_id=user_id, + status=status, + page_size=page_size, + next_page_token=next_cursor, + retries=retries, + server_url=server_url, + timeout_ms=timeout_ms, + http_headers=http_headers, + ) + + response_data: Any = None if utils.match_response(http_res, "200", "application/json"): - return unmarshal_json_response( - models.WorkflowScheduleListResponse, http_res + return models.GetSchedulesV1WorkflowsSchedulesGetResponse( + result=unmarshal_json_response( + models.WorkflowScheduleListResponse, http_res + ), + next=next_func, + ) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res ) + raise errors.HTTPValidationError(response_data, http_res) if utils.match_response(http_res, "4XX", "*"): http_res_text = utils.stream_to_text(http_res) raise errors.SDKError("API error occurred", http_res, http_res_text) @@ -94,13 +155,25 @@ def get_schedules( async def get_schedules_async( self, *, + workflow_name: OptionalNullable[str] = UNSET, + user_id: OptionalNullable[str] = UNSET, + status: OptionalNullable[ + models.GetSchedulesV1WorkflowsSchedulesGetStatus + ] = UNSET, + page_size: OptionalNullable[int] = UNSET, + next_page_token: OptionalNullable[str] = UNSET, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, http_headers: Optional[Mapping[str, str]] = None, - ) -> models.WorkflowScheduleListResponse: + ) -> Optional[models.GetSchedulesV1WorkflowsSchedulesGetResponse]: r"""Get Schedules + :param workflow_name: Filter by workflow name + :param user_id: Filter by user ID. Pass 'current' to resolve to the authenticated user's ID. + :param status: Filter by schedule status: 'active' or 'paused' + :param page_size: Number of items per page. Omitting this parameter fetches all results at once (deprecated — pass page_size to use pagination). + :param next_page_token: Token for the next page of results :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 @@ -118,12 +191,21 @@ async def get_schedules_async( base_url = server_url else: base_url = self._get_url(base_url, url_variables) + + request = models.GetSchedulesV1WorkflowsSchedulesGetRequest( + workflow_name=workflow_name, + user_id=user_id, + status=status, + page_size=page_size, + next_page_token=next_page_token, + ) + req = self._build_request_async( method="GET", path="/v1/workflows/schedules", base_url=base_url, url_variables=url_variables, - request=None, + request=request, request_body_required=False, request_has_path_params=False, request_has_query_params=True, @@ -154,14 +236,58 @@ async def get_schedules_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) + def next_func() -> ( + Awaitable[Optional[models.GetSchedulesV1WorkflowsSchedulesGetResponse]] + ): + body = utils.unmarshal_json(http_res.text, Union[Dict[Any, Any], List[Any]]) + + async def empty_result(): + return None + + next_cursor = JSONPath("$.next_page_token").parse(body) + + if len(next_cursor) == 0: + return empty_result() + + next_cursor = next_cursor[0] + if next_cursor is None or str(next_cursor).strip() == "": + return empty_result() + results = JSONPath("$.schedules").parse(body) + if len(results) == 0 or len(results[0]) == 0: + return empty_result() + limit_ = request.page_size if isinstance(request.page_size, int) else 0 + if len(results[0]) < limit_: + return empty_result() + + return self.get_schedules_async( + workflow_name=workflow_name, + user_id=user_id, + status=status, + page_size=page_size, + next_page_token=next_cursor, + retries=retries, + server_url=server_url, + timeout_ms=timeout_ms, + http_headers=http_headers, + ) + + response_data: Any = None if utils.match_response(http_res, "200", "application/json"): - return unmarshal_json_response( - models.WorkflowScheduleListResponse, http_res + return models.GetSchedulesV1WorkflowsSchedulesGetResponse( + result=unmarshal_json_response( + models.WorkflowScheduleListResponse, http_res + ), + next=next_func, ) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) if utils.match_response(http_res, "4XX", "*"): http_res_text = await utils.stream_to_text_async(http_res) raise errors.SDKError("API error occurred", http_res, http_res_text) @@ -267,7 +393,7 @@ def schedule_workflow( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -384,7 +510,7 @@ async def schedule_workflow_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -405,6 +531,188 @@ async def schedule_workflow_async( raise errors.SDKError("Unexpected response received", http_res) + def get_schedule( + self, + *, + schedule_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.ScheduleDefinitionOutput: + r"""Get Schedule + + :param schedule_id: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.GetScheduleV1WorkflowsSchedulesScheduleIDGetRequest( + schedule_id=schedule_id, + ) + + req = self._build_request( + method="GET", + path="/v1/workflows/schedules/{schedule_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="get_schedule_v1_workflows_schedules__schedule_id__get", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.ScheduleDefinitionOutput, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def get_schedule_async( + self, + *, + schedule_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.ScheduleDefinitionOutput: + r"""Get Schedule + + :param schedule_id: + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.GetScheduleV1WorkflowsSchedulesScheduleIDGetRequest( + schedule_id=schedule_id, + ) + + req = self._build_request_async( + method="GET", + path="/v1/workflows/schedules/{schedule_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="get_schedule_v1_workflows_schedules__schedule_id__get", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.ScheduleDefinitionOutput, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + def unschedule_workflow( self, *, @@ -475,7 +783,7 @@ def unschedule_workflow( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -566,7 +874,7 @@ async def unschedule_workflow_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -587,6 +895,226 @@ async def unschedule_workflow_async( raise errors.SDKError("Unexpected response received", http_res) + def update_schedule( + self, + *, + schedule_id: str, + schedule: Union[ + models.PartialScheduleDefinition, models.PartialScheduleDefinitionTypedDict + ], + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.WorkflowScheduleResponse: + r"""Update Schedule + + :param schedule_id: + :param schedule: Schedule definition for partial updates. + + All fields are optional (inherited from _ScheduleRequestBase). Only explicitly-set + fields are applied during an update; unset fields preserve the existing schedule values. + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.UpdateScheduleV1WorkflowsSchedulesScheduleIDPatchRequest( + schedule_id=schedule_id, + workflow_schedule_update_request=models.WorkflowScheduleUpdateRequest( + schedule=utils.get_pydantic_model( + schedule, models.PartialScheduleDefinition + ), + ), + ) + + req = self._build_request( + method="PATCH", + path="/v1/workflows/schedules/{schedule_id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + 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, + get_serialized_body=lambda: utils.serialize_request_body( + request.workflow_schedule_update_request, + False, + False, + "json", + models.WorkflowScheduleUpdateRequest, + ), + 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="update_schedule_v1_workflows_schedules__schedule_id__patch", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.WorkflowScheduleResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def update_schedule_async( + self, + *, + schedule_id: str, + schedule: Union[ + models.PartialScheduleDefinition, models.PartialScheduleDefinitionTypedDict + ], + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.WorkflowScheduleResponse: + r"""Update Schedule + + :param schedule_id: + :param schedule: Schedule definition for partial updates. + + All fields are optional (inherited from _ScheduleRequestBase). Only explicitly-set + fields are applied during an update; unset fields preserve the existing schedule values. + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.UpdateScheduleV1WorkflowsSchedulesScheduleIDPatchRequest( + schedule_id=schedule_id, + workflow_schedule_update_request=models.WorkflowScheduleUpdateRequest( + schedule=utils.get_pydantic_model( + schedule, models.PartialScheduleDefinition + ), + ), + ) + + req = self._build_request_async( + method="PATCH", + path="/v1/workflows/schedules/{schedule_id}", + base_url=base_url, + url_variables=url_variables, + request=request, + request_body_required=True, + 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, + get_serialized_body=lambda: utils.serialize_request_body( + request.workflow_schedule_update_request, + False, + False, + "json", + models.WorkflowScheduleUpdateRequest, + ), + 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="update_schedule_v1_workflows_schedules__schedule_id__patch", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.WorkflowScheduleResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + def pause_schedule( self, *, @@ -671,7 +1199,7 @@ def pause_schedule( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -776,7 +1304,7 @@ async def pause_schedule_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -881,7 +1409,7 @@ def resume_schedule( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -986,7 +1514,7 @@ async def resume_schedule_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/sdk.py b/src/mistralai/client/sdk.py index 03338f46..86de8dd9 100644 --- a/src/mistralai/client/sdk.py +++ b/src/mistralai/client/sdk.py @@ -119,7 +119,9 @@ def __init__( ), "The provided async_client must implement the AsyncHttpClient protocol." security: Any = None - if callable(api_key): + if api_key is None: + security = None + elif callable(api_key): # pylint: disable=unnecessary-lambda-assignment security = lambda: models_.Security(api_key=api_key()) else: diff --git a/src/mistralai/client/search_indexes.py b/src/mistralai/client/search_indexes.py new file mode 100644 index 00000000..522ae338 --- /dev/null +++ b/src/mistralai/client/search_indexes.py @@ -0,0 +1,384 @@ +"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" +# @generated-id: c5a0a7df993a + +from .basesdk import BaseSDK +from mistralai.client import errors, models, utils +from mistralai.client._hooks import HookContext +from mistralai.client.types import OptionalNullable, UNSET +from mistralai.client.utils import get_security_from_env +from mistralai.client.utils.unmarshal_json_response import unmarshal_json_response +from typing import Any, List, Mapping, Optional, Union + + +class SearchIndexes(BaseSDK): + def list( + self, + *, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> List[models.SearchIndexResponse]: + r"""Get Search Indexes + + :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 timeout_ms is None: + timeout_ms = 60000 + + 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="/v1/rag/search_index", + 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="get_search_indexes_v1_rag_search_index_get", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response(List[models.SearchIndexResponse], http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def list_async( + self, + *, + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> List[models.SearchIndexResponse]: + r"""Get Search Indexes + + :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 timeout_ms is None: + timeout_ms = 60000 + + 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="/v1/rag/search_index", + 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="get_search_indexes_v1_rag_search_index_get", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + request=req, + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), + retry_config=retry_config, + ) + + if utils.match_response(http_res, "200", "application/json"): + return unmarshal_json_response(List[models.SearchIndexResponse], http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + def register( + self, + *, + name: str, + index: Union[ + models.CreateSearchIndexInfoRequestIndex, + models.CreateSearchIndexInfoRequestIndexTypedDict, + ], + document_count: OptionalNullable[int] = UNSET, + status: Optional[models.CreateSearchIndexInfoRequestStatus] = "offline", + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.SearchIndexResponse: + r"""Register Search Index + + :param name: + :param index: + :param document_count: + :param 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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.CreateSearchIndexInfoRequest( + name=name, + document_count=document_count, + status=status, + index=utils.get_pydantic_model( + index, models.CreateSearchIndexInfoRequestIndex + ), + ) + + req = self._build_request( + method="PUT", + path="/v1/rag/search_index", + 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.CreateSearchIndexInfoRequest + ), + 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="register_search_index_v1_rag_search_index_put", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.SearchIndexResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def register_async( + self, + *, + name: str, + index: Union[ + models.CreateSearchIndexInfoRequestIndex, + models.CreateSearchIndexInfoRequestIndexTypedDict, + ], + document_count: OptionalNullable[int] = UNSET, + status: Optional[models.CreateSearchIndexInfoRequestStatus] = "offline", + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.SearchIndexResponse: + r"""Register Search Index + + :param name: + :param index: + :param document_count: + :param 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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.CreateSearchIndexInfoRequest( + name=name, + document_count=document_count, + status=status, + index=utils.get_pydantic_model( + index, models.CreateSearchIndexInfoRequestIndex + ), + ) + + req = self._build_request_async( + method="PUT", + path="/v1/rag/search_index", + 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.CreateSearchIndexInfoRequest + ), + 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="register_search_index_v1_rag_search_index_put", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.SearchIndexResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) diff --git a/src/mistralai/client/speech.py b/src/mistralai/client/speech.py index 4893684b..42cb1bbb 100644 --- a/src/mistralai/client/speech.py +++ b/src/mistralai/client/speech.py @@ -180,7 +180,7 @@ def complete( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -376,7 +376,7 @@ async def complete_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) diff --git a/src/mistralai/client/transcriptions.py b/src/mistralai/client/transcriptions.py index d84b59f8..b63fd5d0 100644 --- a/src/mistralai/client/transcriptions.py +++ b/src/mistralai/client/transcriptions.py @@ -110,7 +110,7 @@ def complete( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -222,7 +222,7 @@ async def complete_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -338,7 +338,7 @@ def stream( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -460,7 +460,7 @@ async def stream_async( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) diff --git a/src/mistralai/client/voices.py b/src/mistralai/client/voices.py index e19d5d5a..2810b922 100644 --- a/src/mistralai/client/voices.py +++ b/src/mistralai/client/voices.py @@ -8,7 +8,7 @@ from mistralai.client.types import OptionalNullable, UNSET from mistralai.client.utils import get_security_from_env from mistralai.client.utils.unmarshal_json_response import unmarshal_json_response -from typing import Any, List, Mapping, Optional +from typing import Any, List, Mapping, Optional, Union class Voices(BaseSDK): @@ -90,7 +90,7 @@ def list( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -189,7 +189,7 @@ async def list_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -221,6 +221,10 @@ def create( age: OptionalNullable[int] = UNSET, tags: OptionalNullable[List[str]] = UNSET, color: OptionalNullable[str] = UNSET, + description: OptionalNullable[str] = UNSET, + appearance: OptionalNullable[ + Union[models.VoiceAppearance, models.VoiceAppearanceTypedDict] + ] = UNSET, retention_notice: Optional[int] = 30, sample_filename: OptionalNullable[str] = UNSET, retries: OptionalNullable[utils.RetryConfig] = UNSET, @@ -240,6 +244,8 @@ def create( :param age: :param tags: :param color: + :param description: + :param appearance: :param retention_notice: :param sample_filename: Original filename for extension detection :param retries: Override the default retry configuration for this method @@ -268,6 +274,10 @@ def create( age=age, tags=tags, color=color, + description=description, + appearance=utils.get_pydantic_model( + appearance, OptionalNullable[models.VoiceAppearance] + ), retention_notice=retention_notice, sample_audio=sample_audio, sample_filename=sample_filename, @@ -312,7 +322,7 @@ def create( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -344,6 +354,10 @@ async def create_async( age: OptionalNullable[int] = UNSET, tags: OptionalNullable[List[str]] = UNSET, color: OptionalNullable[str] = UNSET, + description: OptionalNullable[str] = UNSET, + appearance: OptionalNullable[ + Union[models.VoiceAppearance, models.VoiceAppearanceTypedDict] + ] = UNSET, retention_notice: Optional[int] = 30, sample_filename: OptionalNullable[str] = UNSET, retries: OptionalNullable[utils.RetryConfig] = UNSET, @@ -363,6 +377,8 @@ async def create_async( :param age: :param tags: :param color: + :param description: + :param appearance: :param retention_notice: :param sample_filename: Original filename for extension detection :param retries: Override the default retry configuration for this method @@ -391,6 +407,10 @@ async def create_async( age=age, tags=tags, color=color, + description=description, + appearance=utils.get_pydantic_model( + appearance, OptionalNullable[models.VoiceAppearance] + ), retention_notice=retention_notice, sample_audio=sample_audio, sample_filename=sample_filename, @@ -435,7 +455,7 @@ async def create_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -528,7 +548,7 @@ def delete( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -621,7 +641,7 @@ async def delete_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -651,6 +671,10 @@ def update( gender: OptionalNullable[str] = UNSET, age: OptionalNullable[int] = UNSET, tags: OptionalNullable[List[str]] = UNSET, + description: OptionalNullable[str] = UNSET, + appearance: OptionalNullable[ + Union[models.VoiceAppearance, models.VoiceAppearanceTypedDict] + ] = UNSET, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -666,6 +690,8 @@ def update( :param gender: :param age: :param tags: + :param description: + :param appearance: :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 @@ -692,6 +718,10 @@ def update( gender=gender, age=age, tags=tags, + description=description, + appearance=utils.get_pydantic_model( + appearance, OptionalNullable[models.VoiceAppearance] + ), ), ) @@ -738,7 +768,7 @@ def update( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -768,6 +798,10 @@ async def update_async( gender: OptionalNullable[str] = UNSET, age: OptionalNullable[int] = UNSET, tags: OptionalNullable[List[str]] = UNSET, + description: OptionalNullable[str] = UNSET, + appearance: OptionalNullable[ + Union[models.VoiceAppearance, models.VoiceAppearanceTypedDict] + ] = UNSET, retries: OptionalNullable[utils.RetryConfig] = UNSET, server_url: Optional[str] = None, timeout_ms: Optional[int] = None, @@ -783,6 +817,8 @@ async def update_async( :param gender: :param age: :param tags: + :param description: + :param appearance: :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 @@ -809,6 +845,10 @@ async def update_async( gender=gender, age=age, tags=tags, + description=description, + appearance=utils.get_pydantic_model( + appearance, OptionalNullable[models.VoiceAppearance] + ), ), ) @@ -855,7 +895,7 @@ async def update_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -948,7 +988,7 @@ def get( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1041,7 +1081,7 @@ async def get_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1134,7 +1174,7 @@ def get_sample_audio( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -1230,7 +1270,7 @@ async def get_sample_audio_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) diff --git a/src/mistralai/client/workflows.py b/src/mistralai/client/workflows.py index 2693b05b..a6015946 100644 --- a/src/mistralai/client/workflows.py +++ b/src/mistralai/client/workflows.py @@ -377,7 +377,7 @@ def get_workflows( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -395,8 +395,8 @@ def next_func() -> Optional[models.GetWorkflowsV1WorkflowsGetResponse]: results = JSONPath("$.workflows").parse(body) if len(results) == 0 or len(results[0]) == 0: return None - limit = request.limit if isinstance(request.limit, int) else 50 - if len(results[0]) < limit: + limit_ = request.limit if isinstance(request.limit, int) else 50 + if len(results[0]) < limit_: return None return self.get_workflows( @@ -517,7 +517,7 @@ async def get_workflows_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -540,8 +540,8 @@ async def empty_result(): results = JSONPath("$.workflows").parse(body) if len(results) == 0 or len(results[0]) == 0: return empty_result() - limit = request.limit if isinstance(request.limit, int) else 50 - if len(results[0]) < limit: + limit_ = request.limit if isinstance(request.limit, int) else 50 + if len(results[0]) < limit_: return empty_result() return self.get_workflows_async( @@ -674,7 +674,7 @@ def get_workflow_registrations( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -794,7 +794,7 @@ async def get_workflow_registrations_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -920,7 +920,7 @@ def execute_workflow( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1047,7 +1047,7 @@ async def execute_workflow_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1177,7 +1177,7 @@ def execute_workflow_registration( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1307,7 +1307,7 @@ async def execute_workflow_registration_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1401,7 +1401,7 @@ def get_workflow( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1492,7 +1492,7 @@ async def get_workflow_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1601,7 +1601,7 @@ def update_workflow( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1710,7 +1710,7 @@ async def update_workflow_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1807,7 +1807,7 @@ def get_workflow_registration( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1906,7 +1906,7 @@ async def get_workflow_registration_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -1929,6 +1929,386 @@ async def get_workflow_registration_async( raise errors.SDKError("Unexpected response received", http_res) + def bulk_archive_workflows( + self, + *, + workflow_ids: List[str], + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.WorkflowBulkArchiveResponse: + r"""Bulk Archive Workflows + + :param workflow_ids: List of workflow IDs to archive + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.WorkflowBulkArchiveRequest( + workflow_ids=workflow_ids, + ) + + req = self._build_request( + method="PUT", + path="/v1/workflows/archive", + 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.WorkflowBulkArchiveRequest + ), + 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="bulk_archive_workflows_v1_workflows_archive_put", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.WorkflowBulkArchiveResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def bulk_archive_workflows_async( + self, + *, + workflow_ids: List[str], + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.WorkflowBulkArchiveResponse: + r"""Bulk Archive Workflows + + :param workflow_ids: List of workflow IDs to archive + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.WorkflowBulkArchiveRequest( + workflow_ids=workflow_ids, + ) + + req = self._build_request_async( + method="PUT", + path="/v1/workflows/archive", + 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.WorkflowBulkArchiveRequest + ), + 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="bulk_archive_workflows_v1_workflows_archive_put", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.WorkflowBulkArchiveResponse, http_res) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + def bulk_unarchive_workflows( + self, + *, + workflow_ids: List[str], + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.WorkflowBulkUnarchiveResponse: + r"""Bulk Unarchive Workflows + + :param workflow_ids: List of workflow IDs to unarchive + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.WorkflowBulkUnarchiveRequest( + workflow_ids=workflow_ids, + ) + + req = self._build_request( + method="PUT", + path="/v1/workflows/unarchive", + 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.WorkflowBulkUnarchiveRequest + ), + 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="bulk_unarchive_workflows_v1_workflows_unarchive_put", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.WorkflowBulkUnarchiveResponse, http_res + ) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = utils.stream_to_text(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + + async def bulk_unarchive_workflows_async( + self, + *, + workflow_ids: List[str], + retries: OptionalNullable[utils.RetryConfig] = UNSET, + server_url: Optional[str] = None, + timeout_ms: Optional[int] = None, + http_headers: Optional[Mapping[str, str]] = None, + ) -> models.WorkflowBulkUnarchiveResponse: + r"""Bulk Unarchive Workflows + + :param workflow_ids: List of workflow IDs to unarchive + :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 timeout_ms is None: + timeout_ms = 60000 + + if server_url is not None: + base_url = server_url + else: + base_url = self._get_url(base_url, url_variables) + + request = models.WorkflowBulkUnarchiveRequest( + workflow_ids=workflow_ids, + ) + + req = self._build_request_async( + method="PUT", + path="/v1/workflows/unarchive", + 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.WorkflowBulkUnarchiveRequest + ), + 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="bulk_unarchive_workflows_v1_workflows_unarchive_put", + oauth2_scopes=None, + security_source=get_security_from_env( + self.sdk_configuration.security, models.Security + ), + ), + 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.WorkflowBulkUnarchiveResponse, http_res + ) + if utils.match_response(http_res, "422", "application/json"): + response_data = unmarshal_json_response( + errors.HTTPValidationErrorData, http_res + ) + raise errors.HTTPValidationError(response_data, http_res) + if utils.match_response(http_res, "4XX", "*"): + http_res_text = await utils.stream_to_text_async(http_res) + raise errors.SDKError("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.SDKError("API error occurred", http_res, http_res_text) + + raise errors.SDKError("Unexpected response received", http_res) + def archive_workflow( self, *, @@ -1999,7 +2379,7 @@ def archive_workflow( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2090,7 +2470,7 @@ async def archive_workflow_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2183,7 +2563,7 @@ def unarchive_workflow( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -2276,7 +2656,7 @@ async def unarchive_workflow_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/client/workflows_events.py b/src/mistralai/client/workflows_events.py index 71e44ac7..fbf5bc11 100644 --- a/src/mistralai/client/workflows_events.py +++ b/src/mistralai/client/workflows_events.py @@ -116,7 +116,7 @@ def get_stream_events( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -252,7 +252,7 @@ async def get_stream_events_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), stream=True, retry_config=retry_config, ) @@ -365,7 +365,7 @@ def get_workflow_events( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) @@ -468,7 +468,7 @@ async def get_workflow_events_async( ), ), request=req, - error_status_codes=["422", "4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/src/mistralai/extra/workflows/helpers.py b/src/mistralai/extra/workflows/helpers.py index 508c4b97..901fae45 100644 --- a/src/mistralai/extra/workflows/helpers.py +++ b/src/mistralai/extra/workflows/helpers.py @@ -70,7 +70,7 @@ async def get_scheduler_namespace( ), ), request=req, - error_status_codes=["4XX", "5XX"], + is_error_status_code=lambda c: utils.match_status_codes(["4XX", "5XX"], c), retry_config=retry_config, ) diff --git a/uv.lock b/uv.lock index 8cc60189..d1b64c13 100644 --- a/uv.lock +++ b/uv.lock @@ -7,6 +7,10 @@ resolution-markers = [ "python_full_version < '3.11'", ] +[options] +exclude-newer = "0001-01-01T00:00:00Z" # This has no effect and is included for backwards compatibility when using relative exclude-newer values. +exclude-newer-span = "P7D" + [[package]] name = "aioboto3" version = "12.4.0" @@ -1031,7 +1035,7 @@ wheels = [ [[package]] name = "mistralai" -version = "2.4.5" +version = "2.4.7" source = { editable = "." } dependencies = [ { name = "eval-type-backport" },