@distilled.cloud/typesense 0.30.3 → 1.0.0-rc.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/credentials.d.ts +7 -0
- package/lib/credentials.d.ts.map +1 -1
- package/lib/credentials.js +17 -0
- package/lib/credentials.js.map +1 -1
- package/lib/errors.d.ts +14 -3
- package/lib/errors.d.ts.map +1 -1
- package/lib/errors.js +3 -2
- package/lib/errors.js.map +1 -1
- package/lib/index.d.ts +7 -10
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +7 -10
- package/lib/index.js.map +1 -1
- package/lib/protocol.d.ts +18 -0
- package/lib/protocol.d.ts.map +1 -0
- package/lib/protocol.js +31 -0
- package/lib/protocol.js.map +1 -0
- package/lib/retry.d.ts +4 -4
- package/lib/retry.js +4 -4
- package/lib/services/index.d.ts +2 -0
- package/lib/services/index.d.ts.map +1 -0
- package/lib/services/index.js +3 -0
- package/lib/services/index.js.map +1 -0
- package/lib/services/typesense.d.ts +2817 -0
- package/lib/services/typesense.d.ts.map +1 -0
- package/lib/services/typesense.js +2917 -0
- package/lib/services/typesense.js.map +1 -0
- package/lib/traits.d.ts +8 -2
- package/lib/traits.d.ts.map +1 -1
- package/lib/traits.js +8 -2
- package/lib/traits.js.map +1 -1
- package/package.json +31 -51
- package/src/credentials.ts +26 -0
- package/src/errors.ts +16 -3
- package/src/index.ts +11 -10
- package/src/protocol.ts +52 -0
- package/src/retry.ts +4 -4
- package/src/services/index.ts +2 -0
- package/src/services/typesense.ts +6837 -0
- package/src/traits.ts +41 -2
- package/README.md +0 -75
- package/lib/category.d.ts +0 -5
- package/lib/category.d.ts.map +0 -1
- package/lib/category.js +0 -5
- package/lib/category.js.map +0 -1
- package/lib/client.d.ts +0 -11
- package/lib/client.d.ts.map +0 -1
- package/lib/client.js +0 -56
- package/lib/client.js.map +0 -1
- package/lib/operations/clearCache.d.ts +0 -15
- package/lib/operations/clearCache.d.ts.map +0 -1
- package/lib/operations/clearCache.js +0 -18
- package/lib/operations/clearCache.js.map +0 -1
- package/lib/operations/compactDb.d.ts +0 -15
- package/lib/operations/compactDb.d.ts.map +0 -1
- package/lib/operations/compactDb.js +0 -18
- package/lib/operations/compactDb.js.map +0 -1
- package/lib/operations/createAnalyticsEvent.d.ts +0 -25
- package/lib/operations/createAnalyticsEvent.d.ts.map +0 -1
- package/lib/operations/createAnalyticsEvent.js +0 -32
- package/lib/operations/createAnalyticsEvent.js.map +0 -1
- package/lib/operations/createAnalyticsRule.d.ts +0 -46
- package/lib/operations/createAnalyticsRule.d.ts.map +0 -1
- package/lib/operations/createAnalyticsRule.js +0 -68
- package/lib/operations/createAnalyticsRule.js.map +0 -1
- package/lib/operations/createCollection.d.ts +0 -110
- package/lib/operations/createCollection.d.ts.map +0 -1
- package/lib/operations/createCollection.js +0 -116
- package/lib/operations/createCollection.js.map +0 -1
- package/lib/operations/createConversationModel.d.ts +0 -26
- package/lib/operations/createConversationModel.d.ts.map +0 -1
- package/lib/operations/createConversationModel.js +0 -34
- package/lib/operations/createConversationModel.js.map +0 -1
- package/lib/operations/createKey.d.ts +0 -27
- package/lib/operations/createKey.d.ts.map +0 -1
- package/lib/operations/createKey.js +0 -32
- package/lib/operations/createKey.js.map +0 -1
- package/lib/operations/createNLSearchModel.d.ts +0 -36
- package/lib/operations/createNLSearchModel.d.ts.map +0 -1
- package/lib/operations/createNLSearchModel.js +0 -44
- package/lib/operations/createNLSearchModel.js.map +0 -1
- package/lib/operations/debug.d.ts +0 -13
- package/lib/operations/debug.d.ts.map +0 -1
- package/lib/operations/debug.js +0 -16
- package/lib/operations/debug.js.map +0 -1
- package/lib/operations/deleteAlias.d.ts +0 -18
- package/lib/operations/deleteAlias.d.ts.map +0 -1
- package/lib/operations/deleteAlias.js +0 -23
- package/lib/operations/deleteAlias.js.map +0 -1
- package/lib/operations/deleteAnalyticsRule.d.ts +0 -32
- package/lib/operations/deleteAnalyticsRule.d.ts.map +0 -1
- package/lib/operations/deleteAnalyticsRule.js +0 -44
- package/lib/operations/deleteAnalyticsRule.js.map +0 -1
- package/lib/operations/deleteCollection.d.ts +0 -67
- package/lib/operations/deleteCollection.d.ts.map +0 -1
- package/lib/operations/deleteCollection.js +0 -73
- package/lib/operations/deleteCollection.js.map +0 -1
- package/lib/operations/deleteConversationModel.d.ts +0 -17
- package/lib/operations/deleteConversationModel.d.ts.map +0 -1
- package/lib/operations/deleteConversationModel.js +0 -24
- package/lib/operations/deleteConversationModel.js.map +0 -1
- package/lib/operations/deleteCurationSet.d.ts +0 -19
- package/lib/operations/deleteCurationSet.d.ts.map +0 -1
- package/lib/operations/deleteCurationSet.js +0 -25
- package/lib/operations/deleteCurationSet.js.map +0 -1
- package/lib/operations/deleteCurationSetItem.d.ts +0 -21
- package/lib/operations/deleteCurationSetItem.d.ts.map +0 -1
- package/lib/operations/deleteCurationSetItem.js +0 -31
- package/lib/operations/deleteCurationSetItem.js.map +0 -1
- package/lib/operations/deleteDocument.d.ts +0 -19
- package/lib/operations/deleteDocument.d.ts.map +0 -1
- package/lib/operations/deleteDocument.js +0 -28
- package/lib/operations/deleteDocument.js.map +0 -1
- package/lib/operations/deleteDocuments.d.ts +0 -20
- package/lib/operations/deleteDocuments.d.ts.map +0 -1
- package/lib/operations/deleteDocuments.js +0 -25
- package/lib/operations/deleteDocuments.js.map +0 -1
- package/lib/operations/deleteKey.d.ts +0 -17
- package/lib/operations/deleteKey.d.ts.map +0 -1
- package/lib/operations/deleteKey.js +0 -22
- package/lib/operations/deleteKey.js.map +0 -1
- package/lib/operations/deleteNLSearchModel.d.ts +0 -19
- package/lib/operations/deleteNLSearchModel.d.ts.map +0 -1
- package/lib/operations/deleteNLSearchModel.js +0 -26
- package/lib/operations/deleteNLSearchModel.js.map +0 -1
- package/lib/operations/deletePreset.d.ts +0 -19
- package/lib/operations/deletePreset.d.ts.map +0 -1
- package/lib/operations/deletePreset.js +0 -24
- package/lib/operations/deletePreset.js.map +0 -1
- package/lib/operations/deleteStopwordsSet.d.ts +0 -19
- package/lib/operations/deleteStopwordsSet.d.ts.map +0 -1
- package/lib/operations/deleteStopwordsSet.js +0 -26
- package/lib/operations/deleteStopwordsSet.js.map +0 -1
- package/lib/operations/deleteSynonymSet.d.ts +0 -19
- package/lib/operations/deleteSynonymSet.d.ts.map +0 -1
- package/lib/operations/deleteSynonymSet.js +0 -24
- package/lib/operations/deleteSynonymSet.js.map +0 -1
- package/lib/operations/deleteSynonymSetItem.d.ts +0 -21
- package/lib/operations/deleteSynonymSetItem.d.ts.map +0 -1
- package/lib/operations/deleteSynonymSetItem.js +0 -31
- package/lib/operations/deleteSynonymSetItem.js.map +0 -1
- package/lib/operations/exportDocuments.d.ts +0 -18
- package/lib/operations/exportDocuments.d.ts.map +0 -1
- package/lib/operations/exportDocuments.js +0 -27
- package/lib/operations/exportDocuments.js.map +0 -1
- package/lib/operations/flushAnalytics.d.ts +0 -15
- package/lib/operations/flushAnalytics.d.ts.map +0 -1
- package/lib/operations/flushAnalytics.js +0 -18
- package/lib/operations/flushAnalytics.js.map +0 -1
- package/lib/operations/getAlias.d.ts +0 -20
- package/lib/operations/getAlias.d.ts.map +0 -1
- package/lib/operations/getAlias.js +0 -25
- package/lib/operations/getAlias.js.map +0 -1
- package/lib/operations/getAliases.d.ts +0 -18
- package/lib/operations/getAliases.d.ts.map +0 -1
- package/lib/operations/getAliases.js +0 -21
- package/lib/operations/getAliases.js.map +0 -1
- package/lib/operations/getAnalyticsEvents.d.ts +0 -31
- package/lib/operations/getAnalyticsEvents.d.ts.map +0 -1
- package/lib/operations/getAnalyticsEvents.js +0 -38
- package/lib/operations/getAnalyticsEvents.js.map +0 -1
- package/lib/operations/getAnalyticsStatus.d.ts +0 -21
- package/lib/operations/getAnalyticsStatus.d.ts.map +0 -1
- package/lib/operations/getAnalyticsStatus.js +0 -26
- package/lib/operations/getAnalyticsStatus.js.map +0 -1
- package/lib/operations/getCollection.d.ts +0 -67
- package/lib/operations/getCollection.d.ts.map +0 -1
- package/lib/operations/getCollection.js +0 -73
- package/lib/operations/getCollection.js.map +0 -1
- package/lib/operations/getCollections.d.ts +0 -64
- package/lib/operations/getCollections.d.ts.map +0 -1
- package/lib/operations/getCollections.js +0 -69
- package/lib/operations/getCollections.js.map +0 -1
- package/lib/operations/getDocument.d.ts +0 -19
- package/lib/operations/getDocument.d.ts.map +0 -1
- package/lib/operations/getDocument.js +0 -28
- package/lib/operations/getDocument.js.map +0 -1
- package/lib/operations/getKey.d.ts +0 -25
- package/lib/operations/getKey.d.ts.map +0 -1
- package/lib/operations/getKey.js +0 -30
- package/lib/operations/getKey.js.map +0 -1
- package/lib/operations/getKeys.d.ts +0 -21
- package/lib/operations/getKeys.d.ts.map +0 -1
- package/lib/operations/getKeys.js +0 -24
- package/lib/operations/getKeys.js.map +0 -1
- package/lib/operations/getSchemaChanges.d.ts +0 -17
- package/lib/operations/getSchemaChanges.d.ts.map +0 -1
- package/lib/operations/getSchemaChanges.js +0 -20
- package/lib/operations/getSchemaChanges.js.map +0 -1
- package/lib/operations/getStemmingDictionary.d.ts +0 -23
- package/lib/operations/getStemmingDictionary.d.ts.map +0 -1
- package/lib/operations/getStemmingDictionary.js +0 -30
- package/lib/operations/getStemmingDictionary.js.map +0 -1
- package/lib/operations/health.d.ts +0 -13
- package/lib/operations/health.d.ts.map +0 -1
- package/lib/operations/health.js +0 -16
- package/lib/operations/health.js.map +0 -1
- package/lib/operations/importDocuments.d.ts +0 -18
- package/lib/operations/importDocuments.d.ts.map +0 -1
- package/lib/operations/importDocuments.js +0 -27
- package/lib/operations/importDocuments.js.map +0 -1
- package/lib/operations/importStemmingDictionary.d.ts +0 -17
- package/lib/operations/importStemmingDictionary.d.ts.map +0 -1
- package/lib/operations/importStemmingDictionary.js +0 -24
- package/lib/operations/importStemmingDictionary.js.map +0 -1
- package/lib/operations/index.d.ts +0 -80
- package/lib/operations/index.d.ts.map +0 -1
- package/lib/operations/index.js +0 -80
- package/lib/operations/index.js.map +0 -1
- package/lib/operations/indexDocument.d.ts +0 -21
- package/lib/operations/indexDocument.d.ts.map +0 -1
- package/lib/operations/indexDocument.js +0 -27
- package/lib/operations/indexDocument.js.map +0 -1
- package/lib/operations/listStemmingDictionaries.d.ts +0 -15
- package/lib/operations/listStemmingDictionaries.d.ts.map +0 -1
- package/lib/operations/listStemmingDictionaries.js +0 -20
- package/lib/operations/listStemmingDictionaries.js.map +0 -1
- package/lib/operations/multiSearch.d.ts +0 -207
- package/lib/operations/multiSearch.d.ts.map +0 -1
- package/lib/operations/multiSearch.js +0 -212
- package/lib/operations/multiSearch.js.map +0 -1
- package/lib/operations/retrieveAPIStats.d.ts +0 -27
- package/lib/operations/retrieveAPIStats.d.ts.map +0 -1
- package/lib/operations/retrieveAPIStats.js +0 -30
- package/lib/operations/retrieveAPIStats.js.map +0 -1
- package/lib/operations/retrieveAllConversationModels.d.ts +0 -15
- package/lib/operations/retrieveAllConversationModels.d.ts.map +0 -1
- package/lib/operations/retrieveAllConversationModels.js +0 -21
- package/lib/operations/retrieveAllConversationModels.js.map +0 -1
- package/lib/operations/retrieveAllNLSearchModels.d.ts +0 -15
- package/lib/operations/retrieveAllNLSearchModels.d.ts.map +0 -1
- package/lib/operations/retrieveAllNLSearchModels.js +0 -20
- package/lib/operations/retrieveAllNLSearchModels.js.map +0 -1
- package/lib/operations/retrieveAllPresets.d.ts +0 -163
- package/lib/operations/retrieveAllPresets.d.ts.map +0 -1
- package/lib/operations/retrieveAllPresets.js +0 -23
- package/lib/operations/retrieveAllPresets.js.map +0 -1
- package/lib/operations/retrieveAnalyticsRule.d.ts +0 -32
- package/lib/operations/retrieveAnalyticsRule.d.ts.map +0 -1
- package/lib/operations/retrieveAnalyticsRule.js +0 -44
- package/lib/operations/retrieveAnalyticsRule.js.map +0 -1
- package/lib/operations/retrieveAnalyticsRules.d.ts +0 -31
- package/lib/operations/retrieveAnalyticsRules.d.ts.map +0 -1
- package/lib/operations/retrieveAnalyticsRules.js +0 -42
- package/lib/operations/retrieveAnalyticsRules.js.map +0 -1
- package/lib/operations/retrieveConversationModel.d.ts +0 -17
- package/lib/operations/retrieveConversationModel.d.ts.map +0 -1
- package/lib/operations/retrieveConversationModel.js +0 -24
- package/lib/operations/retrieveConversationModel.js.map +0 -1
- package/lib/operations/retrieveCurationSet.d.ts +0 -45
- package/lib/operations/retrieveCurationSet.d.ts.map +0 -1
- package/lib/operations/retrieveCurationSet.js +0 -52
- package/lib/operations/retrieveCurationSet.js.map +0 -1
- package/lib/operations/retrieveCurationSetItem.d.ts +0 -43
- package/lib/operations/retrieveCurationSetItem.d.ts.map +0 -1
- package/lib/operations/retrieveCurationSetItem.js +0 -53
- package/lib/operations/retrieveCurationSetItem.js.map +0 -1
- package/lib/operations/retrieveCurationSetItems.d.ts +0 -41
- package/lib/operations/retrieveCurationSetItems.d.ts.map +0 -1
- package/lib/operations/retrieveCurationSetItems.js +0 -48
- package/lib/operations/retrieveCurationSetItems.js.map +0 -1
- package/lib/operations/retrieveCurationSets.d.ts +0 -41
- package/lib/operations/retrieveCurationSets.d.ts.map +0 -1
- package/lib/operations/retrieveCurationSets.js +0 -46
- package/lib/operations/retrieveCurationSets.js.map +0 -1
- package/lib/operations/retrieveMetrics.d.ts +0 -13
- package/lib/operations/retrieveMetrics.d.ts.map +0 -1
- package/lib/operations/retrieveMetrics.js +0 -17
- package/lib/operations/retrieveMetrics.js.map +0 -1
- package/lib/operations/retrieveNLSearchModel.d.ts +0 -19
- package/lib/operations/retrieveNLSearchModel.d.ts.map +0 -1
- package/lib/operations/retrieveNLSearchModel.js +0 -26
- package/lib/operations/retrieveNLSearchModel.js.map +0 -1
- package/lib/operations/retrievePreset.d.ts +0 -165
- package/lib/operations/retrievePreset.d.ts.map +0 -1
- package/lib/operations/retrievePreset.js +0 -25
- package/lib/operations/retrievePreset.js.map +0 -1
- package/lib/operations/retrieveStopwordsSet.d.ts +0 -23
- package/lib/operations/retrieveStopwordsSet.d.ts.map +0 -1
- package/lib/operations/retrieveStopwordsSet.js +0 -30
- package/lib/operations/retrieveStopwordsSet.js.map +0 -1
- package/lib/operations/retrieveStopwordsSets.d.ts +0 -19
- package/lib/operations/retrieveStopwordsSets.d.ts.map +0 -1
- package/lib/operations/retrieveStopwordsSets.js +0 -24
- package/lib/operations/retrieveStopwordsSets.js.map +0 -1
- package/lib/operations/retrieveSynonymSet.d.ts +0 -26
- package/lib/operations/retrieveSynonymSet.d.ts.map +0 -1
- package/lib/operations/retrieveSynonymSet.js +0 -33
- package/lib/operations/retrieveSynonymSet.js.map +0 -1
- package/lib/operations/retrieveSynonymSetItem.d.ts +0 -25
- package/lib/operations/retrieveSynonymSetItem.d.ts.map +0 -1
- package/lib/operations/retrieveSynonymSetItem.js +0 -35
- package/lib/operations/retrieveSynonymSetItem.js.map +0 -1
- package/lib/operations/retrieveSynonymSetItems.d.ts +0 -23
- package/lib/operations/retrieveSynonymSetItems.d.ts.map +0 -1
- package/lib/operations/retrieveSynonymSetItems.js +0 -30
- package/lib/operations/retrieveSynonymSetItems.js.map +0 -1
- package/lib/operations/retrieveSynonymSets.d.ts +0 -22
- package/lib/operations/retrieveSynonymSets.d.ts.map +0 -1
- package/lib/operations/retrieveSynonymSets.js +0 -27
- package/lib/operations/retrieveSynonymSets.js.map +0 -1
- package/lib/operations/searchCollection.d.ts +0 -129
- package/lib/operations/searchCollection.d.ts.map +0 -1
- package/lib/operations/searchCollection.js +0 -137
- package/lib/operations/searchCollection.js.map +0 -1
- package/lib/operations/takeSnapshot.d.ts +0 -18
- package/lib/operations/takeSnapshot.d.ts.map +0 -1
- package/lib/operations/takeSnapshot.js +0 -22
- package/lib/operations/takeSnapshot.js.map +0 -1
- package/lib/operations/toggleSlowRequestLog.d.ts +0 -16
- package/lib/operations/toggleSlowRequestLog.d.ts.map +0 -1
- package/lib/operations/toggleSlowRequestLog.js +0 -22
- package/lib/operations/toggleSlowRequestLog.js.map +0 -1
- package/lib/operations/updateCollection.d.ts +0 -95
- package/lib/operations/updateCollection.d.ts.map +0 -1
- package/lib/operations/updateCollection.js +0 -101
- package/lib/operations/updateCollection.js.map +0 -1
- package/lib/operations/updateConversationModel.d.ts +0 -27
- package/lib/operations/updateConversationModel.d.ts.map +0 -1
- package/lib/operations/updateConversationModel.js +0 -35
- package/lib/operations/updateConversationModel.js.map +0 -1
- package/lib/operations/updateDocument.d.ts +0 -21
- package/lib/operations/updateDocument.d.ts.map +0 -1
- package/lib/operations/updateDocument.js +0 -30
- package/lib/operations/updateDocument.js.map +0 -1
- package/lib/operations/updateDocuments.d.ts +0 -20
- package/lib/operations/updateDocuments.d.ts.map +0 -1
- package/lib/operations/updateDocuments.js +0 -25
- package/lib/operations/updateDocuments.js.map +0 -1
- package/lib/operations/updateNLSearchModel.d.ts +0 -19
- package/lib/operations/updateNLSearchModel.d.ts.map +0 -1
- package/lib/operations/updateNLSearchModel.js +0 -26
- package/lib/operations/updateNLSearchModel.js.map +0 -1
- package/lib/operations/upsertAlias.d.ts +0 -21
- package/lib/operations/upsertAlias.d.ts.map +0 -1
- package/lib/operations/upsertAlias.js +0 -26
- package/lib/operations/upsertAlias.js.map +0 -1
- package/lib/operations/upsertAnalyticsRule.d.ts +0 -43
- package/lib/operations/upsertAnalyticsRule.d.ts.map +0 -1
- package/lib/operations/upsertAnalyticsRule.js +0 -55
- package/lib/operations/upsertAnalyticsRule.js.map +0 -1
- package/lib/operations/upsertCurationSet.d.ts +0 -71
- package/lib/operations/upsertCurationSet.d.ts.map +0 -1
- package/lib/operations/upsertCurationSet.js +0 -77
- package/lib/operations/upsertCurationSet.js.map +0 -1
- package/lib/operations/upsertCurationSetItem.d.ts +0 -66
- package/lib/operations/upsertCurationSetItem.d.ts.map +0 -1
- package/lib/operations/upsertCurationSetItem.js +0 -76
- package/lib/operations/upsertCurationSetItem.js.map +0 -1
- package/lib/operations/upsertPreset.d.ts +0 -311
- package/lib/operations/upsertPreset.d.ts.map +0 -1
- package/lib/operations/upsertPreset.js +0 -26
- package/lib/operations/upsertPreset.js.map +0 -1
- package/lib/operations/upsertStopwordsSet.d.ts +0 -23
- package/lib/operations/upsertStopwordsSet.d.ts.map +0 -1
- package/lib/operations/upsertStopwordsSet.js +0 -30
- package/lib/operations/upsertStopwordsSet.js.map +0 -1
- package/lib/operations/upsertSynonymSet.d.ts +0 -33
- package/lib/operations/upsertSynonymSet.d.ts.map +0 -1
- package/lib/operations/upsertSynonymSet.js +0 -38
- package/lib/operations/upsertSynonymSet.js.map +0 -1
- package/lib/operations/upsertSynonymSetItem.d.ts +0 -29
- package/lib/operations/upsertSynonymSetItem.d.ts.map +0 -1
- package/lib/operations/upsertSynonymSetItem.js +0 -39
- package/lib/operations/upsertSynonymSetItem.js.map +0 -1
- package/lib/operations/vote.d.ts +0 -15
- package/lib/operations/vote.d.ts.map +0 -1
- package/lib/operations/vote.js +0 -18
- package/lib/operations/vote.js.map +0 -1
- package/lib/sensitive.d.ts +0 -5
- package/lib/sensitive.d.ts.map +0 -1
- package/lib/sensitive.js +0 -5
- package/lib/sensitive.js.map +0 -1
- package/src/category.ts +0 -4
- package/src/client.ts +0 -71
- package/src/operations/clearCache.ts +0 -28
- package/src/operations/compactDb.ts +0 -28
- package/src/operations/createAnalyticsEvent.ts +0 -52
- package/src/operations/createAnalyticsRule.ts +0 -117
- package/src/operations/createCollection.ts +0 -228
- package/src/operations/createConversationModel.ts +0 -54
- package/src/operations/createKey.ts +0 -54
- package/src/operations/createNLSearchModel.ts +0 -74
- package/src/operations/debug.ts +0 -26
- package/src/operations/deleteAlias.ts +0 -36
- package/src/operations/deleteAnalyticsRule.ts +0 -71
- package/src/operations/deleteCollection.ts +0 -136
- package/src/operations/deleteConversationModel.ts +0 -36
- package/src/operations/deleteCurationSet.ts +0 -37
- package/src/operations/deleteCurationSetItem.ts +0 -44
- package/src/operations/deleteDocument.ts +0 -39
- package/src/operations/deleteDocuments.ts +0 -38
- package/src/operations/deleteKey.ts +0 -34
- package/src/operations/deleteNLSearchModel.ts +0 -38
- package/src/operations/deletePreset.ts +0 -36
- package/src/operations/deleteStopwordsSet.ts +0 -38
- package/src/operations/deleteSynonymSet.ts +0 -36
- package/src/operations/deleteSynonymSetItem.ts +0 -44
- package/src/operations/exportDocuments.ts +0 -38
- package/src/operations/flushAnalytics.ts +0 -28
- package/src/operations/getAlias.ts +0 -38
- package/src/operations/getAliases.ts +0 -33
- package/src/operations/getAnalyticsEvents.ts +0 -63
- package/src/operations/getAnalyticsStatus.ts +0 -42
- package/src/operations/getCollection.ts +0 -136
- package/src/operations/getCollections.ts +0 -134
- package/src/operations/getDocument.ts +0 -39
- package/src/operations/getKey.ts +0 -48
- package/src/operations/getKeys.ts +0 -44
- package/src/operations/getSchemaChanges.ts +0 -34
- package/src/operations/getStemmingDictionary.ts +0 -45
- package/src/operations/health.ts +0 -26
- package/src/operations/importDocuments.ts +0 -38
- package/src/operations/importStemmingDictionary.ts +0 -34
- package/src/operations/index.ts +0 -79
- package/src/operations/indexDocument.ts +0 -39
- package/src/operations/listStemmingDictionaries.ts +0 -30
- package/src/operations/multiSearch.ts +0 -476
- package/src/operations/retrieveAPIStats.ts +0 -52
- package/src/operations/retrieveAllConversationModels.ts +0 -31
- package/src/operations/retrieveAllNLSearchModels.ts +0 -30
- package/src/operations/retrieveAllPresets.ts +0 -188
- package/src/operations/retrieveAnalyticsRule.ts +0 -71
- package/src/operations/retrieveAnalyticsRules.ts +0 -71
- package/src/operations/retrieveConversationModel.ts +0 -36
- package/src/operations/retrieveCurationSet.ts +0 -95
- package/src/operations/retrieveCurationSetItem.ts +0 -91
- package/src/operations/retrieveCurationSetItems.ts +0 -87
- package/src/operations/retrieveCurationSets.ts +0 -89
- package/src/operations/retrieveMetrics.ts +0 -25
- package/src/operations/retrieveNLSearchModel.ts +0 -38
- package/src/operations/retrievePreset.ts +0 -185
- package/src/operations/retrieveStopwordsSet.ts +0 -42
- package/src/operations/retrieveStopwordsSets.ts +0 -36
- package/src/operations/retrieveSynonymSet.ts +0 -54
- package/src/operations/retrieveSynonymSetItem.ts +0 -52
- package/src/operations/retrieveSynonymSetItems.ts +0 -48
- package/src/operations/retrieveSynonymSets.ts +0 -48
- package/src/operations/searchCollection.ts +0 -309
- package/src/operations/takeSnapshot.ts +0 -34
- package/src/operations/toggleSlowRequestLog.ts +0 -34
- package/src/operations/updateCollection.ts +0 -200
- package/src/operations/updateConversationModel.ts +0 -56
- package/src/operations/updateDocument.ts +0 -42
- package/src/operations/updateDocuments.ts +0 -38
- package/src/operations/updateNLSearchModel.ts +0 -38
- package/src/operations/upsertAlias.ts +0 -40
- package/src/operations/upsertAnalyticsRule.ts +0 -95
- package/src/operations/upsertCurationSet.ts +0 -151
- package/src/operations/upsertCurationSetItem.ts +0 -140
- package/src/operations/upsertPreset.ts +0 -334
- package/src/operations/upsertStopwordsSet.ts +0 -46
- package/src/operations/upsertSynonymSet.ts +0 -68
- package/src/operations/upsertSynonymSetItem.ts +0 -60
- package/src/operations/vote.ts +0 -28
- package/src/sensitive.ts +0 -4
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import * as Schema from "effect/Schema";
|
|
2
|
-
import { BadRequest } from "../errors.ts";
|
|
3
|
-
export interface UpsertSynonymSetItemInput {
|
|
4
|
-
synonymSetName: string;
|
|
5
|
-
itemId: string;
|
|
6
|
-
synonyms: string[];
|
|
7
|
-
root?: string;
|
|
8
|
-
locale?: string;
|
|
9
|
-
symbols_to_index?: string[];
|
|
10
|
-
}
|
|
11
|
-
export declare const UpsertSynonymSetItemInput: Schema.Codec<UpsertSynonymSetItemInput>;
|
|
12
|
-
export interface UpsertSynonymSetItemOutput {
|
|
13
|
-
id: string;
|
|
14
|
-
synonyms: string[];
|
|
15
|
-
root?: string;
|
|
16
|
-
locale?: string;
|
|
17
|
-
symbols_to_index?: string[];
|
|
18
|
-
}
|
|
19
|
-
export declare const UpsertSynonymSetItemOutput: Schema.Codec<UpsertSynonymSetItemOutput>;
|
|
20
|
-
/**
|
|
21
|
-
* Create or update a synonym set item
|
|
22
|
-
*
|
|
23
|
-
* Create or update a synonym set item with the given id
|
|
24
|
-
*
|
|
25
|
-
* @param synonymSetName - The name of the synonym set
|
|
26
|
-
* @param itemId - The id of the synonym item to upsert
|
|
27
|
-
*/
|
|
28
|
-
export declare const upsertSynonymSetItem: import("@distilled.cloud/core/client").OperationMethod<UpsertSynonymSetItemInput, UpsertSynonymSetItemOutput, BadRequest, import("../credentials.ts").Credentials, never>;
|
|
29
|
-
//# sourceMappingURL=upsertSynonymSetItem.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"upsertSynonymSetItem.d.ts","sourceRoot":"","sources":["../../src/operations/upsertSynonymSetItem.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAGxC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAG1C,MAAM,WAAW,yBAAyB;IACxC,cAAc,EAAE,MAAM,CAAC;IACvB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;CAC7B;AACD,eAAO,MAAM,yBAAyB,EAapB,MAAM,CAAC,KAAK,CAAC,yBAAyB,CAAC,CAAC;AAG1D,MAAM,WAAW,0BAA0B;IACzC,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;CAC7B;AACD,eAAO,MAAM,0BAA0B,EAOpB,MAAM,CAAC,KAAK,CAAC,0BAA0B,CAAC,CAAC;AAG5D;;;;;;;GAOG;AACH,eAAO,MAAM,oBAAoB,2KAI9B,CAAC"}
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import * as Schema from "effect/Schema";
|
|
2
|
-
import { API } from "../client.js";
|
|
3
|
-
import * as T from "../traits.js";
|
|
4
|
-
import { BadRequest } from "../errors.js";
|
|
5
|
-
export const UpsertSynonymSetItemInput =
|
|
6
|
-
/*@__PURE__*/ Schema.Struct({
|
|
7
|
-
synonymSetName: Schema.String.pipe(T.PathParam()),
|
|
8
|
-
itemId: Schema.String.pipe(T.PathParam()),
|
|
9
|
-
synonyms: Schema.Array(Schema.String),
|
|
10
|
-
root: Schema.optional(Schema.String),
|
|
11
|
-
locale: Schema.optional(Schema.String),
|
|
12
|
-
symbols_to_index: Schema.optional(Schema.Array(Schema.String)),
|
|
13
|
-
}).pipe(T.Http({
|
|
14
|
-
method: "PUT",
|
|
15
|
-
path: "/synonym_sets/{synonymSetName}/items/{itemId}",
|
|
16
|
-
}));
|
|
17
|
-
export const UpsertSynonymSetItemOutput =
|
|
18
|
-
/*@__PURE__*/ Schema.Struct({
|
|
19
|
-
id: Schema.String,
|
|
20
|
-
synonyms: Schema.Array(Schema.String),
|
|
21
|
-
root: Schema.optional(Schema.String),
|
|
22
|
-
locale: Schema.optional(Schema.String),
|
|
23
|
-
symbols_to_index: Schema.optional(Schema.Array(Schema.String)),
|
|
24
|
-
});
|
|
25
|
-
// The operation
|
|
26
|
-
/**
|
|
27
|
-
* Create or update a synonym set item
|
|
28
|
-
*
|
|
29
|
-
* Create or update a synonym set item with the given id
|
|
30
|
-
*
|
|
31
|
-
* @param synonymSetName - The name of the synonym set
|
|
32
|
-
* @param itemId - The id of the synonym item to upsert
|
|
33
|
-
*/
|
|
34
|
-
export const upsertSynonymSetItem = /*@__PURE__*/ API.make(() => ({
|
|
35
|
-
inputSchema: UpsertSynonymSetItemInput,
|
|
36
|
-
outputSchema: UpsertSynonymSetItemOutput,
|
|
37
|
-
errors: [BadRequest],
|
|
38
|
-
}));
|
|
39
|
-
//# sourceMappingURL=upsertSynonymSetItem.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"upsertSynonymSetItem.js","sourceRoot":"","sources":["../../src/operations/upsertSynonymSetItem.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,GAAG,EAAE,MAAM,cAAc,CAAC;AACnC,OAAO,KAAK,CAAC,MAAM,cAAc,CAAC;AAClC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAW1C,MAAM,CAAC,MAAM,yBAAyB;AACpC,aAAa,CAAC,MAAM,CAAC,MAAM,CAAC;IAC1B,cAAc,EAAE,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,EAAE,CAAC;IACjD,MAAM,EAAE,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,EAAE,CAAC;IACzC,QAAQ,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,CAAC;IACrC,IAAI,EAAE,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,MAAM,CAAC;IACpC,MAAM,EAAE,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,MAAM,CAAC;IACtC,gBAAgB,EAAE,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;CAC/D,CAAC,CAAC,IAAI,CACL,CAAC,CAAC,IAAI,CAAC;IACL,MAAM,EAAE,KAAK;IACb,IAAI,EAAE,+CAA+C;CACtD,CAAC,CACmD,CAAC;AAU1D,MAAM,CAAC,MAAM,0BAA0B;AACrC,aAAa,CAAC,MAAM,CAAC,MAAM,CAAC;IAC1B,EAAE,EAAE,MAAM,CAAC,MAAM;IACjB,QAAQ,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,CAAC;IACrC,IAAI,EAAE,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,MAAM,CAAC;IACpC,MAAM,EAAE,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,MAAM,CAAC;IACtC,gBAAgB,EAAE,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;CAC/D,CAAwD,CAAC;AAE5D,gBAAgB;AAChB;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,aAAa,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC;IAChE,WAAW,EAAE,yBAAyB;IACtC,YAAY,EAAE,0BAA0B;IACxC,MAAM,EAAE,CAAC,UAAU,CAAU;CAC9B,CAAC,CAAC,CAAC"}
|
package/lib/operations/vote.d.ts
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import * as Schema from "effect/Schema";
|
|
2
|
-
export interface VoteInput {
|
|
3
|
-
}
|
|
4
|
-
export declare const VoteInput: Schema.Codec<VoteInput>;
|
|
5
|
-
export interface VoteOutput {
|
|
6
|
-
success: boolean;
|
|
7
|
-
}
|
|
8
|
-
export declare const VoteOutput: Schema.Codec<VoteOutput>;
|
|
9
|
-
/**
|
|
10
|
-
* Triggers a follower node to initiate the raft voting process, which triggers leader re-election.
|
|
11
|
-
*
|
|
12
|
-
* Triggers a follower node to initiate the raft voting process, which triggers leader re-election. The follower node that you run this operation against will become the new leader, once this command succeeds.
|
|
13
|
-
*/
|
|
14
|
-
export declare const vote: import("@distilled.cloud/core/client").OperationMethod<VoteInput, VoteOutput, never, import("../credentials.ts").Credentials, never>;
|
|
15
|
-
//# sourceMappingURL=vote.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"vote.d.ts","sourceRoot":"","sources":["../../src/operations/vote.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAKxC,MAAM,WAAW,SAAS;CAAG;AAC7B,eAAO,MAAM,SAAS,EAEN,MAAM,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC;AAGxC,MAAM,WAAW,UAAU;IACzB,OAAO,EAAE,OAAO,CAAC;CAClB;AACD,eAAO,MAAM,UAAU,EAEN,MAAM,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC;AAG1C;;;;GAIG;AACH,eAAO,MAAM,IAAI,sIAGd,CAAC"}
|
package/lib/operations/vote.js
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import * as Schema from "effect/Schema";
|
|
2
|
-
import { API } from "../client.js";
|
|
3
|
-
import * as T from "../traits.js";
|
|
4
|
-
export const VoteInput = /*@__PURE__*/ Schema.Struct({}).pipe(T.Http({ method: "POST", path: "/operations/vote" }));
|
|
5
|
-
export const VoteOutput = /*@__PURE__*/ Schema.Struct({
|
|
6
|
-
success: Schema.Boolean,
|
|
7
|
-
});
|
|
8
|
-
// The operation
|
|
9
|
-
/**
|
|
10
|
-
* Triggers a follower node to initiate the raft voting process, which triggers leader re-election.
|
|
11
|
-
*
|
|
12
|
-
* Triggers a follower node to initiate the raft voting process, which triggers leader re-election. The follower node that you run this operation against will become the new leader, once this command succeeds.
|
|
13
|
-
*/
|
|
14
|
-
export const vote = /*@__PURE__*/ API.make(() => ({
|
|
15
|
-
inputSchema: VoteInput,
|
|
16
|
-
outputSchema: VoteOutput,
|
|
17
|
-
}));
|
|
18
|
-
//# sourceMappingURL=vote.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"vote.js","sourceRoot":"","sources":["../../src/operations/vote.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,GAAG,EAAE,MAAM,cAAc,CAAC;AACnC,OAAO,KAAK,CAAC,MAAM,cAAc,CAAC;AAIlC,MAAM,CAAC,MAAM,SAAS,GAAG,aAAa,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,IAAI,CAC3D,CAAC,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,kBAAkB,EAAE,CAAC,CACf,CAAC;AAMxC,MAAM,CAAC,MAAM,UAAU,GAAG,aAAa,CAAC,MAAM,CAAC,MAAM,CAAC;IACpD,OAAO,EAAE,MAAM,CAAC,OAAO;CACxB,CAAwC,CAAC;AAE1C,gBAAgB;AAChB;;;;GAIG;AACH,MAAM,CAAC,MAAM,IAAI,GAAG,aAAa,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC;IAChD,WAAW,EAAE,SAAS;IACtB,YAAY,EAAE,UAAU;CACzB,CAAC,CAAC,CAAC"}
|
package/lib/sensitive.d.ts
DELETED
package/lib/sensitive.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sensitive.d.ts","sourceRoot":"","sources":["../src/sensitive.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,cAAc,iCAAiC,CAAC"}
|
package/lib/sensitive.js
DELETED
package/lib/sensitive.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sensitive.js","sourceRoot":"","sources":["../src/sensitive.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,cAAc,iCAAiC,CAAC"}
|
package/src/category.ts
DELETED
package/src/client.ts
DELETED
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Typesense API Client.
|
|
3
|
-
*
|
|
4
|
-
* Wraps the shared REST client from sdk-core with Typesense-specific
|
|
5
|
-
* error matching and credential handling.
|
|
6
|
-
*/
|
|
7
|
-
import * as Effect from "effect/Effect";
|
|
8
|
-
import * as Redacted from "effect/Redacted";
|
|
9
|
-
import * as Schema from "effect/Schema";
|
|
10
|
-
import { makeAPI } from "@distilled.cloud/core/client";
|
|
11
|
-
import { parseRetryAfterForStatus } from "@distilled.cloud/core/retry-after";
|
|
12
|
-
import { Retry } from "./retry.ts";
|
|
13
|
-
import {
|
|
14
|
-
HTTP_STATUS_MAP,
|
|
15
|
-
UnknownTypesenseError,
|
|
16
|
-
TypesenseParseError,
|
|
17
|
-
} from "./errors.ts";
|
|
18
|
-
|
|
19
|
-
// Re-export for backwards compatibility
|
|
20
|
-
export { UnknownTypesenseError } from "./errors.ts";
|
|
21
|
-
import { Credentials } from "./credentials.ts";
|
|
22
|
-
|
|
23
|
-
// API Error Response Schema (Typesense ApiResponse: { message: string })
|
|
24
|
-
const ApiErrorResponse = Schema.Struct({
|
|
25
|
-
message: Schema.String,
|
|
26
|
-
});
|
|
27
|
-
|
|
28
|
-
/**
|
|
29
|
-
* Match a Typesense API error response to the appropriate error class based on HTTP status.
|
|
30
|
-
*/
|
|
31
|
-
const matchError = (
|
|
32
|
-
status: number,
|
|
33
|
-
errorBody: unknown,
|
|
34
|
-
_errors?: readonly unknown[],
|
|
35
|
-
headers?: Record<string, string | undefined>,
|
|
36
|
-
): Effect.Effect<never, unknown> => {
|
|
37
|
-
try {
|
|
38
|
-
const parsed = Schema.decodeUnknownSync(ApiErrorResponse)(errorBody);
|
|
39
|
-
const ErrorClass = (HTTP_STATUS_MAP as any)[status];
|
|
40
|
-
if (ErrorClass) {
|
|
41
|
-
return Effect.fail(
|
|
42
|
-
new ErrorClass({
|
|
43
|
-
message: parsed.message ?? "",
|
|
44
|
-
retryAfter: parseRetryAfterForStatus(status, headers),
|
|
45
|
-
}),
|
|
46
|
-
);
|
|
47
|
-
}
|
|
48
|
-
return Effect.fail(
|
|
49
|
-
new UnknownTypesenseError({
|
|
50
|
-
message: parsed.message,
|
|
51
|
-
body: errorBody,
|
|
52
|
-
}),
|
|
53
|
-
);
|
|
54
|
-
} catch {
|
|
55
|
-
return Effect.fail(new UnknownTypesenseError({ body: errorBody }));
|
|
56
|
-
}
|
|
57
|
-
};
|
|
58
|
-
|
|
59
|
-
/**
|
|
60
|
-
* Typesense API client.
|
|
61
|
-
*/
|
|
62
|
-
export const API = makeAPI<Credentials>({
|
|
63
|
-
credentials: Credentials as any,
|
|
64
|
-
getBaseUrl: (creds: any) => creds.apiBaseUrl,
|
|
65
|
-
getAuthHeaders: (creds: any) => ({
|
|
66
|
-
"X-TYPESENSE-API-KEY": Redacted.value(creds.apiKey),
|
|
67
|
-
}),
|
|
68
|
-
matchError,
|
|
69
|
-
ParseError: TypesenseParseError as any,
|
|
70
|
-
retry: Retry as any,
|
|
71
|
-
});
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import * as Schema from "effect/Schema";
|
|
2
|
-
import { API } from "../client.ts";
|
|
3
|
-
import * as T from "../traits.ts";
|
|
4
|
-
|
|
5
|
-
// Input Schema
|
|
6
|
-
export interface ClearCacheInput {}
|
|
7
|
-
export const ClearCacheInput = /*@__PURE__*/ Schema.Struct({}).pipe(
|
|
8
|
-
T.Http({ method: "POST", path: "/operations/cache/clear" }),
|
|
9
|
-
) as unknown as Schema.Codec<ClearCacheInput>;
|
|
10
|
-
|
|
11
|
-
// Output Schema
|
|
12
|
-
export interface ClearCacheOutput {
|
|
13
|
-
success: boolean;
|
|
14
|
-
}
|
|
15
|
-
export const ClearCacheOutput = /*@__PURE__*/ Schema.Struct({
|
|
16
|
-
success: Schema.Boolean,
|
|
17
|
-
}) as unknown as Schema.Codec<ClearCacheOutput>;
|
|
18
|
-
|
|
19
|
-
// The operation
|
|
20
|
-
/**
|
|
21
|
-
* Clear the cached responses of search requests in the LRU cache.
|
|
22
|
-
*
|
|
23
|
-
* Clear the cached responses of search requests that are sent with `use_cache` parameter in the LRU cache.
|
|
24
|
-
*/
|
|
25
|
-
export const clearCache = /*@__PURE__*/ API.make(() => ({
|
|
26
|
-
inputSchema: ClearCacheInput,
|
|
27
|
-
outputSchema: ClearCacheOutput,
|
|
28
|
-
}));
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import * as Schema from "effect/Schema";
|
|
2
|
-
import { API } from "../client.ts";
|
|
3
|
-
import * as T from "../traits.ts";
|
|
4
|
-
|
|
5
|
-
// Input Schema
|
|
6
|
-
export interface CompactDbInput {}
|
|
7
|
-
export const CompactDbInput = /*@__PURE__*/ Schema.Struct({}).pipe(
|
|
8
|
-
T.Http({ method: "POST", path: "/operations/db/compact" }),
|
|
9
|
-
) as unknown as Schema.Codec<CompactDbInput>;
|
|
10
|
-
|
|
11
|
-
// Output Schema
|
|
12
|
-
export interface CompactDbOutput {
|
|
13
|
-
success: boolean;
|
|
14
|
-
}
|
|
15
|
-
export const CompactDbOutput = /*@__PURE__*/ Schema.Struct({
|
|
16
|
-
success: Schema.Boolean,
|
|
17
|
-
}) as unknown as Schema.Codec<CompactDbOutput>;
|
|
18
|
-
|
|
19
|
-
// The operation
|
|
20
|
-
/**
|
|
21
|
-
* Compacting the on-disk database
|
|
22
|
-
*
|
|
23
|
-
* Typesense uses RocksDB to store your documents on the disk. If you do frequent writes or updates, you could benefit from running a compaction of the underlying RocksDB database. This could reduce the size of the database and decrease read latency. While the database will not block during this operation, we recommend running it during off-peak hours.
|
|
24
|
-
*/
|
|
25
|
-
export const compactDb = /*@__PURE__*/ API.make(() => ({
|
|
26
|
-
inputSchema: CompactDbInput,
|
|
27
|
-
outputSchema: CompactDbOutput,
|
|
28
|
-
}));
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import * as Schema from "effect/Schema";
|
|
2
|
-
import { API } from "../client.ts";
|
|
3
|
-
import * as T from "../traits.ts";
|
|
4
|
-
import { BadRequest } from "../errors.ts";
|
|
5
|
-
|
|
6
|
-
// Input Schema
|
|
7
|
-
export interface CreateAnalyticsEventInput {
|
|
8
|
-
name: string;
|
|
9
|
-
event_type: string;
|
|
10
|
-
data: {
|
|
11
|
-
user_id?: string;
|
|
12
|
-
doc_id?: string;
|
|
13
|
-
doc_ids?: string[];
|
|
14
|
-
q?: string;
|
|
15
|
-
analytics_tag?: string;
|
|
16
|
-
};
|
|
17
|
-
}
|
|
18
|
-
export const CreateAnalyticsEventInput =
|
|
19
|
-
/*@__PURE__*/ Schema.Struct({
|
|
20
|
-
name: Schema.String,
|
|
21
|
-
event_type: Schema.String,
|
|
22
|
-
data: Schema.Struct({
|
|
23
|
-
user_id: Schema.optional(Schema.String),
|
|
24
|
-
doc_id: Schema.optional(Schema.String),
|
|
25
|
-
doc_ids: Schema.optional(Schema.Array(Schema.String)),
|
|
26
|
-
q: Schema.optional(Schema.String),
|
|
27
|
-
analytics_tag: Schema.optional(Schema.String),
|
|
28
|
-
}),
|
|
29
|
-
}).pipe(
|
|
30
|
-
T.Http({ method: "POST", path: "/analytics/events" }),
|
|
31
|
-
) as unknown as Schema.Codec<CreateAnalyticsEventInput>;
|
|
32
|
-
|
|
33
|
-
// Output Schema
|
|
34
|
-
export interface CreateAnalyticsEventOutput {
|
|
35
|
-
ok: boolean;
|
|
36
|
-
}
|
|
37
|
-
export const CreateAnalyticsEventOutput =
|
|
38
|
-
/*@__PURE__*/ Schema.Struct({
|
|
39
|
-
ok: Schema.Boolean,
|
|
40
|
-
}) as unknown as Schema.Codec<CreateAnalyticsEventOutput>;
|
|
41
|
-
|
|
42
|
-
// The operation
|
|
43
|
-
/**
|
|
44
|
-
* Create an analytics event
|
|
45
|
-
*
|
|
46
|
-
* Submit a single analytics event. The event must correspond to an existing analytics rule by name.
|
|
47
|
-
*/
|
|
48
|
-
export const createAnalyticsEvent = /*@__PURE__*/ API.make(() => ({
|
|
49
|
-
inputSchema: CreateAnalyticsEventInput,
|
|
50
|
-
outputSchema: CreateAnalyticsEventOutput,
|
|
51
|
-
errors: [BadRequest] as const,
|
|
52
|
-
}));
|
|
@@ -1,117 +0,0 @@
|
|
|
1
|
-
import * as Schema from "effect/Schema";
|
|
2
|
-
import { API } from "../client.ts";
|
|
3
|
-
import * as T from "../traits.ts";
|
|
4
|
-
import { BadRequest } from "../errors.ts";
|
|
5
|
-
|
|
6
|
-
// Input Schema
|
|
7
|
-
export interface CreateAnalyticsRuleInput {}
|
|
8
|
-
export const CreateAnalyticsRuleInput =
|
|
9
|
-
/*@__PURE__*/ Schema.Struct({}).pipe(
|
|
10
|
-
T.Http({ method: "POST", path: "/analytics/rules" }),
|
|
11
|
-
) as unknown as Schema.Codec<CreateAnalyticsRuleInput>;
|
|
12
|
-
|
|
13
|
-
// Output Schema
|
|
14
|
-
export type CreateAnalyticsRuleOutput =
|
|
15
|
-
| {
|
|
16
|
-
name: string;
|
|
17
|
-
type: "popular_queries" | "nohits_queries" | "counter" | "log";
|
|
18
|
-
collection: string;
|
|
19
|
-
event_type: string;
|
|
20
|
-
rule_tag?: string;
|
|
21
|
-
params?: {
|
|
22
|
-
destination_collection?: string;
|
|
23
|
-
limit?: number;
|
|
24
|
-
capture_search_requests?: boolean;
|
|
25
|
-
meta_fields?: string[];
|
|
26
|
-
expand_query?: boolean;
|
|
27
|
-
counter_field?: string;
|
|
28
|
-
weight?: number;
|
|
29
|
-
};
|
|
30
|
-
}
|
|
31
|
-
| (
|
|
32
|
-
| {
|
|
33
|
-
name: string;
|
|
34
|
-
type: "popular_queries" | "nohits_queries" | "counter" | "log";
|
|
35
|
-
collection: string;
|
|
36
|
-
event_type: string;
|
|
37
|
-
rule_tag?: string;
|
|
38
|
-
params?: {
|
|
39
|
-
destination_collection?: string;
|
|
40
|
-
limit?: number;
|
|
41
|
-
capture_search_requests?: boolean;
|
|
42
|
-
meta_fields?: string[];
|
|
43
|
-
expand_query?: boolean;
|
|
44
|
-
counter_field?: string;
|
|
45
|
-
weight?: number;
|
|
46
|
-
};
|
|
47
|
-
}
|
|
48
|
-
| { error?: string }
|
|
49
|
-
)[];
|
|
50
|
-
export const CreateAnalyticsRuleOutput =
|
|
51
|
-
/*@__PURE__*/ Schema.Union([
|
|
52
|
-
Schema.Struct({
|
|
53
|
-
name: Schema.String,
|
|
54
|
-
type: Schema.Literals([
|
|
55
|
-
"popular_queries",
|
|
56
|
-
"nohits_queries",
|
|
57
|
-
"counter",
|
|
58
|
-
"log",
|
|
59
|
-
]),
|
|
60
|
-
collection: Schema.String,
|
|
61
|
-
event_type: Schema.String,
|
|
62
|
-
rule_tag: Schema.optional(Schema.String),
|
|
63
|
-
params: Schema.optional(
|
|
64
|
-
Schema.Struct({
|
|
65
|
-
destination_collection: Schema.optional(Schema.String),
|
|
66
|
-
limit: Schema.optional(Schema.Number),
|
|
67
|
-
capture_search_requests: Schema.optional(Schema.Boolean),
|
|
68
|
-
meta_fields: Schema.optional(Schema.Array(Schema.String)),
|
|
69
|
-
expand_query: Schema.optional(Schema.Boolean),
|
|
70
|
-
counter_field: Schema.optional(Schema.String),
|
|
71
|
-
weight: Schema.optional(Schema.Number),
|
|
72
|
-
}),
|
|
73
|
-
),
|
|
74
|
-
}),
|
|
75
|
-
Schema.Array(
|
|
76
|
-
Schema.Union([
|
|
77
|
-
Schema.Struct({
|
|
78
|
-
name: Schema.String,
|
|
79
|
-
type: Schema.Literals([
|
|
80
|
-
"popular_queries",
|
|
81
|
-
"nohits_queries",
|
|
82
|
-
"counter",
|
|
83
|
-
"log",
|
|
84
|
-
]),
|
|
85
|
-
collection: Schema.String,
|
|
86
|
-
event_type: Schema.String,
|
|
87
|
-
rule_tag: Schema.optional(Schema.String),
|
|
88
|
-
params: Schema.optional(
|
|
89
|
-
Schema.Struct({
|
|
90
|
-
destination_collection: Schema.optional(Schema.String),
|
|
91
|
-
limit: Schema.optional(Schema.Number),
|
|
92
|
-
capture_search_requests: Schema.optional(Schema.Boolean),
|
|
93
|
-
meta_fields: Schema.optional(Schema.Array(Schema.String)),
|
|
94
|
-
expand_query: Schema.optional(Schema.Boolean),
|
|
95
|
-
counter_field: Schema.optional(Schema.String),
|
|
96
|
-
weight: Schema.optional(Schema.Number),
|
|
97
|
-
}),
|
|
98
|
-
),
|
|
99
|
-
}),
|
|
100
|
-
Schema.Struct({
|
|
101
|
-
error: Schema.optional(Schema.String),
|
|
102
|
-
}),
|
|
103
|
-
]),
|
|
104
|
-
),
|
|
105
|
-
]) as unknown as Schema.Codec<CreateAnalyticsRuleOutput>;
|
|
106
|
-
|
|
107
|
-
// The operation
|
|
108
|
-
/**
|
|
109
|
-
* Create analytics rule(s)
|
|
110
|
-
*
|
|
111
|
-
* Create one or more analytics rules. You can send a single rule object or an array of rule objects.
|
|
112
|
-
*/
|
|
113
|
-
export const createAnalyticsRule = /*@__PURE__*/ API.make(() => ({
|
|
114
|
-
inputSchema: CreateAnalyticsRuleInput,
|
|
115
|
-
outputSchema: CreateAnalyticsRuleOutput,
|
|
116
|
-
errors: [BadRequest] as const,
|
|
117
|
-
}));
|
|
@@ -1,228 +0,0 @@
|
|
|
1
|
-
import * as Schema from "effect/Schema";
|
|
2
|
-
import { API } from "../client.ts";
|
|
3
|
-
import * as T from "../traits.ts";
|
|
4
|
-
import { BadRequest, Conflict } from "../errors.ts";
|
|
5
|
-
import { SensitiveString, SensitiveOutputString } from "../sensitive.ts";
|
|
6
|
-
import * as Redacted from "effect/Redacted";
|
|
7
|
-
|
|
8
|
-
// Input Schema
|
|
9
|
-
export interface CreateCollectionInput {
|
|
10
|
-
name: string;
|
|
11
|
-
fields: {
|
|
12
|
-
name: string;
|
|
13
|
-
type: string;
|
|
14
|
-
optional?: boolean;
|
|
15
|
-
facet?: boolean;
|
|
16
|
-
index?: boolean;
|
|
17
|
-
locale?: string;
|
|
18
|
-
sort?: boolean;
|
|
19
|
-
infix?: boolean;
|
|
20
|
-
reference?: string;
|
|
21
|
-
async_reference?: boolean;
|
|
22
|
-
num_dim?: number;
|
|
23
|
-
drop?: boolean;
|
|
24
|
-
store?: boolean;
|
|
25
|
-
vec_dist?: string;
|
|
26
|
-
range_index?: boolean;
|
|
27
|
-
stem?: boolean;
|
|
28
|
-
stem_dictionary?: string;
|
|
29
|
-
token_separators?: string[];
|
|
30
|
-
symbols_to_index?: string[];
|
|
31
|
-
embed?: {
|
|
32
|
-
from: string[];
|
|
33
|
-
model_config: {
|
|
34
|
-
model_name: string;
|
|
35
|
-
api_key?: string | Redacted.Redacted<string>;
|
|
36
|
-
url?: string;
|
|
37
|
-
access_token?: string | Redacted.Redacted<string>;
|
|
38
|
-
refresh_token?: string | Redacted.Redacted<string>;
|
|
39
|
-
client_id?: string;
|
|
40
|
-
client_secret?: string | Redacted.Redacted<string>;
|
|
41
|
-
project_id?: string;
|
|
42
|
-
indexing_prefix?: string;
|
|
43
|
-
query_prefix?: string;
|
|
44
|
-
};
|
|
45
|
-
};
|
|
46
|
-
}[];
|
|
47
|
-
default_sorting_field?: string;
|
|
48
|
-
token_separators?: string[];
|
|
49
|
-
synonym_sets?: string[];
|
|
50
|
-
enable_nested_fields?: boolean;
|
|
51
|
-
symbols_to_index?: string[];
|
|
52
|
-
voice_query_model?: { model_name?: string };
|
|
53
|
-
metadata?: unknown;
|
|
54
|
-
}
|
|
55
|
-
export const CreateCollectionInput = /*@__PURE__*/ Schema.Struct({
|
|
56
|
-
name: Schema.String,
|
|
57
|
-
fields: Schema.Array(
|
|
58
|
-
Schema.Struct({
|
|
59
|
-
name: Schema.String,
|
|
60
|
-
type: Schema.String,
|
|
61
|
-
optional: Schema.optional(Schema.Boolean),
|
|
62
|
-
facet: Schema.optional(Schema.Boolean),
|
|
63
|
-
index: Schema.optional(Schema.Boolean),
|
|
64
|
-
locale: Schema.optional(Schema.String),
|
|
65
|
-
sort: Schema.optional(Schema.Boolean),
|
|
66
|
-
infix: Schema.optional(Schema.Boolean),
|
|
67
|
-
reference: Schema.optional(Schema.String),
|
|
68
|
-
async_reference: Schema.optional(Schema.Boolean),
|
|
69
|
-
num_dim: Schema.optional(Schema.Number),
|
|
70
|
-
drop: Schema.optional(Schema.Boolean),
|
|
71
|
-
store: Schema.optional(Schema.Boolean),
|
|
72
|
-
vec_dist: Schema.optional(Schema.String),
|
|
73
|
-
range_index: Schema.optional(Schema.Boolean),
|
|
74
|
-
stem: Schema.optional(Schema.Boolean),
|
|
75
|
-
stem_dictionary: Schema.optional(Schema.String),
|
|
76
|
-
token_separators: Schema.optional(Schema.Array(Schema.String)),
|
|
77
|
-
symbols_to_index: Schema.optional(Schema.Array(Schema.String)),
|
|
78
|
-
embed: Schema.optional(
|
|
79
|
-
Schema.Struct({
|
|
80
|
-
from: Schema.Array(Schema.String),
|
|
81
|
-
model_config: Schema.Struct({
|
|
82
|
-
model_name: Schema.String,
|
|
83
|
-
api_key: Schema.optional(SensitiveString),
|
|
84
|
-
url: Schema.optional(Schema.String),
|
|
85
|
-
access_token: Schema.optional(SensitiveString),
|
|
86
|
-
refresh_token: Schema.optional(SensitiveString),
|
|
87
|
-
client_id: Schema.optional(Schema.String),
|
|
88
|
-
client_secret: Schema.optional(SensitiveString),
|
|
89
|
-
project_id: Schema.optional(Schema.String),
|
|
90
|
-
indexing_prefix: Schema.optional(Schema.String),
|
|
91
|
-
query_prefix: Schema.optional(Schema.String),
|
|
92
|
-
}),
|
|
93
|
-
}),
|
|
94
|
-
),
|
|
95
|
-
}),
|
|
96
|
-
),
|
|
97
|
-
default_sorting_field: Schema.optional(Schema.String),
|
|
98
|
-
token_separators: Schema.optional(Schema.Array(Schema.String)),
|
|
99
|
-
synonym_sets: Schema.optional(Schema.Array(Schema.String)),
|
|
100
|
-
enable_nested_fields: Schema.optional(Schema.Boolean),
|
|
101
|
-
symbols_to_index: Schema.optional(Schema.Array(Schema.String)),
|
|
102
|
-
voice_query_model: Schema.optional(
|
|
103
|
-
Schema.Struct({
|
|
104
|
-
model_name: Schema.optional(Schema.String),
|
|
105
|
-
}),
|
|
106
|
-
),
|
|
107
|
-
metadata: Schema.optional(Schema.Unknown),
|
|
108
|
-
}).pipe(
|
|
109
|
-
T.Http({ method: "POST", path: "/collections" }),
|
|
110
|
-
) as unknown as Schema.Codec<CreateCollectionInput>;
|
|
111
|
-
|
|
112
|
-
// Output Schema
|
|
113
|
-
export interface CreateCollectionOutput {
|
|
114
|
-
name: string;
|
|
115
|
-
fields: {
|
|
116
|
-
name: string;
|
|
117
|
-
type: string;
|
|
118
|
-
optional?: boolean;
|
|
119
|
-
facet?: boolean;
|
|
120
|
-
index?: boolean;
|
|
121
|
-
locale?: string;
|
|
122
|
-
sort?: boolean;
|
|
123
|
-
infix?: boolean;
|
|
124
|
-
reference?: string;
|
|
125
|
-
async_reference?: boolean;
|
|
126
|
-
num_dim?: number;
|
|
127
|
-
drop?: boolean;
|
|
128
|
-
store?: boolean;
|
|
129
|
-
vec_dist?: string;
|
|
130
|
-
range_index?: boolean;
|
|
131
|
-
stem?: boolean;
|
|
132
|
-
stem_dictionary?: string;
|
|
133
|
-
token_separators?: string[];
|
|
134
|
-
symbols_to_index?: string[];
|
|
135
|
-
embed?: {
|
|
136
|
-
from: string[];
|
|
137
|
-
model_config: {
|
|
138
|
-
model_name: string;
|
|
139
|
-
api_key?: Redacted.Redacted<string>;
|
|
140
|
-
url?: string;
|
|
141
|
-
access_token?: Redacted.Redacted<string>;
|
|
142
|
-
refresh_token?: Redacted.Redacted<string>;
|
|
143
|
-
client_id?: string;
|
|
144
|
-
client_secret?: Redacted.Redacted<string>;
|
|
145
|
-
project_id?: string;
|
|
146
|
-
indexing_prefix?: string;
|
|
147
|
-
query_prefix?: string;
|
|
148
|
-
};
|
|
149
|
-
};
|
|
150
|
-
}[];
|
|
151
|
-
default_sorting_field?: string;
|
|
152
|
-
token_separators?: string[];
|
|
153
|
-
synonym_sets?: string[];
|
|
154
|
-
enable_nested_fields?: boolean;
|
|
155
|
-
symbols_to_index?: string[];
|
|
156
|
-
voice_query_model?: { model_name?: string };
|
|
157
|
-
metadata?: unknown;
|
|
158
|
-
num_documents: number;
|
|
159
|
-
created_at: number;
|
|
160
|
-
}
|
|
161
|
-
export const CreateCollectionOutput = /*@__PURE__*/ Schema.Struct({
|
|
162
|
-
name: Schema.String,
|
|
163
|
-
fields: Schema.Array(
|
|
164
|
-
Schema.Struct({
|
|
165
|
-
name: Schema.String,
|
|
166
|
-
type: Schema.String,
|
|
167
|
-
optional: Schema.optional(Schema.Boolean),
|
|
168
|
-
facet: Schema.optional(Schema.Boolean),
|
|
169
|
-
index: Schema.optional(Schema.Boolean),
|
|
170
|
-
locale: Schema.optional(Schema.String),
|
|
171
|
-
sort: Schema.optional(Schema.Boolean),
|
|
172
|
-
infix: Schema.optional(Schema.Boolean),
|
|
173
|
-
reference: Schema.optional(Schema.String),
|
|
174
|
-
async_reference: Schema.optional(Schema.Boolean),
|
|
175
|
-
num_dim: Schema.optional(Schema.Number),
|
|
176
|
-
drop: Schema.optional(Schema.Boolean),
|
|
177
|
-
store: Schema.optional(Schema.Boolean),
|
|
178
|
-
vec_dist: Schema.optional(Schema.String),
|
|
179
|
-
range_index: Schema.optional(Schema.Boolean),
|
|
180
|
-
stem: Schema.optional(Schema.Boolean),
|
|
181
|
-
stem_dictionary: Schema.optional(Schema.String),
|
|
182
|
-
token_separators: Schema.optional(Schema.Array(Schema.String)),
|
|
183
|
-
symbols_to_index: Schema.optional(Schema.Array(Schema.String)),
|
|
184
|
-
embed: Schema.optional(
|
|
185
|
-
Schema.Struct({
|
|
186
|
-
from: Schema.Array(Schema.String),
|
|
187
|
-
model_config: Schema.Struct({
|
|
188
|
-
model_name: Schema.String,
|
|
189
|
-
api_key: Schema.optional(SensitiveOutputString),
|
|
190
|
-
url: Schema.optional(Schema.String),
|
|
191
|
-
access_token: Schema.optional(SensitiveOutputString),
|
|
192
|
-
refresh_token: Schema.optional(SensitiveOutputString),
|
|
193
|
-
client_id: Schema.optional(Schema.String),
|
|
194
|
-
client_secret: Schema.optional(SensitiveOutputString),
|
|
195
|
-
project_id: Schema.optional(Schema.String),
|
|
196
|
-
indexing_prefix: Schema.optional(Schema.String),
|
|
197
|
-
query_prefix: Schema.optional(Schema.String),
|
|
198
|
-
}),
|
|
199
|
-
}),
|
|
200
|
-
),
|
|
201
|
-
}),
|
|
202
|
-
),
|
|
203
|
-
default_sorting_field: Schema.optional(Schema.String),
|
|
204
|
-
token_separators: Schema.optional(Schema.Array(Schema.String)),
|
|
205
|
-
synonym_sets: Schema.optional(Schema.Array(Schema.String)),
|
|
206
|
-
enable_nested_fields: Schema.optional(Schema.Boolean),
|
|
207
|
-
symbols_to_index: Schema.optional(Schema.Array(Schema.String)),
|
|
208
|
-
voice_query_model: Schema.optional(
|
|
209
|
-
Schema.Struct({
|
|
210
|
-
model_name: Schema.optional(Schema.String),
|
|
211
|
-
}),
|
|
212
|
-
),
|
|
213
|
-
metadata: Schema.optional(Schema.Unknown),
|
|
214
|
-
num_documents: Schema.Number,
|
|
215
|
-
created_at: Schema.Number,
|
|
216
|
-
}) as unknown as Schema.Codec<CreateCollectionOutput>;
|
|
217
|
-
|
|
218
|
-
// The operation
|
|
219
|
-
/**
|
|
220
|
-
* Create a new collection
|
|
221
|
-
*
|
|
222
|
-
* When a collection is created, we give it a name and describe the fields that will be indexed from the documents added to the collection.
|
|
223
|
-
*/
|
|
224
|
-
export const createCollection = /*@__PURE__*/ API.make(() => ({
|
|
225
|
-
inputSchema: CreateCollectionInput,
|
|
226
|
-
outputSchema: CreateCollectionOutput,
|
|
227
|
-
errors: [BadRequest, Conflict] as const,
|
|
228
|
-
}));
|