mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-04 16:44:56 +00:00
Compare commits
17 Commits
v0.26.0-be
...
hwang/inte
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
cc2b90daa6 | ||
|
|
74819f6141 | ||
|
|
ab758b01b3 | ||
|
|
a505e65f32 | ||
|
|
cbcc708073 | ||
|
|
876ea3a987 | ||
|
|
92887791fc | ||
|
|
1e861e54ee | ||
|
|
c19ef05534 | ||
|
|
ea1e7076d7 | ||
|
|
8065fa4bf4 | ||
|
|
1aca314299 | ||
|
|
f6b281d12f | ||
|
|
6d0516175d | ||
|
|
d3591dcdc1 | ||
|
|
333edab3b6 | ||
|
|
deeca60efa |
@@ -15,7 +15,7 @@ export const passwordLimitsFragment = `fragment PasswordLimits on PasswordLimits
|
||||
minLength
|
||||
maxLength
|
||||
}`;
|
||||
export const licenseFragment = `fragment license on License {
|
||||
export const licenseBodyFragment = `fragment licenseBody on License {
|
||||
expiredAt
|
||||
installedAt
|
||||
quantity
|
||||
@@ -1443,10 +1443,10 @@ export const activateLicenseMutation = {
|
||||
op: 'activateLicense',
|
||||
query: `mutation activateLicense($workspaceId: String!, $license: String!) {
|
||||
activateLicense(workspaceId: $workspaceId, license: $license) {
|
||||
...license
|
||||
...licenseBody
|
||||
}
|
||||
}
|
||||
${licenseFragment}`,
|
||||
${licenseBodyFragment}`,
|
||||
};
|
||||
|
||||
export const deactivateLicenseMutation = {
|
||||
@@ -1463,11 +1463,11 @@ export const getLicenseQuery = {
|
||||
query: `query getLicense($workspaceId: String!) {
|
||||
workspace(id: $workspaceId) {
|
||||
license {
|
||||
...license
|
||||
...licenseBody
|
||||
}
|
||||
}
|
||||
}
|
||||
${licenseFragment}`,
|
||||
${licenseBodyFragment}`,
|
||||
};
|
||||
|
||||
export const installLicenseMutation = {
|
||||
@@ -1475,10 +1475,10 @@ export const installLicenseMutation = {
|
||||
op: 'installLicense',
|
||||
query: `mutation installLicense($workspaceId: String!, $license: Upload!) {
|
||||
installLicense(workspaceId: $workspaceId, license: $license) {
|
||||
...license
|
||||
...licenseBody
|
||||
}
|
||||
}
|
||||
${licenseFragment}`,
|
||||
${licenseBodyFragment}`,
|
||||
file: true,
|
||||
};
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#import './license.gql'
|
||||
#import './license-body.gql'
|
||||
|
||||
mutation activateLicense($workspaceId: String!, $license: String!) {
|
||||
activateLicense(workspaceId: $workspaceId, license: $license) {
|
||||
...license
|
||||
...licenseBody
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,9 @@
|
||||
#import './license.gql'
|
||||
#import './license-body.gql'
|
||||
|
||||
query getLicense($workspaceId: String!) {
|
||||
workspace(id: $workspaceId) {
|
||||
license {
|
||||
...license
|
||||
...licenseBody
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#import './license.gql'
|
||||
#import './license-body.gql'
|
||||
|
||||
mutation installLicense($workspaceId: String!, $license: Upload!) {
|
||||
installLicense(workspaceId: $workspaceId, license: $license) {
|
||||
...license
|
||||
...licenseBody
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
fragment license on License {
|
||||
fragment licenseBody on License {
|
||||
expiredAt
|
||||
installedAt
|
||||
quantity
|
||||
@@ -4401,7 +4401,7 @@ export type InstallLicenseMutation = {
|
||||
};
|
||||
};
|
||||
|
||||
export type LicenseFragment = {
|
||||
export type LicenseBodyFragment = {
|
||||
__typename?: 'License';
|
||||
expiredAt: string | null;
|
||||
installedAt: string;
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
archiveVersion = 1;
|
||||
classes = {
|
||||
};
|
||||
objectVersion = 77;
|
||||
objectVersion = 56;
|
||||
objects = {
|
||||
|
||||
/* Begin PBXBuildFile section */
|
||||
@@ -13,7 +13,6 @@
|
||||
50802D612D112F8700694021 /* Intelligents in Frameworks */ = {isa = PBXBuildFile; productRef = 50802D602D112F8700694021 /* Intelligents */; };
|
||||
50A285D72D112A5E000D5A6D /* Localizable.xcstrings in Resources */ = {isa = PBXBuildFile; fileRef = 50A285D62D112A5E000D5A6D /* Localizable.xcstrings */; };
|
||||
50A285D82D112A5E000D5A6D /* InfoPlist.xcstrings in Resources */ = {isa = PBXBuildFile; fileRef = 50A285D52D112A5E000D5A6D /* InfoPlist.xcstrings */; };
|
||||
50A285DC2D112B24000D5A6D /* Intelligents in Frameworks */ = {isa = PBXBuildFile; productRef = 50A285DB2D112B24000D5A6D /* Intelligents */; };
|
||||
50FF428A2D2E757E0050AA83 /* ApplicationBridgedWindowScript.swift in Sources */ = {isa = PBXBuildFile; fileRef = 50FF42892D2E757E0050AA83 /* ApplicationBridgedWindowScript.swift */; };
|
||||
50FF428C2D2E77CC0050AA83 /* AffineViewController+AIButton.swift in Sources */ = {isa = PBXBuildFile; fileRef = 50FF428B2D2E77CC0050AA83 /* AffineViewController+AIButton.swift */; };
|
||||
9D52FC432D26CDBF00105D0A /* JSValueContainerExt.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9D52FC422D26CDB600105D0A /* JSValueContainerExt.swift */; };
|
||||
@@ -78,6 +77,8 @@
|
||||
/* Begin PBXFileSystemSynchronizedRootGroup section */
|
||||
C45499AB2D140B5000E21978 /* NBStore */ = {
|
||||
isa = PBXFileSystemSynchronizedRootGroup;
|
||||
exceptions = (
|
||||
);
|
||||
path = NBStore;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
@@ -88,7 +89,6 @@
|
||||
isa = PBXFrameworksBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
50A285DC2D112B24000D5A6D /* Intelligents in Frameworks */,
|
||||
9DFCD1462D27D1D70028C92B /* libaffine_mobile_native.a in Frameworks */,
|
||||
50802D612D112F8700694021 /* Intelligents in Frameworks */,
|
||||
2E0DD47B57B994A104B25EED /* Pods_AFFiNE.framework in Frameworks */,
|
||||
@@ -514,14 +514,13 @@
|
||||
baseConfigurationReference = 3256F4410D881A03FE77D092 /* Pods-AFFiNE.debug.xcconfig */;
|
||||
buildSettings = {
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||
CODE_SIGN_IDENTITY = "Apple Distribution: TOEVERYTHING PTE. LTD. (73YMMDVT2M)";
|
||||
CODE_SIGN_STYLE = Manual;
|
||||
CODE_SIGN_IDENTITY = "Apple Development";
|
||||
CODE_SIGN_STYLE = Automatic;
|
||||
CURRENT_PROJECT_VERSION = 12;
|
||||
DEVELOPMENT_TEAM = 73YMMDVT2M;
|
||||
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = 73YMMDVT2M;
|
||||
DEVELOPMENT_TEAM = 964G86XT2P;
|
||||
INFOPLIST_FILE = App/Info.plist;
|
||||
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.productivity";
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 16.4;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 16.0;
|
||||
LD_RUNPATH_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"@executable_path/Frameworks",
|
||||
@@ -559,7 +558,7 @@
|
||||
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = 73YMMDVT2M;
|
||||
INFOPLIST_FILE = App/Info.plist;
|
||||
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.productivity";
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 16.4;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 16.0;
|
||||
LD_RUNPATH_SEARCH_PATHS = (
|
||||
"$(inherited)",
|
||||
"@executable_path/Frameworks",
|
||||
@@ -572,8 +571,7 @@
|
||||
ONLY_ACTIVE_ARCH = NO;
|
||||
PRODUCT_BUNDLE_IDENTIFIER = app.affine.pro;
|
||||
PRODUCT_NAME = "$(TARGET_NAME)";
|
||||
PROVISIONING_PROFILE_SPECIFIER = "AppStore app.affine.pro";
|
||||
"PROVISIONING_PROFILE_SPECIFIER[sdk=iphoneos*]" = "AppStore app.affine.pro";
|
||||
PROVISIONING_PROFILE_SPECIFIER = "";
|
||||
SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
|
||||
SUPPORTS_MACCATALYST = NO;
|
||||
SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO;
|
||||
@@ -613,10 +611,6 @@
|
||||
isa = XCSwiftPackageProductDependency;
|
||||
productName = Intelligents;
|
||||
};
|
||||
50A285DB2D112B24000D5A6D /* Intelligents */ = {
|
||||
isa = XCSwiftPackageProductDependency;
|
||||
productName = Intelligents;
|
||||
};
|
||||
/* End XCSwiftPackageProductDependency section */
|
||||
};
|
||||
rootObject = 504EC2FC1FED79650016851F /* Project object */;
|
||||
|
||||
@@ -1,59 +0,0 @@
|
||||
{
|
||||
"pins" : [
|
||||
{
|
||||
"identity" : "apollo-ios",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/apollographql/apollo-ios",
|
||||
"state" : {
|
||||
"revision" : "39fea7617346c0731be25f61afd537e7032fb562",
|
||||
"version" : "1.22.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "chidorimenu",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/Lakr233/ChidoriMenu",
|
||||
"state" : {
|
||||
"revision" : "3bb4323fe0f7f8f435d15656c3eeffcbb7c9c605",
|
||||
"version" : "3.0.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "splash",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/JohnSundell/Splash",
|
||||
"state" : {
|
||||
"revision" : "7f4df436eb78fe64fe2c32c58006e9949fa28ad8",
|
||||
"version" : "0.16.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "swift-cmark",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/swiftlang/swift-cmark",
|
||||
"state" : {
|
||||
"revision" : "b022b08312decdc46585e0b3440d97f6f22ef703",
|
||||
"version" : "0.6.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "swift-collections",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/apple/swift-collections",
|
||||
"state" : {
|
||||
"revision" : "c1805596154bb3a265fd91b8ac0c4433b4348fb0",
|
||||
"version" : "1.2.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "swift-eventsource",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/LaunchDarkly/swift-eventsource.git",
|
||||
"state" : {
|
||||
"revision" : "57051701c58a93603ffa2051f8e9cf0c8cff7814",
|
||||
"version" : "3.3.0"
|
||||
}
|
||||
}
|
||||
],
|
||||
"version" : 2
|
||||
}
|
||||
@@ -3,37 +3,28 @@
|
||||
{
|
||||
"identity" : "apollo-ios",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/apollographql/apollo-ios.git",
|
||||
"location" : "https://github.com/apollographql/apollo-ios",
|
||||
"state" : {
|
||||
"revision" : "39fea7617346c0731be25f61afd537e7032fb562",
|
||||
"version" : "1.22.0"
|
||||
"revision" : "9aa748d6f0526a744d49d59a2383dc7fdf9d645b",
|
||||
"version" : "1.18.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "chidorimenu",
|
||||
"identity" : "snapkit",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/Lakr233/ChidoriMenu",
|
||||
"location" : "https://github.com/SnapKit/SnapKit.git",
|
||||
"state" : {
|
||||
"revision" : "3bb4323fe0f7f8f435d15656c3eeffcbb7c9c605",
|
||||
"version" : "3.0.0"
|
||||
"revision" : "2842e6e84e82eb9a8dac0100ca90d9444b0307f4",
|
||||
"version" : "5.7.1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "splash",
|
||||
"identity" : "sqlite.swift",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/JohnSundell/Splash",
|
||||
"location" : "https://github.com/stephencelis/SQLite.swift.git",
|
||||
"state" : {
|
||||
"revision" : "7f4df436eb78fe64fe2c32c58006e9949fa28ad8",
|
||||
"version" : "0.16.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "swift-cmark",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/swiftlang/swift-cmark",
|
||||
"state" : {
|
||||
"revision" : "b022b08312decdc46585e0b3440d97f6f22ef703",
|
||||
"version" : "0.6.0"
|
||||
"revision" : "392dd6058624d9f6c5b4c769d165ddd8c7293394",
|
||||
"version" : "0.15.4"
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -46,12 +37,30 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "swift-eventsource",
|
||||
"identity" : "swift-toolchain-sqlite",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/LaunchDarkly/swift-eventsource.git",
|
||||
"location" : "https://github.com/swiftlang/swift-toolchain-sqlite",
|
||||
"state" : {
|
||||
"revision" : "57051701c58a93603ffa2051f8e9cf0c8cff7814",
|
||||
"version" : "3.3.0"
|
||||
"revision" : "b626d3002773b1a1304166643e7f118f724b2132",
|
||||
"version" : "1.0.4"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "swifterswift",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/SwifterSwift/SwifterSwift.git",
|
||||
"state" : {
|
||||
"revision" : "39fa28c90a3ebe3d53f80289304fd880cf2c42d0",
|
||||
"version" : "6.2.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "then",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/devxoul/Then",
|
||||
"state" : {
|
||||
"revision" : "d41ef523faef0f911369f79c0b96815d9dbb6d7a",
|
||||
"version" : "3.0.0"
|
||||
}
|
||||
}
|
||||
],
|
||||
|
||||
@@ -5,123 +5,18 @@
|
||||
// Created by 秋星桥 on 2025/1/8.
|
||||
//
|
||||
|
||||
import ChidoriMenu
|
||||
import Intelligents
|
||||
import UIKit
|
||||
|
||||
extension AFFiNEViewController: IntelligentsButtonDelegate, IntelligentsFocusApertureViewDelegate {
|
||||
extension AFFiNEViewController: IntelligentsButtonDelegate {
|
||||
func onIntelligentsButtonTapped(_ button: IntelligentsButton) {
|
||||
guard let webView else {
|
||||
assertionFailure() // ? wdym ?
|
||||
return
|
||||
}
|
||||
|
||||
IntelligentContext.shared.webView = webView!
|
||||
button.beginProgress()
|
||||
|
||||
let group = DispatchGroup()
|
||||
|
||||
group.enter()
|
||||
webView.evaluateScript(.getCurrentServerBaseUrl) { result in
|
||||
self.baseUrl = result as? String
|
||||
print("[*] setting baseUrl: \(self.baseUrl ?? "")")
|
||||
group.leave()
|
||||
}
|
||||
|
||||
group.enter()
|
||||
webView.evaluateScript(.getCurrentDocId) { result in
|
||||
self.documentID = result as? String
|
||||
print("[*] setting documentID: \(self.documentID ?? "")")
|
||||
group.leave()
|
||||
}
|
||||
|
||||
group.enter()
|
||||
webView.evaluateScript(.getCurrentWorkspaceId) { result in
|
||||
self.workspaceID = result as? String
|
||||
print("[*] setting workspaceID: \(self.workspaceID ?? "")")
|
||||
group.leave()
|
||||
}
|
||||
|
||||
group.enter()
|
||||
webView.evaluateScript(.getCurrentDocContentInMarkdown) { input in
|
||||
self.documentContent = input as? String
|
||||
print("[*] setting documentContent: \(self.documentContent?.count ?? 0) chars")
|
||||
group.leave()
|
||||
}
|
||||
|
||||
DispatchQueue.global().asyncAfter(deadline: .now()) {
|
||||
group.wait()
|
||||
DispatchQueue.main.async {
|
||||
button.stopProgress()
|
||||
webView.resignFirstResponder()
|
||||
self.openIntelligentsSheet()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@discardableResult
|
||||
func openIntelligentsSheet() -> IntelligentsFocusApertureView? {
|
||||
dismissIntelligentsButton()
|
||||
view.resignFirstResponder()
|
||||
// stop scroll on webview
|
||||
if let contentOffset = webView?.scrollView.contentOffset {
|
||||
webView?.scrollView.contentOffset = contentOffset
|
||||
}
|
||||
let focus = IntelligentsFocusApertureView()
|
||||
focus.prepareAnimationWith(
|
||||
capturingTargetContentView: webView ?? .init(),
|
||||
coveringRootViewController: self
|
||||
)
|
||||
focus.delegate = self
|
||||
focus.executeAnimationKickIn()
|
||||
dismissIntelligentsButton()
|
||||
return focus
|
||||
}
|
||||
|
||||
func openSimpleChat() {
|
||||
let targetController = IntelligentsChatController()
|
||||
presentIntoCurrentContext(withTargetController: targetController)
|
||||
}
|
||||
|
||||
func focusApertureRequestAction(
|
||||
from view: IntelligentsFocusApertureView,
|
||||
actionType: IntelligentsFocusApertureViewActionType
|
||||
) {
|
||||
switch actionType {
|
||||
case .translateTo:
|
||||
var actions: [UIAction] = []
|
||||
for lang in IntelligentsEphemeralActionController.EphemeralAction.Language.allCases {
|
||||
actions.append(.init(title: lang.rawValue) { [weak self] _ in
|
||||
guard let self else { return }
|
||||
let controller = IntelligentsEphemeralActionController(
|
||||
action: .translate(to: lang)
|
||||
)
|
||||
controller.workspaceID = workspaceID ?? ""
|
||||
controller.documentID = documentID ?? ""
|
||||
controller.documentContent = documentContent ?? ""
|
||||
controller.configure(previewImage: view.capturedImage ?? .init())
|
||||
presentIntoCurrentContext(withTargetController: controller)
|
||||
})
|
||||
}
|
||||
view.present(menu: .init(children: actions)) { controller in
|
||||
controller.overrideUserInterfaceStyle = .dark
|
||||
} controllerDidPresent: { _ in }
|
||||
case .summary:
|
||||
let controller = IntelligentsEphemeralActionController(
|
||||
action: .summarize
|
||||
)
|
||||
controller.configure(previewImage: view.capturedImage ?? .init())
|
||||
controller.workspaceID = workspaceID ?? ""
|
||||
controller.documentID = documentID ?? ""
|
||||
controller.documentContent = documentContent ?? ""
|
||||
presentIntoCurrentContext(withTargetController: controller)
|
||||
case .chatWithAI:
|
||||
let controller = IntelligentsChatController()
|
||||
controller.metadata[.documentID] = documentID
|
||||
controller.metadata[.workspaceID] = workspaceID
|
||||
controller.metadata[.content] = documentContent
|
||||
presentIntoCurrentContext(withTargetController: controller)
|
||||
case .dismiss:
|
||||
presentIntelligentsButton()
|
||||
|
||||
IntelligentContext.shared.preparePresent() {
|
||||
button.stopProgress()
|
||||
let controller = IntelligentsController()
|
||||
self.present(controller, animated: true)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,13 +3,6 @@ import Intelligents
|
||||
import UIKit
|
||||
|
||||
class AFFiNEViewController: CAPBridgeViewController {
|
||||
var baseUrl: String? {
|
||||
didSet { Intelligents.setUpstreamEndpoint(baseUrl ?? "") }
|
||||
}
|
||||
var documentID: String?
|
||||
var workspaceID: String?
|
||||
var documentContent: String?
|
||||
|
||||
override func viewDidLoad() {
|
||||
super.viewDidLoad()
|
||||
webView?.allowsBackForwardNavigationGestures = true
|
||||
@@ -36,7 +29,7 @@ class AFFiNEViewController: CAPBridgeViewController {
|
||||
CookiePlugin(),
|
||||
HashcashPlugin(),
|
||||
NavigationGesturePlugin(),
|
||||
IntelligentsPlugin(representController: self),
|
||||
// IntelligentsPlugin(representController: self), // no longer put in use
|
||||
NbStorePlugin(),
|
||||
]
|
||||
plugins.forEach { bridge?.registerPluginInstance($0) }
|
||||
@@ -45,16 +38,11 @@ class AFFiNEViewController: CAPBridgeViewController {
|
||||
override func viewDidAppear(_ animated: Bool) {
|
||||
super.viewDidAppear(animated)
|
||||
navigationController?.setNavigationBarHidden(false, animated: animated)
|
||||
}
|
||||
|
||||
#if DEBUG
|
||||
override func motionEnded(_ motion: UIEvent.EventSubtype, with event: UIEvent?) {
|
||||
super.motionEnded(motion, with: event)
|
||||
if motion == .motionShake {
|
||||
presentIntelligentsButton()
|
||||
DispatchQueue.main.asyncAfter(deadline: .now() + 1) {
|
||||
self.presentIntelligentsButton()
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
<key>NSPhotoLibraryUsageDescription</key>
|
||||
<string>AFFiNE requires access to select photos from your photo library and insert them into your documents</string>
|
||||
<key>NSUserTrackingUsageDescription</key>
|
||||
<string>Rest assured, enabling this permission won't access your private info on other sites. It's only used to identify your device and improve security and product experience.</string>
|
||||
<string>Rest assured, enabling this permission won't access your private info on other sites. It's only used to identify your device and improve security and product experience.</string>
|
||||
<key>UILaunchScreen</key>
|
||||
<dict>
|
||||
<key>UIImageName</key>
|
||||
|
||||
@@ -1,36 +1,36 @@
|
||||
import Capacitor
|
||||
import Foundation
|
||||
|
||||
@objc(IntelligentsPlugin)
|
||||
public class IntelligentsPlugin: CAPPlugin, CAPBridgedPlugin {
|
||||
public let identifier = "IntelligentsPlugin"
|
||||
public let jsName = "Intelligents"
|
||||
public let pluginMethods: [CAPPluginMethod] = [
|
||||
CAPPluginMethod(name: "presentIntelligentsButton", returnType: CAPPluginReturnPromise),
|
||||
CAPPluginMethod(name: "dismissIntelligentsButton", returnType: CAPPluginReturnPromise),
|
||||
]
|
||||
public private(set) weak var representController: UIViewController?
|
||||
|
||||
init(representController: UIViewController) {
|
||||
self.representController = representController
|
||||
super.init()
|
||||
}
|
||||
|
||||
deinit {
|
||||
representController = nil
|
||||
}
|
||||
|
||||
@objc public func presentIntelligentsButton(_ call: CAPPluginCall) {
|
||||
DispatchQueue.main.async {
|
||||
self.representController?.presentIntelligentsButton()
|
||||
call.resolve()
|
||||
}
|
||||
}
|
||||
|
||||
@objc public func dismissIntelligentsButton(_ call: CAPPluginCall) {
|
||||
DispatchQueue.main.async {
|
||||
self.representController?.dismissIntelligentsButton()
|
||||
call.resolve()
|
||||
}
|
||||
}
|
||||
}
|
||||
//@objc(IntelligentsPlugin)
|
||||
//public class IntelligentsPlugin: CAPPlugin, CAPBridgedPlugin {
|
||||
// public let identifier = "IntelligentsPlugin"
|
||||
// public let jsName = "Intelligents"
|
||||
// public let pluginMethods: [CAPPluginMethod] = [
|
||||
// CAPPluginMethod(name: "presentIntelligentsButton", returnType: CAPPluginReturnPromise),
|
||||
// CAPPluginMethod(name: "dismissIntelligentsButton", returnType: CAPPluginReturnPromise),
|
||||
// ]
|
||||
// public private(set) weak var representController: UIViewController?
|
||||
//
|
||||
// init(representController: UIViewController) {
|
||||
// self.representController = representController
|
||||
// super.init()
|
||||
// }
|
||||
//
|
||||
// deinit {
|
||||
// representController = nil
|
||||
// }
|
||||
//
|
||||
// @objc public func presentIntelligentsButton(_ call: CAPPluginCall) {
|
||||
// DispatchQueue.main.async {
|
||||
// self.representController?.presentIntelligentsButton()
|
||||
// call.resolve()
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// @objc public func dismissIntelligentsButton(_ call: CAPPluginCall) {
|
||||
// DispatchQueue.main.async {
|
||||
// self.representController?.dismissIntelligentsButton()
|
||||
// call.resolve()
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
|
||||
@@ -1711,6 +1711,7 @@ extension UniffiError: Equatable, Hashable {}
|
||||
|
||||
|
||||
|
||||
|
||||
extension UniffiError: Foundation.LocalizedError {
|
||||
public var errorDescription: String? {
|
||||
String(reflecting: self)
|
||||
@@ -1718,6 +1719,8 @@ extension UniffiError: Foundation.LocalizedError {
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
#if swift(>=5.8)
|
||||
@_documentation(visibility: private)
|
||||
#endif
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
module affine_mobile_nativeFFI {
|
||||
header "affine_mobile_nativeFFI.h"
|
||||
export *
|
||||
use "Darwin"
|
||||
use "_Builtin_stdbool"
|
||||
use "_Builtin_stdint"
|
||||
}
|
||||
@@ -1,14 +0,0 @@
|
||||
{
|
||||
"pins" : [
|
||||
{
|
||||
"identity" : "apollo-ios",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/apollographql/apollo-ios.git",
|
||||
"state" : {
|
||||
"revision" : "6ecc75281dab2fa231cb0d5fed3a3713826fecae",
|
||||
"version" : "1.21.0"
|
||||
}
|
||||
}
|
||||
],
|
||||
"version" : 2
|
||||
}
|
||||
@@ -14,7 +14,7 @@ let package = Package(
|
||||
.library(name: "AffineGraphQL", targets: ["AffineGraphQL"]),
|
||||
],
|
||||
dependencies: [
|
||||
.package(url: "https://github.com/apollographql/apollo-ios", exact: "1.22.0"),
|
||||
.package(url: "https://github.com/apollographql/apollo-ios", exact: "1.18.0"),
|
||||
],
|
||||
targets: [
|
||||
.target(
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public struct LicenseBody: AffineGraphQL.SelectionSet, Fragment {
|
||||
public static var fragmentDefinition: StaticString {
|
||||
#"fragment licenseBody on License { __typename expiredAt installedAt quantity recurring validatedAt variant }"#
|
||||
}
|
||||
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.License }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("expiredAt", AffineGraphQL.DateTime?.self),
|
||||
.field("installedAt", AffineGraphQL.DateTime.self),
|
||||
.field("quantity", Int.self),
|
||||
.field("recurring", GraphQLEnum<AffineGraphQL.SubscriptionRecurring>.self),
|
||||
.field("validatedAt", AffineGraphQL.DateTime.self),
|
||||
.field("variant", GraphQLEnum<AffineGraphQL.SubscriptionVariant>?.self),
|
||||
] }
|
||||
|
||||
public var expiredAt: AffineGraphQL.DateTime? { __data["expiredAt"] }
|
||||
public var installedAt: AffineGraphQL.DateTime { __data["installedAt"] }
|
||||
public var quantity: Int { __data["quantity"] }
|
||||
public var recurring: GraphQLEnum<AffineGraphQL.SubscriptionRecurring> { __data["recurring"] }
|
||||
public var validatedAt: AffineGraphQL.DateTime { __data["validatedAt"] }
|
||||
public var variant: GraphQLEnum<AffineGraphQL.SubscriptionVariant>? { __data["variant"] }
|
||||
}
|
||||
@@ -7,27 +7,23 @@ public class AcceptInviteByInviteIdMutation: GraphQLMutation {
|
||||
public static let operationName: String = "acceptInviteByInviteId"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation acceptInviteByInviteId($workspaceId: String!, $inviteId: String!, $sendAcceptMail: Boolean) { acceptInviteById( workspaceId: $workspaceId inviteId: $inviteId sendAcceptMail: $sendAcceptMail ) }"#
|
||||
#"mutation acceptInviteByInviteId($workspaceId: String!, $inviteId: String!) { acceptInviteById(workspaceId: $workspaceId, inviteId: $inviteId) }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var inviteId: String
|
||||
public var sendAcceptMail: GraphQLNullable<Bool>
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
inviteId: String,
|
||||
sendAcceptMail: GraphQLNullable<Bool>
|
||||
inviteId: String
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.inviteId = inviteId
|
||||
self.sendAcceptMail = sendAcceptMail
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"inviteId": inviteId,
|
||||
"sendAcceptMail": sendAcceptMail
|
||||
"inviteId": inviteId
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
@@ -35,12 +31,11 @@ public class AcceptInviteByInviteIdMutation: GraphQLMutation {
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
#warning("Argument 'sendAcceptMail' of field 'acceptInviteById' is deprecated. Reason: 'never used'")
|
||||
#warning("Argument 'workspaceId' of field 'acceptInviteById' is deprecated. Reason: 'never used'")
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("acceptInviteById", Bool.self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
"inviteId": .variable("inviteId"),
|
||||
"sendAcceptMail": .variable("sendAcceptMail")
|
||||
"inviteId": .variable("inviteId")
|
||||
]),
|
||||
] }
|
||||
|
||||
|
||||
@@ -7,7 +7,8 @@ public class ActivateLicenseMutation: GraphQLMutation {
|
||||
public static let operationName: String = "activateLicense"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation activateLicense($workspaceId: String!, $license: String!) { activateLicense(workspaceId: $workspaceId, license: $license) { __typename installedAt validatedAt } }"#
|
||||
#"mutation activateLicense($workspaceId: String!, $license: String!) { activateLicense(workspaceId: $workspaceId, license: $license) { __typename ...licenseBody } }"#,
|
||||
fragments: [LicenseBody.self]
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
@@ -50,12 +51,22 @@ public class ActivateLicenseMutation: GraphQLMutation {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.License }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("installedAt", AffineGraphQL.DateTime.self),
|
||||
.field("validatedAt", AffineGraphQL.DateTime.self),
|
||||
.fragment(LicenseBody.self),
|
||||
] }
|
||||
|
||||
public var expiredAt: AffineGraphQL.DateTime? { __data["expiredAt"] }
|
||||
public var installedAt: AffineGraphQL.DateTime { __data["installedAt"] }
|
||||
public var quantity: Int { __data["quantity"] }
|
||||
public var recurring: GraphQLEnum<AffineGraphQL.SubscriptionRecurring> { __data["recurring"] }
|
||||
public var validatedAt: AffineGraphQL.DateTime { __data["validatedAt"] }
|
||||
public var variant: GraphQLEnum<AffineGraphQL.SubscriptionVariant>? { __data["variant"] }
|
||||
|
||||
public struct Fragments: FragmentContainer {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public var licenseBody: LicenseBody { _toFragment() }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ public class AddContextFileMutation: GraphQLMutation {
|
||||
public static let operationName: String = "addContextFile"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation addContextFile($content: Upload!, $options: AddContextFileInput!) { addContextFile(content: $content, options: $options) { __typename id createdAt name chunkSize error status blobId } }"#
|
||||
#"mutation addContextFile($content: Upload!, $options: AddContextFileInput!) { addContextFile(content: $content, options: $options) { __typename id createdAt name mimeType chunkSize error status blobId } }"#
|
||||
))
|
||||
|
||||
public var content: Upload
|
||||
@@ -54,6 +54,7 @@ public class AddContextFileMutation: GraphQLMutation {
|
||||
.field("id", AffineGraphQL.ID.self),
|
||||
.field("createdAt", AffineGraphQL.SafeInt.self),
|
||||
.field("name", String.self),
|
||||
.field("mimeType", String.self),
|
||||
.field("chunkSize", AffineGraphQL.SafeInt.self),
|
||||
.field("error", String?.self),
|
||||
.field("status", GraphQLEnum<AffineGraphQL.ContextEmbedStatus>.self),
|
||||
@@ -63,6 +64,7 @@ public class AddContextFileMutation: GraphQLMutation {
|
||||
public var id: AffineGraphQL.ID { __data["id"] }
|
||||
public var createdAt: AffineGraphQL.SafeInt { __data["createdAt"] }
|
||||
public var name: String { __data["name"] }
|
||||
public var mimeType: String { __data["mimeType"] }
|
||||
public var chunkSize: AffineGraphQL.SafeInt { __data["chunkSize"] }
|
||||
public var error: String? { __data["error"] }
|
||||
public var status: GraphQLEnum<AffineGraphQL.ContextEmbedStatus> { __data["status"] }
|
||||
|
||||
@@ -0,0 +1,70 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class AddWorkspaceEmbeddingFilesMutation: GraphQLMutation {
|
||||
public static let operationName: String = "addWorkspaceEmbeddingFiles"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation addWorkspaceEmbeddingFiles($workspaceId: String!, $blob: Upload!) { addWorkspaceEmbeddingFiles(workspaceId: $workspaceId, blob: $blob) { __typename fileId fileName blobId mimeType size createdAt } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var blob: Upload
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
blob: Upload
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.blob = blob
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"blob": blob
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("addWorkspaceEmbeddingFiles", AddWorkspaceEmbeddingFiles.self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
"blob": .variable("blob")
|
||||
]),
|
||||
] }
|
||||
|
||||
/// Update workspace embedding files
|
||||
public var addWorkspaceEmbeddingFiles: AddWorkspaceEmbeddingFiles { __data["addWorkspaceEmbeddingFiles"] }
|
||||
|
||||
/// AddWorkspaceEmbeddingFiles
|
||||
///
|
||||
/// Parent Type: `CopilotWorkspaceFile`
|
||||
public struct AddWorkspaceEmbeddingFiles: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotWorkspaceFile }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("fileId", String.self),
|
||||
.field("fileName", String.self),
|
||||
.field("blobId", String.self),
|
||||
.field("mimeType", String.self),
|
||||
.field("size", AffineGraphQL.SafeInt.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
] }
|
||||
|
||||
public var fileId: String { __data["fileId"] }
|
||||
public var fileName: String { __data["fileName"] }
|
||||
public var blobId: String { __data["blobId"] }
|
||||
public var mimeType: String { __data["mimeType"] }
|
||||
public var size: AffineGraphQL.SafeInt { __data["size"] }
|
||||
public var createdAt: AffineGraphQL.DateTime { __data["createdAt"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class AddWorkspaceEmbeddingIgnoredDocsMutation: GraphQLMutation {
|
||||
public static let operationName: String = "addWorkspaceEmbeddingIgnoredDocs"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation addWorkspaceEmbeddingIgnoredDocs($workspaceId: String!, $add: [String!]!) { updateWorkspaceEmbeddingIgnoredDocs(workspaceId: $workspaceId, add: $add) }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var add: [String]
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
add: [String]
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.add = add
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"add": add
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("updateWorkspaceEmbeddingIgnoredDocs", Int.self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
"add": .variable("add")
|
||||
]),
|
||||
] }
|
||||
|
||||
/// Update ignored docs
|
||||
public var updateWorkspaceEmbeddingIgnoredDocs: Int { __data["updateWorkspaceEmbeddingIgnoredDocs"] }
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,7 @@ public class ClaimAudioTranscriptionMutation: GraphQLMutation {
|
||||
public static let operationName: String = "claimAudioTranscription"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation claimAudioTranscription($jobId: String!) { claimAudioTranscription(jobId: $jobId) { __typename id status title summary transcription { __typename speaker start end transcription } } }"#
|
||||
#"mutation claimAudioTranscription($jobId: String!) { claimAudioTranscription(jobId: $jobId) { __typename id status title summary actions transcription { __typename speaker start end transcription } } }"#
|
||||
))
|
||||
|
||||
public var jobId: String
|
||||
@@ -43,6 +43,7 @@ public class ClaimAudioTranscriptionMutation: GraphQLMutation {
|
||||
.field("status", GraphQLEnum<AffineGraphQL.AiJobStatus>.self),
|
||||
.field("title", String?.self),
|
||||
.field("summary", String?.self),
|
||||
.field("actions", String?.self),
|
||||
.field("transcription", [Transcription]?.self),
|
||||
] }
|
||||
|
||||
@@ -50,6 +51,7 @@ public class ClaimAudioTranscriptionMutation: GraphQLMutation {
|
||||
public var status: GraphQLEnum<AffineGraphQL.AiJobStatus> { __data["status"] }
|
||||
public var title: String? { __data["title"] }
|
||||
public var summary: String? { __data["summary"] }
|
||||
public var actions: String? { __data["actions"] }
|
||||
public var transcription: [Transcription]? { __data["transcription"] }
|
||||
|
||||
/// ClaimAudioTranscription.Transcription
|
||||
|
||||
@@ -0,0 +1,72 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class InstallLicenseMutation: GraphQLMutation {
|
||||
public static let operationName: String = "installLicense"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation installLicense($workspaceId: String!, $license: Upload!) { installLicense(workspaceId: $workspaceId, license: $license) { __typename ...licenseBody } }"#,
|
||||
fragments: [LicenseBody.self]
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var license: Upload
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
license: Upload
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.license = license
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"license": license
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("installLicense", InstallLicense.self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
"license": .variable("license")
|
||||
]),
|
||||
] }
|
||||
|
||||
public var installLicense: InstallLicense { __data["installLicense"] }
|
||||
|
||||
/// InstallLicense
|
||||
///
|
||||
/// Parent Type: `License`
|
||||
public struct InstallLicense: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.License }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.fragment(LicenseBody.self),
|
||||
] }
|
||||
|
||||
public var expiredAt: AffineGraphQL.DateTime? { __data["expiredAt"] }
|
||||
public var installedAt: AffineGraphQL.DateTime { __data["installedAt"] }
|
||||
public var quantity: Int { __data["quantity"] }
|
||||
public var recurring: GraphQLEnum<AffineGraphQL.SubscriptionRecurring> { __data["recurring"] }
|
||||
public var validatedAt: AffineGraphQL.DateTime { __data["validatedAt"] }
|
||||
public var variant: GraphQLEnum<AffineGraphQL.SubscriptionVariant>? { __data["variant"] }
|
||||
|
||||
public struct Fragments: FragmentContainer {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public var licenseBody: LicenseBody { _toFragment() }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,71 +0,0 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class InviteBatchMutation: GraphQLMutation {
|
||||
public static let operationName: String = "inviteBatch"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation inviteBatch($workspaceId: String!, $emails: [String!]!, $sendInviteMail: Boolean) { inviteBatch( workspaceId: $workspaceId emails: $emails sendInviteMail: $sendInviteMail ) { __typename email inviteId sentSuccess } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var emails: [String]
|
||||
public var sendInviteMail: GraphQLNullable<Bool>
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
emails: [String],
|
||||
sendInviteMail: GraphQLNullable<Bool>
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.emails = emails
|
||||
self.sendInviteMail = sendInviteMail
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"emails": emails,
|
||||
"sendInviteMail": sendInviteMail
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
#warning("Argument 'sendInviteMail' of field 'inviteBatch' is deprecated. Reason: 'never used'")
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("inviteBatch", [InviteBatch].self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
"emails": .variable("emails"),
|
||||
"sendInviteMail": .variable("sendInviteMail")
|
||||
]),
|
||||
] }
|
||||
|
||||
public var inviteBatch: [InviteBatch] { __data["inviteBatch"] }
|
||||
|
||||
/// InviteBatch
|
||||
///
|
||||
/// Parent Type: `InviteResult`
|
||||
public struct InviteBatch: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.InviteResult }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("email", String.self),
|
||||
.field("inviteId", String?.self),
|
||||
.field("sentSuccess", Bool.self),
|
||||
] }
|
||||
|
||||
public var email: String { __data["email"] }
|
||||
/// Invite id, null if invite record create failed
|
||||
public var inviteId: String? { __data["inviteId"] }
|
||||
/// Invite email sent success
|
||||
public var sentSuccess: Bool { __data["sentSuccess"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,49 +0,0 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class InviteByEmailMutation: GraphQLMutation {
|
||||
public static let operationName: String = "inviteByEmail"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation inviteByEmail($workspaceId: String!, $email: String!, $sendInviteMail: Boolean) { invite( workspaceId: $workspaceId email: $email sendInviteMail: $sendInviteMail ) }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var email: String
|
||||
public var sendInviteMail: GraphQLNullable<Bool>
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
email: String,
|
||||
sendInviteMail: GraphQLNullable<Bool>
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.email = email
|
||||
self.sendInviteMail = sendInviteMail
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"email": email,
|
||||
"sendInviteMail": sendInviteMail
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
#warning("Argument 'sendInviteMail' of field 'invite' is deprecated. Reason: 'never used'")
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("invite", String.self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
"email": .variable("email"),
|
||||
"sendInviteMail": .variable("sendInviteMail")
|
||||
]),
|
||||
] }
|
||||
|
||||
public var invite: String { __data["invite"] }
|
||||
}
|
||||
}
|
||||
@@ -7,27 +7,23 @@ public class InviteByEmailsMutation: GraphQLMutation {
|
||||
public static let operationName: String = "inviteByEmails"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation inviteByEmails($workspaceId: String!, $emails: [String!]!, $sendInviteMail: Boolean) { inviteBatch( workspaceId: $workspaceId emails: $emails sendInviteMail: $sendInviteMail ) { __typename email inviteId sentSuccess } }"#
|
||||
#"mutation inviteByEmails($workspaceId: String!, $emails: [String!]!) { inviteMembers(workspaceId: $workspaceId, emails: $emails) { __typename email inviteId sentSuccess } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var emails: [String]
|
||||
public var sendInviteMail: GraphQLNullable<Bool>
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
emails: [String],
|
||||
sendInviteMail: GraphQLNullable<Bool>
|
||||
emails: [String]
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.emails = emails
|
||||
self.sendInviteMail = sendInviteMail
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"emails": emails,
|
||||
"sendInviteMail": sendInviteMail
|
||||
"emails": emails
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
@@ -35,21 +31,19 @@ public class InviteByEmailsMutation: GraphQLMutation {
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
#warning("Argument 'sendInviteMail' of field 'inviteBatch' is deprecated. Reason: 'never used'")
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("inviteBatch", [InviteBatch].self, arguments: [
|
||||
.field("inviteMembers", [InviteMember].self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
"emails": .variable("emails"),
|
||||
"sendInviteMail": .variable("sendInviteMail")
|
||||
"emails": .variable("emails")
|
||||
]),
|
||||
] }
|
||||
|
||||
public var inviteBatch: [InviteBatch] { __data["inviteBatch"] }
|
||||
public var inviteMembers: [InviteMember] { __data["inviteMembers"] }
|
||||
|
||||
/// InviteBatch
|
||||
/// InviteMember
|
||||
///
|
||||
/// Parent Type: `InviteResult`
|
||||
public struct InviteBatch: AffineGraphQL.SelectionSet {
|
||||
public struct InviteMember: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
@@ -65,6 +59,7 @@ public class InviteByEmailsMutation: GraphQLMutation {
|
||||
/// Invite id, null if invite record create failed
|
||||
public var inviteId: String? { __data["inviteId"] }
|
||||
/// Invite email sent success
|
||||
@available(*, deprecated, message: "Notification will be sent asynchronously")
|
||||
public var sentSuccess: Bool { __data["sentSuccess"] }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -31,6 +31,7 @@ public class LeaveWorkspaceMutation: GraphQLMutation {
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
#warning("Argument 'sendLeaveMail' of field 'leaveWorkspace' is deprecated. Reason: 'no used anymore'")
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("leaveWorkspace", Bool.self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
|
||||
@@ -0,0 +1,44 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class RemoveWorkspaceEmbeddingFilesMutation: GraphQLMutation {
|
||||
public static let operationName: String = "removeWorkspaceEmbeddingFiles"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation removeWorkspaceEmbeddingFiles($workspaceId: String!, $fileId: String!) { removeWorkspaceEmbeddingFiles(workspaceId: $workspaceId, fileId: $fileId) }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var fileId: String
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
fileId: String
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.fileId = fileId
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"fileId": fileId
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("removeWorkspaceEmbeddingFiles", Bool.self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
"fileId": .variable("fileId")
|
||||
]),
|
||||
] }
|
||||
|
||||
/// Remove workspace embedding files
|
||||
public var removeWorkspaceEmbeddingFiles: Bool { __data["removeWorkspaceEmbeddingFiles"] }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class RemoveWorkspaceEmbeddingIgnoredDocsMutation: GraphQLMutation {
|
||||
public static let operationName: String = "removeWorkspaceEmbeddingIgnoredDocs"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation removeWorkspaceEmbeddingIgnoredDocs($workspaceId: String!, $remove: [String!]!) { updateWorkspaceEmbeddingIgnoredDocs(workspaceId: $workspaceId, remove: $remove) }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var remove: [String]
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
remove: [String]
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.remove = remove
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"remove": remove
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("updateWorkspaceEmbeddingIgnoredDocs", Int.self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
"remove": .variable("remove")
|
||||
]),
|
||||
] }
|
||||
|
||||
/// Update ignored docs
|
||||
public var updateWorkspaceEmbeddingIgnoredDocs: Int { __data["updateWorkspaceEmbeddingIgnoredDocs"] }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,61 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class RetryAudioTranscriptionMutation: GraphQLMutation {
|
||||
public static let operationName: String = "retryAudioTranscription"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation retryAudioTranscription($workspaceId: String!, $jobId: String!) { retryAudioTranscription(workspaceId: $workspaceId, jobId: $jobId) { __typename id status } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var jobId: String
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
jobId: String
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.jobId = jobId
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"jobId": jobId
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("retryAudioTranscription", RetryAudioTranscription?.self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
"jobId": .variable("jobId")
|
||||
]),
|
||||
] }
|
||||
|
||||
public var retryAudioTranscription: RetryAudioTranscription? { __data["retryAudioTranscription"] }
|
||||
|
||||
/// RetryAudioTranscription
|
||||
///
|
||||
/// Parent Type: `TranscriptionResultType`
|
||||
public struct RetryAudioTranscription: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.TranscriptionResultType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", AffineGraphQL.ID.self),
|
||||
.field("status", GraphQLEnum<AffineGraphQL.AiJobStatus>.self),
|
||||
] }
|
||||
|
||||
public var id: AffineGraphQL.ID { __data["id"] }
|
||||
public var status: GraphQLEnum<AffineGraphQL.AiJobStatus> { __data["status"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,7 @@ public class RevokeMemberPermissionMutation: GraphQLMutation {
|
||||
public static let operationName: String = "revokeMemberPermission"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation revokeMemberPermission($workspaceId: String!, $userId: String!) { revoke(workspaceId: $workspaceId, userId: $userId) }"#
|
||||
#"mutation revokeMemberPermission($workspaceId: String!, $userId: String!) { revokeMember(workspaceId: $workspaceId, userId: $userId) }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
@@ -32,12 +32,12 @@ public class RevokeMemberPermissionMutation: GraphQLMutation {
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("revoke", Bool.self, arguments: [
|
||||
.field("revokeMember", Bool.self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
"userId": .variable("userId")
|
||||
]),
|
||||
] }
|
||||
|
||||
public var revoke: Bool { __data["revoke"] }
|
||||
public var revokeMember: Bool { __data["revokeMember"] }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,63 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class SendTestEmailMutation: GraphQLMutation {
|
||||
public static let operationName: String = "sendTestEmail"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation sendTestEmail($host: String!, $port: Int!, $sender: String!, $username: String!, $password: String!, $ignoreTLS: Boolean!) { sendTestEmail( config: { host: $host port: $port sender: $sender username: $username password: $password ignoreTLS: $ignoreTLS } ) }"#
|
||||
))
|
||||
|
||||
public var host: String
|
||||
public var port: Int
|
||||
public var sender: String
|
||||
public var username: String
|
||||
public var password: String
|
||||
public var ignoreTLS: Bool
|
||||
|
||||
public init(
|
||||
host: String,
|
||||
port: Int,
|
||||
sender: String,
|
||||
username: String,
|
||||
password: String,
|
||||
ignoreTLS: Bool
|
||||
) {
|
||||
self.host = host
|
||||
self.port = port
|
||||
self.sender = sender
|
||||
self.username = username
|
||||
self.password = password
|
||||
self.ignoreTLS = ignoreTLS
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"host": host,
|
||||
"port": port,
|
||||
"sender": sender,
|
||||
"username": username,
|
||||
"password": password,
|
||||
"ignoreTLS": ignoreTLS
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("sendTestEmail", Bool.self, arguments: ["config": [
|
||||
"host": .variable("host"),
|
||||
"port": .variable("port"),
|
||||
"sender": .variable("sender"),
|
||||
"username": .variable("username"),
|
||||
"password": .variable("password"),
|
||||
"ignoreTLS": .variable("ignoreTLS")
|
||||
]]),
|
||||
] }
|
||||
|
||||
public var sendTestEmail: Bool { __data["sendTestEmail"] }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,60 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class SetEnableDocEmbeddingMutation: GraphQLMutation {
|
||||
public static let operationName: String = "setEnableDocEmbedding"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation setEnableDocEmbedding($id: ID!, $enableDocEmbedding: Boolean!) { updateWorkspace(input: { id: $id, enableDocEmbedding: $enableDocEmbedding }) { __typename id } }"#
|
||||
))
|
||||
|
||||
public var id: ID
|
||||
public var enableDocEmbedding: Bool
|
||||
|
||||
public init(
|
||||
id: ID,
|
||||
enableDocEmbedding: Bool
|
||||
) {
|
||||
self.id = id
|
||||
self.enableDocEmbedding = enableDocEmbedding
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"id": id,
|
||||
"enableDocEmbedding": enableDocEmbedding
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("updateWorkspace", UpdateWorkspace.self, arguments: ["input": [
|
||||
"id": .variable("id"),
|
||||
"enableDocEmbedding": .variable("enableDocEmbedding")
|
||||
]]),
|
||||
] }
|
||||
|
||||
/// Update workspace
|
||||
public var updateWorkspace: UpdateWorkspace { __data["updateWorkspace"] }
|
||||
|
||||
/// UpdateWorkspace
|
||||
///
|
||||
/// Parent Type: `WorkspaceType`
|
||||
public struct UpdateWorkspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", AffineGraphQL.ID.self),
|
||||
] }
|
||||
|
||||
public var id: AffineGraphQL.ID { __data["id"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,27 +7,31 @@ public class SubmitAudioTranscriptionMutation: GraphQLMutation {
|
||||
public static let operationName: String = "submitAudioTranscription"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation submitAudioTranscription($workspaceId: String!, $blobId: String!, $blob: Upload!) { submitAudioTranscription( blob: $blob blobId: $blobId workspaceId: $workspaceId ) { __typename id status } }"#
|
||||
#"mutation submitAudioTranscription($workspaceId: String!, $blobId: String!, $blob: Upload, $blobs: [Upload!]) { submitAudioTranscription( blob: $blob blobs: $blobs blobId: $blobId workspaceId: $workspaceId ) { __typename id status } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var blobId: String
|
||||
public var blob: Upload
|
||||
public var blob: GraphQLNullable<Upload>
|
||||
public var blobs: GraphQLNullable<[Upload]>
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
blobId: String,
|
||||
blob: Upload
|
||||
blob: GraphQLNullable<Upload>,
|
||||
blobs: GraphQLNullable<[Upload]>
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.blobId = blobId
|
||||
self.blob = blob
|
||||
self.blobs = blobs
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"blobId": blobId,
|
||||
"blob": blob
|
||||
"blob": blob,
|
||||
"blobs": blobs
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
@@ -38,6 +42,7 @@ public class SubmitAudioTranscriptionMutation: GraphQLMutation {
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("submitAudioTranscription", SubmitAudioTranscription?.self, arguments: [
|
||||
"blob": .variable("blob"),
|
||||
"blobs": .variable("blobs"),
|
||||
"blobId": .variable("blobId"),
|
||||
"workspaceId": .variable("workspaceId")
|
||||
]),
|
||||
|
||||
@@ -7,7 +7,7 @@ public class UpdatePromptMutation: GraphQLMutation {
|
||||
public static let operationName: String = "updatePrompt"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation updatePrompt($name: String!, $messages: [CopilotPromptMessageInput!]!) { updateCopilotPrompt(name: $name, messages: $messages) { __typename name model action config { __typename jsonMode frequencyPenalty presencePenalty temperature topP } messages { __typename role content params } } }"#
|
||||
#"mutation updatePrompt($name: String!, $messages: [CopilotPromptMessageInput!]!) { updateCopilotPrompt(name: $name, messages: $messages) { __typename name model action config { __typename frequencyPenalty presencePenalty temperature topP } messages { __typename role content params } } }"#
|
||||
))
|
||||
|
||||
public var name: String
|
||||
@@ -74,14 +74,12 @@ public class UpdatePromptMutation: GraphQLMutation {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotPromptConfigType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("jsonMode", Bool?.self),
|
||||
.field("frequencyPenalty", Double?.self),
|
||||
.field("presencePenalty", Double?.self),
|
||||
.field("temperature", Double?.self),
|
||||
.field("topP", Double?.self),
|
||||
] }
|
||||
|
||||
public var jsonMode: Bool? { __data["jsonMode"] }
|
||||
public var frequencyPenalty: Double? { __data["frequencyPenalty"] }
|
||||
public var presencePenalty: Double? { __data["presencePenalty"] }
|
||||
public var temperature: Double? { __data["temperature"] }
|
||||
|
||||
@@ -0,0 +1,57 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class ValidateConfigMutation: GraphQLMutation {
|
||||
public static let operationName: String = "validateConfig"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation validateConfig($updates: [UpdateAppConfigInput!]!) { validateAppConfig(updates: $updates) { __typename module key value valid error } }"#
|
||||
))
|
||||
|
||||
public var updates: [UpdateAppConfigInput]
|
||||
|
||||
public init(updates: [UpdateAppConfigInput]) {
|
||||
self.updates = updates
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["updates": updates] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("validateAppConfig", [ValidateAppConfig].self, arguments: ["updates": .variable("updates")]),
|
||||
] }
|
||||
|
||||
/// validate app configuration
|
||||
public var validateAppConfig: [ValidateAppConfig] { __data["validateAppConfig"] }
|
||||
|
||||
/// ValidateAppConfig
|
||||
///
|
||||
/// Parent Type: `AppConfigValidateResult`
|
||||
public struct ValidateAppConfig: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.AppConfigValidateResult }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("module", String.self),
|
||||
.field("key", String.self),
|
||||
.field("value", AffineGraphQL.JSON.self),
|
||||
.field("valid", Bool.self),
|
||||
.field("error", String?.self),
|
||||
] }
|
||||
|
||||
public var module: String { __data["module"] }
|
||||
public var key: String { __data["key"] }
|
||||
public var value: AffineGraphQL.JSON { __data["value"] }
|
||||
public var valid: Bool { __data["valid"] }
|
||||
public var error: String? { __data["error"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,83 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class GetAllWorkspaceEmbeddingIgnoredDocsQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getAllWorkspaceEmbeddingIgnoredDocs"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getAllWorkspaceEmbeddingIgnoredDocs($workspaceId: String!) { workspace(id: $workspaceId) { __typename embedding { __typename allIgnoredDocs { __typename docId createdAt } } } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
|
||||
public init(workspaceId: String) {
|
||||
self.workspaceId = workspaceId
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["workspaceId": workspaceId] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("workspace", Workspace.self, arguments: ["id": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
/// Get workspace by id
|
||||
public var workspace: Workspace { __data["workspace"] }
|
||||
|
||||
/// Workspace
|
||||
///
|
||||
/// Parent Type: `WorkspaceType`
|
||||
public struct Workspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("embedding", Embedding.self),
|
||||
] }
|
||||
|
||||
public var embedding: Embedding { __data["embedding"] }
|
||||
|
||||
/// Workspace.Embedding
|
||||
///
|
||||
/// Parent Type: `CopilotWorkspaceConfig`
|
||||
public struct Embedding: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotWorkspaceConfig }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("allIgnoredDocs", [AllIgnoredDoc].self),
|
||||
] }
|
||||
|
||||
public var allIgnoredDocs: [AllIgnoredDoc] { __data["allIgnoredDocs"] }
|
||||
|
||||
/// Workspace.Embedding.AllIgnoredDoc
|
||||
///
|
||||
/// Parent Type: `CopilotWorkspaceIgnoredDoc`
|
||||
public struct AllIgnoredDoc: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotWorkspaceIgnoredDoc }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("docId", String.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
] }
|
||||
|
||||
public var docId: String { __data["docId"] }
|
||||
public var createdAt: AffineGraphQL.DateTime { __data["createdAt"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,98 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class GetCopilotSessionQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getCopilotSession"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getCopilotSession($workspaceId: String!, $sessionId: String!) { currentUser { __typename copilot(workspaceId: $workspaceId) { __typename session(sessionId: $sessionId) { __typename id parentSessionId promptName model optionalModels } } } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var sessionId: String
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
sessionId: String
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.sessionId = sessionId
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"sessionId": sessionId
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("currentUser", CurrentUser?.self),
|
||||
] }
|
||||
|
||||
/// Get current user
|
||||
public var currentUser: CurrentUser? { __data["currentUser"] }
|
||||
|
||||
/// CurrentUser
|
||||
///
|
||||
/// Parent Type: `UserType`
|
||||
public struct CurrentUser: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("copilot", Copilot.self, arguments: ["workspaceId": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
public var copilot: Copilot { __data["copilot"] }
|
||||
|
||||
/// CurrentUser.Copilot
|
||||
///
|
||||
/// Parent Type: `Copilot`
|
||||
public struct Copilot: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Copilot }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("session", Session.self, arguments: ["sessionId": .variable("sessionId")]),
|
||||
] }
|
||||
|
||||
/// Get the session by id
|
||||
public var session: Session { __data["session"] }
|
||||
|
||||
/// CurrentUser.Copilot.Session
|
||||
///
|
||||
/// Parent Type: `CopilotSessionType`
|
||||
public struct Session: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotSessionType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", AffineGraphQL.ID.self),
|
||||
.field("parentSessionId", AffineGraphQL.ID?.self),
|
||||
.field("promptName", String.self),
|
||||
.field("model", String.self),
|
||||
.field("optionalModels", [String].self),
|
||||
] }
|
||||
|
||||
public var id: AffineGraphQL.ID { __data["id"] }
|
||||
public var parentSessionId: AffineGraphQL.ID? { __data["parentSessionId"] }
|
||||
public var promptName: String { __data["promptName"] }
|
||||
public var model: String { __data["model"] }
|
||||
public var optionalModels: [String] { __data["optionalModels"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,7 @@ public class GetCopilotSessionsQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getCopilotSessions"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getCopilotSessions($workspaceId: String!, $docId: String, $options: QueryChatSessionsInput) { currentUser { __typename copilot(workspaceId: $workspaceId) { __typename sessions(docId: $docId, options: $options) { __typename id parentSessionId promptName } } } }"#
|
||||
#"query getCopilotSessions($workspaceId: String!, $docId: String, $options: QueryChatSessionsInput) { currentUser { __typename copilot(workspaceId: $workspaceId) { __typename sessions(docId: $docId, options: $options) { __typename id parentSessionId promptName model optionalModels } } } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
@@ -89,11 +89,15 @@ public class GetCopilotSessionsQuery: GraphQLQuery {
|
||||
.field("id", AffineGraphQL.ID.self),
|
||||
.field("parentSessionId", AffineGraphQL.ID?.self),
|
||||
.field("promptName", String.self),
|
||||
.field("model", String.self),
|
||||
.field("optionalModels", [String].self),
|
||||
] }
|
||||
|
||||
public var id: AffineGraphQL.ID { __data["id"] }
|
||||
public var parentSessionId: AffineGraphQL.ID? { __data["parentSessionId"] }
|
||||
public var promptName: String { __data["promptName"] }
|
||||
public var model: String { __data["model"] }
|
||||
public var optionalModels: [String] { __data["optionalModels"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,131 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class GetDocCreatedByUpdatedByListQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getDocCreatedByUpdatedByList"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getDocCreatedByUpdatedByList($workspaceId: String!, $pagination: PaginationInput!) { workspace(id: $workspaceId) { __typename docs(pagination: $pagination) { __typename totalCount pageInfo { __typename endCursor hasNextPage } edges { __typename node { __typename id creatorId lastUpdaterId } } } } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var pagination: PaginationInput
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
pagination: PaginationInput
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.pagination = pagination
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"pagination": pagination
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("workspace", Workspace.self, arguments: ["id": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
/// Get workspace by id
|
||||
public var workspace: Workspace { __data["workspace"] }
|
||||
|
||||
/// Workspace
|
||||
///
|
||||
/// Parent Type: `WorkspaceType`
|
||||
public struct Workspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("docs", Docs.self, arguments: ["pagination": .variable("pagination")]),
|
||||
] }
|
||||
|
||||
public var docs: Docs { __data["docs"] }
|
||||
|
||||
/// Workspace.Docs
|
||||
///
|
||||
/// Parent Type: `PaginatedDocType`
|
||||
public struct Docs: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.PaginatedDocType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("totalCount", Int.self),
|
||||
.field("pageInfo", PageInfo.self),
|
||||
.field("edges", [Edge].self),
|
||||
] }
|
||||
|
||||
public var totalCount: Int { __data["totalCount"] }
|
||||
public var pageInfo: PageInfo { __data["pageInfo"] }
|
||||
public var edges: [Edge] { __data["edges"] }
|
||||
|
||||
/// Workspace.Docs.PageInfo
|
||||
///
|
||||
/// Parent Type: `PageInfo`
|
||||
public struct PageInfo: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.PageInfo }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("endCursor", String?.self),
|
||||
.field("hasNextPage", Bool.self),
|
||||
] }
|
||||
|
||||
public var endCursor: String? { __data["endCursor"] }
|
||||
public var hasNextPage: Bool { __data["hasNextPage"] }
|
||||
}
|
||||
|
||||
/// Workspace.Docs.Edge
|
||||
///
|
||||
/// Parent Type: `DocTypeEdge`
|
||||
public struct Edge: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.DocTypeEdge }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("node", Node.self),
|
||||
] }
|
||||
|
||||
public var node: Node { __data["node"] }
|
||||
|
||||
/// Workspace.Docs.Edge.Node
|
||||
///
|
||||
/// Parent Type: `DocType`
|
||||
public struct Node: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.DocType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("creatorId", String?.self),
|
||||
.field("lastUpdaterId", String?.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var creatorId: String? { __data["creatorId"] }
|
||||
public var lastUpdaterId: String? { __data["lastUpdaterId"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -27,7 +27,7 @@ public class GetInviteInfoQuery: GraphQLQuery {
|
||||
.field("getInviteInfo", GetInviteInfo.self, arguments: ["inviteId": .variable("inviteId")]),
|
||||
] }
|
||||
|
||||
/// send workspace invitation
|
||||
/// get workspace invitation info
|
||||
public var getInviteInfo: GetInviteInfo { __data["getInviteInfo"] }
|
||||
|
||||
/// GetInviteInfo
|
||||
|
||||
@@ -1,34 +0,0 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class GetIsAdminQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getIsAdmin"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getIsAdmin($workspaceId: String!) { isAdmin(workspaceId: $workspaceId) }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
|
||||
public init(workspaceId: String) {
|
||||
self.workspaceId = workspaceId
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["workspaceId": workspaceId] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("isAdmin", Bool.self, arguments: ["workspaceId": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
/// Get is admin of workspace
|
||||
@available(*, deprecated, message: "use WorkspaceType[role] instead")
|
||||
public var isAdmin: Bool { __data["isAdmin"] }
|
||||
}
|
||||
}
|
||||
@@ -1,34 +0,0 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class GetIsOwnerQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getIsOwner"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getIsOwner($workspaceId: String!) { isOwner(workspaceId: $workspaceId) }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
|
||||
public init(workspaceId: String) {
|
||||
self.workspaceId = workspaceId
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["workspaceId": workspaceId] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("isOwner", Bool.self, arguments: ["workspaceId": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
/// Get is owner of workspace
|
||||
@available(*, deprecated, message: "use WorkspaceType[role] instead")
|
||||
public var isOwner: Bool { __data["isOwner"] }
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,8 @@ public class GetLicenseQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getLicense"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getLicense($workspaceId: String!) { workspace(id: $workspaceId) { __typename license { __typename expiredAt installedAt quantity recurring validatedAt } } }"#
|
||||
#"query getLicense($workspaceId: String!) { workspace(id: $workspaceId) { __typename license { __typename ...licenseBody } } }"#,
|
||||
fragments: [LicenseBody.self]
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
@@ -56,11 +57,7 @@ public class GetLicenseQuery: GraphQLQuery {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.License }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("expiredAt", AffineGraphQL.DateTime?.self),
|
||||
.field("installedAt", AffineGraphQL.DateTime.self),
|
||||
.field("quantity", Int.self),
|
||||
.field("recurring", GraphQLEnum<AffineGraphQL.SubscriptionRecurring>.self),
|
||||
.field("validatedAt", AffineGraphQL.DateTime.self),
|
||||
.fragment(LicenseBody.self),
|
||||
] }
|
||||
|
||||
public var expiredAt: AffineGraphQL.DateTime? { __data["expiredAt"] }
|
||||
@@ -68,6 +65,14 @@ public class GetLicenseQuery: GraphQLQuery {
|
||||
public var quantity: Int { __data["quantity"] }
|
||||
public var recurring: GraphQLEnum<AffineGraphQL.SubscriptionRecurring> { __data["recurring"] }
|
||||
public var validatedAt: AffineGraphQL.DateTime { __data["validatedAt"] }
|
||||
public var variant: GraphQLEnum<AffineGraphQL.SubscriptionVariant>? { __data["variant"] }
|
||||
|
||||
public struct Fragments: FragmentContainer {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public var licenseBody: LicenseBody { _toFragment() }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ public class GetPromptsQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getPrompts"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getPrompts { listCopilotPrompts { __typename name model action config { __typename jsonMode frequencyPenalty presencePenalty temperature topP } messages { __typename role content params } } }"#
|
||||
#"query getPrompts { listCopilotPrompts { __typename name model action config { __typename frequencyPenalty presencePenalty temperature topP } messages { __typename role content params } } }"#
|
||||
))
|
||||
|
||||
public init() {}
|
||||
@@ -57,14 +57,12 @@ public class GetPromptsQuery: GraphQLQuery {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotPromptConfigType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("jsonMode", Bool?.self),
|
||||
.field("frequencyPenalty", Double?.self),
|
||||
.field("presencePenalty", Double?.self),
|
||||
.field("temperature", Double?.self),
|
||||
.field("topP", Double?.self),
|
||||
] }
|
||||
|
||||
public var jsonMode: Bool? { __data["jsonMode"] }
|
||||
public var frequencyPenalty: Double? { __data["frequencyPenalty"] }
|
||||
public var presencePenalty: Double? { __data["presencePenalty"] }
|
||||
public var temperature: Double? { __data["temperature"] }
|
||||
|
||||
@@ -1,27 +0,0 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class GetUsersCountQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getUsersCount"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getUsersCount { usersCount }"#
|
||||
))
|
||||
|
||||
public init() {}
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("usersCount", Int.self),
|
||||
] }
|
||||
|
||||
/// Get users count
|
||||
public var usersCount: Int { __data["usersCount"] }
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,7 @@ public class GetWorkspaceConfigQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getWorkspaceConfig"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getWorkspaceConfig($id: String!) { workspace(id: $id) { __typename enableAi enableUrlPreview inviteLink { __typename link expireTime } } }"#
|
||||
#"query getWorkspaceConfig($id: String!) { workspace(id: $id) { __typename enableAi enableUrlPreview enableDocEmbedding inviteLink { __typename link expireTime } } }"#
|
||||
))
|
||||
|
||||
public var id: String
|
||||
@@ -42,6 +42,7 @@ public class GetWorkspaceConfigQuery: GraphQLQuery {
|
||||
.field("__typename", String.self),
|
||||
.field("enableAi", Bool.self),
|
||||
.field("enableUrlPreview", Bool.self),
|
||||
.field("enableDocEmbedding", Bool.self),
|
||||
.field("inviteLink", InviteLink?.self),
|
||||
] }
|
||||
|
||||
@@ -49,6 +50,8 @@ public class GetWorkspaceConfigQuery: GraphQLQuery {
|
||||
public var enableAi: Bool { __data["enableAi"] }
|
||||
/// Enable url previous when sharing
|
||||
public var enableUrlPreview: Bool { __data["enableUrlPreview"] }
|
||||
/// Enable doc embedding
|
||||
public var enableDocEmbedding: Bool { __data["enableDocEmbedding"] }
|
||||
/// invite link for workspace
|
||||
public var inviteLink: InviteLink? { __data["inviteLink"] }
|
||||
|
||||
|
||||
@@ -0,0 +1,153 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class GetWorkspaceEmbeddingFilesQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getWorkspaceEmbeddingFiles"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getWorkspaceEmbeddingFiles($workspaceId: String!, $pagination: PaginationInput!) { workspace(id: $workspaceId) { __typename embedding { __typename files(pagination: $pagination) { __typename totalCount pageInfo { __typename endCursor hasNextPage } edges { __typename node { __typename fileId fileName blobId mimeType size createdAt } } } } } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var pagination: PaginationInput
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
pagination: PaginationInput
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.pagination = pagination
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"pagination": pagination
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("workspace", Workspace.self, arguments: ["id": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
/// Get workspace by id
|
||||
public var workspace: Workspace { __data["workspace"] }
|
||||
|
||||
/// Workspace
|
||||
///
|
||||
/// Parent Type: `WorkspaceType`
|
||||
public struct Workspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("embedding", Embedding.self),
|
||||
] }
|
||||
|
||||
public var embedding: Embedding { __data["embedding"] }
|
||||
|
||||
/// Workspace.Embedding
|
||||
///
|
||||
/// Parent Type: `CopilotWorkspaceConfig`
|
||||
public struct Embedding: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotWorkspaceConfig }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("files", Files.self, arguments: ["pagination": .variable("pagination")]),
|
||||
] }
|
||||
|
||||
public var files: Files { __data["files"] }
|
||||
|
||||
/// Workspace.Embedding.Files
|
||||
///
|
||||
/// Parent Type: `PaginatedCopilotWorkspaceFileType`
|
||||
public struct Files: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.PaginatedCopilotWorkspaceFileType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("totalCount", Int.self),
|
||||
.field("pageInfo", PageInfo.self),
|
||||
.field("edges", [Edge].self),
|
||||
] }
|
||||
|
||||
public var totalCount: Int { __data["totalCount"] }
|
||||
public var pageInfo: PageInfo { __data["pageInfo"] }
|
||||
public var edges: [Edge] { __data["edges"] }
|
||||
|
||||
/// Workspace.Embedding.Files.PageInfo
|
||||
///
|
||||
/// Parent Type: `PageInfo`
|
||||
public struct PageInfo: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.PageInfo }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("endCursor", String?.self),
|
||||
.field("hasNextPage", Bool.self),
|
||||
] }
|
||||
|
||||
public var endCursor: String? { __data["endCursor"] }
|
||||
public var hasNextPage: Bool { __data["hasNextPage"] }
|
||||
}
|
||||
|
||||
/// Workspace.Embedding.Files.Edge
|
||||
///
|
||||
/// Parent Type: `CopilotWorkspaceFileTypeEdge`
|
||||
public struct Edge: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotWorkspaceFileTypeEdge }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("node", Node.self),
|
||||
] }
|
||||
|
||||
public var node: Node { __data["node"] }
|
||||
|
||||
/// Workspace.Embedding.Files.Edge.Node
|
||||
///
|
||||
/// Parent Type: `CopilotWorkspaceFile`
|
||||
public struct Node: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotWorkspaceFile }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("fileId", String.self),
|
||||
.field("fileName", String.self),
|
||||
.field("blobId", String.self),
|
||||
.field("mimeType", String.self),
|
||||
.field("size", AffineGraphQL.SafeInt.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
] }
|
||||
|
||||
public var fileId: String { __data["fileId"] }
|
||||
public var fileName: String { __data["fileName"] }
|
||||
public var blobId: String { __data["blobId"] }
|
||||
public var mimeType: String { __data["mimeType"] }
|
||||
public var size: AffineGraphQL.SafeInt { __data["size"] }
|
||||
public var createdAt: AffineGraphQL.DateTime { __data["createdAt"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,157 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class GetWorkspaceEmbeddingIgnoredDocsQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getWorkspaceEmbeddingIgnoredDocs"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getWorkspaceEmbeddingIgnoredDocs($workspaceId: String!, $pagination: PaginationInput!) { workspace(id: $workspaceId) { __typename embedding { __typename ignoredDocs(pagination: $pagination) { __typename totalCount pageInfo { __typename endCursor hasNextPage } edges { __typename node { __typename docId createdAt docCreatedAt docUpdatedAt title createdBy createdByAvatar updatedBy } } } } } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var pagination: PaginationInput
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
pagination: PaginationInput
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.pagination = pagination
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"pagination": pagination
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("workspace", Workspace.self, arguments: ["id": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
/// Get workspace by id
|
||||
public var workspace: Workspace { __data["workspace"] }
|
||||
|
||||
/// Workspace
|
||||
///
|
||||
/// Parent Type: `WorkspaceType`
|
||||
public struct Workspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("embedding", Embedding.self),
|
||||
] }
|
||||
|
||||
public var embedding: Embedding { __data["embedding"] }
|
||||
|
||||
/// Workspace.Embedding
|
||||
///
|
||||
/// Parent Type: `CopilotWorkspaceConfig`
|
||||
public struct Embedding: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotWorkspaceConfig }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("ignoredDocs", IgnoredDocs.self, arguments: ["pagination": .variable("pagination")]),
|
||||
] }
|
||||
|
||||
public var ignoredDocs: IgnoredDocs { __data["ignoredDocs"] }
|
||||
|
||||
/// Workspace.Embedding.IgnoredDocs
|
||||
///
|
||||
/// Parent Type: `PaginatedIgnoredDocsType`
|
||||
public struct IgnoredDocs: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.PaginatedIgnoredDocsType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("totalCount", Int.self),
|
||||
.field("pageInfo", PageInfo.self),
|
||||
.field("edges", [Edge].self),
|
||||
] }
|
||||
|
||||
public var totalCount: Int { __data["totalCount"] }
|
||||
public var pageInfo: PageInfo { __data["pageInfo"] }
|
||||
public var edges: [Edge] { __data["edges"] }
|
||||
|
||||
/// Workspace.Embedding.IgnoredDocs.PageInfo
|
||||
///
|
||||
/// Parent Type: `PageInfo`
|
||||
public struct PageInfo: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.PageInfo }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("endCursor", String?.self),
|
||||
.field("hasNextPage", Bool.self),
|
||||
] }
|
||||
|
||||
public var endCursor: String? { __data["endCursor"] }
|
||||
public var hasNextPage: Bool { __data["hasNextPage"] }
|
||||
}
|
||||
|
||||
/// Workspace.Embedding.IgnoredDocs.Edge
|
||||
///
|
||||
/// Parent Type: `CopilotWorkspaceIgnoredDocTypeEdge`
|
||||
public struct Edge: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotWorkspaceIgnoredDocTypeEdge }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("node", Node.self),
|
||||
] }
|
||||
|
||||
public var node: Node { __data["node"] }
|
||||
|
||||
/// Workspace.Embedding.IgnoredDocs.Edge.Node
|
||||
///
|
||||
/// Parent Type: `CopilotWorkspaceIgnoredDoc`
|
||||
public struct Node: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotWorkspaceIgnoredDoc }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("docId", String.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
.field("docCreatedAt", AffineGraphQL.DateTime?.self),
|
||||
.field("docUpdatedAt", AffineGraphQL.DateTime?.self),
|
||||
.field("title", String?.self),
|
||||
.field("createdBy", String?.self),
|
||||
.field("createdByAvatar", String?.self),
|
||||
.field("updatedBy", String?.self),
|
||||
] }
|
||||
|
||||
public var docId: String { __data["docId"] }
|
||||
public var createdAt: AffineGraphQL.DateTime { __data["createdAt"] }
|
||||
public var docCreatedAt: AffineGraphQL.DateTime? { __data["docCreatedAt"] }
|
||||
public var docUpdatedAt: AffineGraphQL.DateTime? { __data["docUpdatedAt"] }
|
||||
public var title: String? { __data["title"] }
|
||||
public var createdBy: String? { __data["createdBy"] }
|
||||
public var createdByAvatar: String? { __data["createdByAvatar"] }
|
||||
public var updatedBy: String? { __data["updatedBy"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,7 @@ public class GetWorkspaceInfoQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getWorkspaceInfo"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getWorkspaceInfo($workspaceId: String!) { isAdmin(workspaceId: $workspaceId) isOwner(workspaceId: $workspaceId) workspace(id: $workspaceId) { __typename team } }"#
|
||||
#"query getWorkspaceInfo($workspaceId: String!) { workspace(id: $workspaceId) { __typename role team } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
@@ -24,17 +24,9 @@ public class GetWorkspaceInfoQuery: GraphQLQuery {
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("isAdmin", Bool.self, arguments: ["workspaceId": .variable("workspaceId")]),
|
||||
.field("isOwner", Bool.self, arguments: ["workspaceId": .variable("workspaceId")]),
|
||||
.field("workspace", Workspace.self, arguments: ["id": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
/// Get is admin of workspace
|
||||
@available(*, deprecated, message: "use WorkspaceType[role] instead")
|
||||
public var isAdmin: Bool { __data["isAdmin"] }
|
||||
/// Get is owner of workspace
|
||||
@available(*, deprecated, message: "use WorkspaceType[role] instead")
|
||||
public var isOwner: Bool { __data["isOwner"] }
|
||||
/// Get workspace by id
|
||||
public var workspace: Workspace { __data["workspace"] }
|
||||
|
||||
@@ -48,9 +40,12 @@ public class GetWorkspaceInfoQuery: GraphQLQuery {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("role", GraphQLEnum<AffineGraphQL.Permission>.self),
|
||||
.field("team", Bool.self),
|
||||
] }
|
||||
|
||||
/// Role of current signed in user in workspace
|
||||
public var role: GraphQLEnum<AffineGraphQL.Permission> { __data["role"] }
|
||||
/// if workspace is team workspace
|
||||
public var team: Bool { __data["team"] }
|
||||
}
|
||||
|
||||
@@ -52,16 +52,17 @@ public class GetWorkspacePageMetaByIdQuery: GraphQLQuery {
|
||||
] }
|
||||
|
||||
/// Cloud page metadata of workspace
|
||||
@available(*, deprecated, message: "use [WorkspaceType.doc] instead")
|
||||
public var pageMeta: PageMeta { __data["pageMeta"] }
|
||||
|
||||
/// Workspace.PageMeta
|
||||
///
|
||||
/// Parent Type: `WorkspacePageMeta`
|
||||
/// Parent Type: `WorkspaceDocMeta`
|
||||
public struct PageMeta: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspacePageMeta }
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceDocMeta }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
|
||||
@@ -0,0 +1,153 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class IndexerAggregateQuery: GraphQLQuery {
|
||||
public static let operationName: String = "indexerAggregate"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query indexerAggregate($id: String!, $input: AggregateInput!) { workspace(id: $id) { __typename aggregate(input: $input) { __typename buckets { __typename key count hits { __typename nodes { __typename fields highlights } } } pagination { __typename count hasMore nextCursor } } } }"#
|
||||
))
|
||||
|
||||
public var id: String
|
||||
public var input: AggregateInput
|
||||
|
||||
public init(
|
||||
id: String,
|
||||
input: AggregateInput
|
||||
) {
|
||||
self.id = id
|
||||
self.input = input
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"id": id,
|
||||
"input": input
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("workspace", Workspace.self, arguments: ["id": .variable("id")]),
|
||||
] }
|
||||
|
||||
/// Get workspace by id
|
||||
public var workspace: Workspace { __data["workspace"] }
|
||||
|
||||
/// Workspace
|
||||
///
|
||||
/// Parent Type: `WorkspaceType`
|
||||
public struct Workspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("aggregate", Aggregate.self, arguments: ["input": .variable("input")]),
|
||||
] }
|
||||
|
||||
/// Search a specific table with aggregate
|
||||
public var aggregate: Aggregate { __data["aggregate"] }
|
||||
|
||||
/// Workspace.Aggregate
|
||||
///
|
||||
/// Parent Type: `AggregateResultObjectType`
|
||||
public struct Aggregate: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.AggregateResultObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("buckets", [Bucket].self),
|
||||
.field("pagination", Pagination.self),
|
||||
] }
|
||||
|
||||
public var buckets: [Bucket] { __data["buckets"] }
|
||||
public var pagination: Pagination { __data["pagination"] }
|
||||
|
||||
/// Workspace.Aggregate.Bucket
|
||||
///
|
||||
/// Parent Type: `AggregateBucketObjectType`
|
||||
public struct Bucket: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.AggregateBucketObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("key", String.self),
|
||||
.field("count", Int.self),
|
||||
.field("hits", Hits.self),
|
||||
] }
|
||||
|
||||
public var key: String { __data["key"] }
|
||||
public var count: Int { __data["count"] }
|
||||
/// The hits object
|
||||
public var hits: Hits { __data["hits"] }
|
||||
|
||||
/// Workspace.Aggregate.Bucket.Hits
|
||||
///
|
||||
/// Parent Type: `AggregateBucketHitsObjectType`
|
||||
public struct Hits: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.AggregateBucketHitsObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("nodes", [Node].self),
|
||||
] }
|
||||
|
||||
public var nodes: [Node] { __data["nodes"] }
|
||||
|
||||
/// Workspace.Aggregate.Bucket.Hits.Node
|
||||
///
|
||||
/// Parent Type: `SearchNodeObjectType`
|
||||
public struct Node: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.SearchNodeObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("fields", AffineGraphQL.JSONObject.self),
|
||||
.field("highlights", AffineGraphQL.JSONObject?.self),
|
||||
] }
|
||||
|
||||
/// The search result fields, see UnionSearchItemObjectType
|
||||
public var fields: AffineGraphQL.JSONObject { __data["fields"] }
|
||||
/// The search result fields, see UnionSearchItemObjectType
|
||||
public var highlights: AffineGraphQL.JSONObject? { __data["highlights"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Workspace.Aggregate.Pagination
|
||||
///
|
||||
/// Parent Type: `SearchResultPagination`
|
||||
public struct Pagination: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.SearchResultPagination }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("count", Int.self),
|
||||
.field("hasMore", Bool.self),
|
||||
.field("nextCursor", String?.self),
|
||||
] }
|
||||
|
||||
public var count: Int { __data["count"] }
|
||||
public var hasMore: Bool { __data["hasMore"] }
|
||||
public var nextCursor: String? { __data["nextCursor"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,116 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class IndexerSearchQuery: GraphQLQuery {
|
||||
public static let operationName: String = "indexerSearch"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query indexerSearch($id: String!, $input: SearchInput!) { workspace(id: $id) { __typename search(input: $input) { __typename nodes { __typename fields highlights } pagination { __typename count hasMore nextCursor } } } }"#
|
||||
))
|
||||
|
||||
public var id: String
|
||||
public var input: SearchInput
|
||||
|
||||
public init(
|
||||
id: String,
|
||||
input: SearchInput
|
||||
) {
|
||||
self.id = id
|
||||
self.input = input
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"id": id,
|
||||
"input": input
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("workspace", Workspace.self, arguments: ["id": .variable("id")]),
|
||||
] }
|
||||
|
||||
/// Get workspace by id
|
||||
public var workspace: Workspace { __data["workspace"] }
|
||||
|
||||
/// Workspace
|
||||
///
|
||||
/// Parent Type: `WorkspaceType`
|
||||
public struct Workspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("search", Search.self, arguments: ["input": .variable("input")]),
|
||||
] }
|
||||
|
||||
/// Search a specific table
|
||||
public var search: Search { __data["search"] }
|
||||
|
||||
/// Workspace.Search
|
||||
///
|
||||
/// Parent Type: `SearchResultObjectType`
|
||||
public struct Search: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.SearchResultObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("nodes", [Node].self),
|
||||
.field("pagination", Pagination.self),
|
||||
] }
|
||||
|
||||
public var nodes: [Node] { __data["nodes"] }
|
||||
public var pagination: Pagination { __data["pagination"] }
|
||||
|
||||
/// Workspace.Search.Node
|
||||
///
|
||||
/// Parent Type: `SearchNodeObjectType`
|
||||
public struct Node: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.SearchNodeObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("fields", AffineGraphQL.JSONObject.self),
|
||||
.field("highlights", AffineGraphQL.JSONObject?.self),
|
||||
] }
|
||||
|
||||
/// The search result fields, see UnionSearchItemObjectType
|
||||
public var fields: AffineGraphQL.JSONObject { __data["fields"] }
|
||||
/// The search result fields, see UnionSearchItemObjectType
|
||||
public var highlights: AffineGraphQL.JSONObject? { __data["highlights"] }
|
||||
}
|
||||
|
||||
/// Workspace.Search.Pagination
|
||||
///
|
||||
/// Parent Type: `SearchResultPagination`
|
||||
public struct Pagination: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.SearchResultPagination }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("count", Int.self),
|
||||
.field("hasMore", Bool.self),
|
||||
.field("nextCursor", String?.self),
|
||||
] }
|
||||
|
||||
public var count: Int { __data["count"] }
|
||||
public var hasMore: Bool { __data["hasMore"] }
|
||||
public var nextCursor: String? { __data["nextCursor"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,7 @@ public class ListContextObjectQuery: GraphQLQuery {
|
||||
public static let operationName: String = "listContextObject"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query listContextObject($workspaceId: String!, $sessionId: String!, $contextId: String!) { currentUser { __typename copilot(workspaceId: $workspaceId) { __typename contexts(sessionId: $sessionId, contextId: $contextId) { __typename docs { __typename id status error createdAt } files { __typename id name blobId chunkSize error status createdAt } tags { __typename type id docs { __typename id status createdAt } createdAt } collections { __typename type id docs { __typename id status createdAt } createdAt } } } } }"#
|
||||
#"query listContextObject($workspaceId: String!, $sessionId: String!, $contextId: String!) { currentUser { __typename copilot(workspaceId: $workspaceId) { __typename contexts(sessionId: $sessionId, contextId: $contextId) { __typename docs { __typename id status error createdAt } files { __typename id name mimeType blobId chunkSize error status createdAt } tags { __typename type id docs { __typename id status createdAt } createdAt } collections { __typename type id docs { __typename id status createdAt } createdAt } } } } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
@@ -135,6 +135,7 @@ public class ListContextObjectQuery: GraphQLQuery {
|
||||
.field("__typename", String.self),
|
||||
.field("id", AffineGraphQL.ID.self),
|
||||
.field("name", String.self),
|
||||
.field("mimeType", String.self),
|
||||
.field("blobId", String.self),
|
||||
.field("chunkSize", AffineGraphQL.SafeInt.self),
|
||||
.field("error", String?.self),
|
||||
@@ -144,6 +145,7 @@ public class ListContextObjectQuery: GraphQLQuery {
|
||||
|
||||
public var id: AffineGraphQL.ID { __data["id"] }
|
||||
public var name: String { __data["name"] }
|
||||
public var mimeType: String { __data["mimeType"] }
|
||||
public var blobId: String { __data["blobId"] }
|
||||
public var chunkSize: AffineGraphQL.SafeInt { __data["chunkSize"] }
|
||||
public var error: String? { __data["error"] }
|
||||
|
||||
@@ -79,11 +79,11 @@ public class ListContextQuery: GraphQLQuery {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotContext }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", AffineGraphQL.ID.self),
|
||||
.field("id", AffineGraphQL.ID?.self),
|
||||
.field("workspaceId", String.self),
|
||||
] }
|
||||
|
||||
public var id: AffineGraphQL.ID { __data["id"] }
|
||||
public var id: AffineGraphQL.ID? { __data["id"] }
|
||||
public var workspaceId: String { __data["workspaceId"] }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ public class ListUsersQuery: GraphQLQuery {
|
||||
public static let operationName: String = "listUsers"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query listUsers($filter: ListUserInput!) { users(filter: $filter) { __typename id name email disabled features hasPassword emailVerified avatarUrl } }"#
|
||||
#"query listUsers($filter: ListUserInput!) { users(filter: $filter) { __typename id name email disabled features hasPassword emailVerified avatarUrl } usersCount }"#
|
||||
))
|
||||
|
||||
public var filter: ListUserInput
|
||||
@@ -25,10 +25,13 @@ public class ListUsersQuery: GraphQLQuery {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("users", [User].self, arguments: ["filter": .variable("filter")]),
|
||||
.field("usersCount", Int.self),
|
||||
] }
|
||||
|
||||
/// List registered users
|
||||
public var users: [User] { __data["users"] }
|
||||
/// Get users count
|
||||
public var usersCount: Int { __data["usersCount"] }
|
||||
|
||||
/// User
|
||||
///
|
||||
|
||||
@@ -7,30 +7,38 @@ public class MatchContextQuery: GraphQLQuery {
|
||||
public static let operationName: String = "matchContext"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query matchContext($contextId: String!, $content: String!, $limit: SafeInt, $threshold: Float) { currentUser { __typename copilot { __typename contexts(contextId: $contextId) { __typename matchFiles(content: $content, limit: $limit, threshold: $threshold) { __typename fileId chunk content distance } matchWorkspaceDocs(content: $content, limit: $limit, threshold: $threshold) { __typename docId chunk content distance } } } } }"#
|
||||
#"query matchContext($contextId: String, $workspaceId: String, $content: String!, $limit: SafeInt, $scopedThreshold: Float, $threshold: Float) { currentUser { __typename copilot(workspaceId: $workspaceId) { __typename contexts(contextId: $contextId) { __typename matchFiles( content: $content limit: $limit scopedThreshold: $scopedThreshold threshold: $threshold ) { __typename fileId blobId name mimeType chunk content distance } matchWorkspaceDocs( content: $content limit: $limit scopedThreshold: $scopedThreshold threshold: $threshold ) { __typename docId chunk content distance } } } } }"#
|
||||
))
|
||||
|
||||
public var contextId: String
|
||||
public var contextId: GraphQLNullable<String>
|
||||
public var workspaceId: GraphQLNullable<String>
|
||||
public var content: String
|
||||
public var limit: GraphQLNullable<SafeInt>
|
||||
public var scopedThreshold: GraphQLNullable<Double>
|
||||
public var threshold: GraphQLNullable<Double>
|
||||
|
||||
public init(
|
||||
contextId: String,
|
||||
contextId: GraphQLNullable<String>,
|
||||
workspaceId: GraphQLNullable<String>,
|
||||
content: String,
|
||||
limit: GraphQLNullable<SafeInt>,
|
||||
scopedThreshold: GraphQLNullable<Double>,
|
||||
threshold: GraphQLNullable<Double>
|
||||
) {
|
||||
self.contextId = contextId
|
||||
self.workspaceId = workspaceId
|
||||
self.content = content
|
||||
self.limit = limit
|
||||
self.scopedThreshold = scopedThreshold
|
||||
self.threshold = threshold
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"contextId": contextId,
|
||||
"workspaceId": workspaceId,
|
||||
"content": content,
|
||||
"limit": limit,
|
||||
"scopedThreshold": scopedThreshold,
|
||||
"threshold": threshold
|
||||
] }
|
||||
|
||||
@@ -56,7 +64,7 @@ public class MatchContextQuery: GraphQLQuery {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("copilot", Copilot.self),
|
||||
.field("copilot", Copilot.self, arguments: ["workspaceId": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
public var copilot: Copilot { __data["copilot"] }
|
||||
@@ -90,11 +98,13 @@ public class MatchContextQuery: GraphQLQuery {
|
||||
.field("matchFiles", [MatchFile].self, arguments: [
|
||||
"content": .variable("content"),
|
||||
"limit": .variable("limit"),
|
||||
"scopedThreshold": .variable("scopedThreshold"),
|
||||
"threshold": .variable("threshold")
|
||||
]),
|
||||
.field("matchWorkspaceDocs", [MatchWorkspaceDoc].self, arguments: [
|
||||
"content": .variable("content"),
|
||||
"limit": .variable("limit"),
|
||||
"scopedThreshold": .variable("scopedThreshold"),
|
||||
"threshold": .variable("threshold")
|
||||
]),
|
||||
] }
|
||||
@@ -115,12 +125,18 @@ public class MatchContextQuery: GraphQLQuery {
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("fileId", String.self),
|
||||
.field("blobId", String.self),
|
||||
.field("name", String.self),
|
||||
.field("mimeType", String.self),
|
||||
.field("chunk", AffineGraphQL.SafeInt.self),
|
||||
.field("content", String.self),
|
||||
.field("distance", Double?.self),
|
||||
] }
|
||||
|
||||
public var fileId: String { __data["fileId"] }
|
||||
public var blobId: String { __data["blobId"] }
|
||||
public var name: String { __data["name"] }
|
||||
public var mimeType: String { __data["mimeType"] }
|
||||
public var chunk: AffineGraphQL.SafeInt { __data["chunk"] }
|
||||
public var content: String { __data["content"] }
|
||||
public var distance: Double? { __data["distance"] }
|
||||
|
||||
@@ -7,27 +7,39 @@ public class MatchFilesQuery: GraphQLQuery {
|
||||
public static let operationName: String = "matchFiles"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query matchFiles($contextId: String!, $content: String!, $limit: SafeInt) { currentUser { __typename copilot { __typename contexts(contextId: $contextId) { __typename matchFiles(content: $content, limit: $limit) { __typename fileId chunk content distance } } } } }"#
|
||||
#"query matchFiles($contextId: String, $workspaceId: String, $content: String!, $limit: SafeInt, $scopedThreshold: Float, $threshold: Float) { currentUser { __typename copilot(workspaceId: $workspaceId) { __typename contexts(contextId: $contextId) { __typename matchFiles( content: $content limit: $limit scopedThreshold: $scopedThreshold threshold: $threshold ) { __typename fileId blobId chunk content distance } } } } }"#
|
||||
))
|
||||
|
||||
public var contextId: String
|
||||
public var contextId: GraphQLNullable<String>
|
||||
public var workspaceId: GraphQLNullable<String>
|
||||
public var content: String
|
||||
public var limit: GraphQLNullable<SafeInt>
|
||||
public var scopedThreshold: GraphQLNullable<Double>
|
||||
public var threshold: GraphQLNullable<Double>
|
||||
|
||||
public init(
|
||||
contextId: String,
|
||||
contextId: GraphQLNullable<String>,
|
||||
workspaceId: GraphQLNullable<String>,
|
||||
content: String,
|
||||
limit: GraphQLNullable<SafeInt>
|
||||
limit: GraphQLNullable<SafeInt>,
|
||||
scopedThreshold: GraphQLNullable<Double>,
|
||||
threshold: GraphQLNullable<Double>
|
||||
) {
|
||||
self.contextId = contextId
|
||||
self.workspaceId = workspaceId
|
||||
self.content = content
|
||||
self.limit = limit
|
||||
self.scopedThreshold = scopedThreshold
|
||||
self.threshold = threshold
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"contextId": contextId,
|
||||
"workspaceId": workspaceId,
|
||||
"content": content,
|
||||
"limit": limit
|
||||
"limit": limit,
|
||||
"scopedThreshold": scopedThreshold,
|
||||
"threshold": threshold
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
@@ -52,7 +64,7 @@ public class MatchFilesQuery: GraphQLQuery {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("copilot", Copilot.self),
|
||||
.field("copilot", Copilot.self, arguments: ["workspaceId": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
public var copilot: Copilot { __data["copilot"] }
|
||||
@@ -85,7 +97,9 @@ public class MatchFilesQuery: GraphQLQuery {
|
||||
.field("__typename", String.self),
|
||||
.field("matchFiles", [MatchFile].self, arguments: [
|
||||
"content": .variable("content"),
|
||||
"limit": .variable("limit")
|
||||
"limit": .variable("limit"),
|
||||
"scopedThreshold": .variable("scopedThreshold"),
|
||||
"threshold": .variable("threshold")
|
||||
]),
|
||||
] }
|
||||
|
||||
@@ -103,12 +117,14 @@ public class MatchFilesQuery: GraphQLQuery {
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("fileId", String.self),
|
||||
.field("blobId", String.self),
|
||||
.field("chunk", AffineGraphQL.SafeInt.self),
|
||||
.field("content", String.self),
|
||||
.field("distance", Double?.self),
|
||||
] }
|
||||
|
||||
public var fileId: String { __data["fileId"] }
|
||||
public var blobId: String { __data["blobId"] }
|
||||
public var chunk: AffineGraphQL.SafeInt { __data["chunk"] }
|
||||
public var content: String { __data["content"] }
|
||||
public var distance: Double? { __data["distance"] }
|
||||
|
||||
@@ -7,27 +7,39 @@ public class MatchWorkspaceDocsQuery: GraphQLQuery {
|
||||
public static let operationName: String = "matchWorkspaceDocs"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query matchWorkspaceDocs($contextId: String!, $content: String!, $limit: SafeInt) { currentUser { __typename copilot { __typename contexts(contextId: $contextId) { __typename matchWorkspaceDocs(content: $content, limit: $limit) { __typename docId chunk content distance } } } } }"#
|
||||
#"query matchWorkspaceDocs($contextId: String, $workspaceId: String, $content: String!, $limit: SafeInt, $scopedThreshold: Float, $threshold: Float) { currentUser { __typename copilot(workspaceId: $workspaceId) { __typename contexts(contextId: $contextId) { __typename matchWorkspaceDocs( content: $content limit: $limit scopedThreshold: $scopedThreshold threshold: $threshold ) { __typename docId chunk content distance } } } } }"#
|
||||
))
|
||||
|
||||
public var contextId: String
|
||||
public var contextId: GraphQLNullable<String>
|
||||
public var workspaceId: GraphQLNullable<String>
|
||||
public var content: String
|
||||
public var limit: GraphQLNullable<SafeInt>
|
||||
public var scopedThreshold: GraphQLNullable<Double>
|
||||
public var threshold: GraphQLNullable<Double>
|
||||
|
||||
public init(
|
||||
contextId: String,
|
||||
contextId: GraphQLNullable<String>,
|
||||
workspaceId: GraphQLNullable<String>,
|
||||
content: String,
|
||||
limit: GraphQLNullable<SafeInt>
|
||||
limit: GraphQLNullable<SafeInt>,
|
||||
scopedThreshold: GraphQLNullable<Double>,
|
||||
threshold: GraphQLNullable<Double>
|
||||
) {
|
||||
self.contextId = contextId
|
||||
self.workspaceId = workspaceId
|
||||
self.content = content
|
||||
self.limit = limit
|
||||
self.scopedThreshold = scopedThreshold
|
||||
self.threshold = threshold
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"contextId": contextId,
|
||||
"workspaceId": workspaceId,
|
||||
"content": content,
|
||||
"limit": limit
|
||||
"limit": limit,
|
||||
"scopedThreshold": scopedThreshold,
|
||||
"threshold": threshold
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
@@ -52,7 +64,7 @@ public class MatchWorkspaceDocsQuery: GraphQLQuery {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("copilot", Copilot.self),
|
||||
.field("copilot", Copilot.self, arguments: ["workspaceId": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
public var copilot: Copilot { __data["copilot"] }
|
||||
@@ -85,7 +97,9 @@ public class MatchWorkspaceDocsQuery: GraphQLQuery {
|
||||
.field("__typename", String.self),
|
||||
.field("matchWorkspaceDocs", [MatchWorkspaceDoc].self, arguments: [
|
||||
"content": .variable("content"),
|
||||
"limit": .variable("limit")
|
||||
"limit": .variable("limit"),
|
||||
"scopedThreshold": .variable("scopedThreshold"),
|
||||
"threshold": .variable("threshold")
|
||||
]),
|
||||
] }
|
||||
|
||||
|
||||
@@ -0,0 +1,84 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class WorkspaceBlobQuotaQuery: GraphQLQuery {
|
||||
public static let operationName: String = "workspaceBlobQuota"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query workspaceBlobQuota($id: String!) { workspace(id: $id) { __typename quota { __typename blobLimit humanReadable { __typename blobLimit } } } }"#
|
||||
))
|
||||
|
||||
public var id: String
|
||||
|
||||
public init(id: String) {
|
||||
self.id = id
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["id": id] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("workspace", Workspace.self, arguments: ["id": .variable("id")]),
|
||||
] }
|
||||
|
||||
/// Get workspace by id
|
||||
public var workspace: Workspace { __data["workspace"] }
|
||||
|
||||
/// Workspace
|
||||
///
|
||||
/// Parent Type: `WorkspaceType`
|
||||
public struct Workspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("quota", Quota.self),
|
||||
] }
|
||||
|
||||
/// quota of workspace
|
||||
public var quota: Quota { __data["quota"] }
|
||||
|
||||
/// Workspace.Quota
|
||||
///
|
||||
/// Parent Type: `WorkspaceQuotaType`
|
||||
public struct Quota: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceQuotaType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("blobLimit", AffineGraphQL.SafeInt.self),
|
||||
.field("humanReadable", HumanReadable.self),
|
||||
] }
|
||||
|
||||
public var blobLimit: AffineGraphQL.SafeInt { __data["blobLimit"] }
|
||||
public var humanReadable: HumanReadable { __data["humanReadable"] }
|
||||
|
||||
/// Workspace.Quota.HumanReadable
|
||||
///
|
||||
/// Parent Type: `WorkspaceQuotaHumanReadableType`
|
||||
public struct HumanReadable: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceQuotaHumanReadableType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("blobLimit", String.self),
|
||||
] }
|
||||
|
||||
public var blobLimit: String { __data["blobLimit"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,7 @@ public class WorkspaceQuotaQuery: GraphQLQuery {
|
||||
public static let operationName: String = "workspaceQuota"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query workspaceQuota($id: String!) { workspace(id: $id) { __typename quota { __typename name blobLimit storageQuota usedStorageQuota historyPeriod memberLimit memberCount humanReadable { __typename name blobLimit storageQuota historyPeriod memberLimit } } } }"#
|
||||
#"query workspaceQuota($id: String!) { workspace(id: $id) { __typename quota { __typename name blobLimit storageQuota usedStorageQuota historyPeriod memberLimit memberCount overcapacityMemberCount humanReadable { __typename name blobLimit storageQuota historyPeriod memberLimit memberCount overcapacityMemberCount } } } }"#
|
||||
))
|
||||
|
||||
public var id: String
|
||||
@@ -63,6 +63,7 @@ public class WorkspaceQuotaQuery: GraphQLQuery {
|
||||
.field("historyPeriod", AffineGraphQL.SafeInt.self),
|
||||
.field("memberLimit", Int.self),
|
||||
.field("memberCount", Int.self),
|
||||
.field("overcapacityMemberCount", Int.self),
|
||||
.field("humanReadable", HumanReadable.self),
|
||||
] }
|
||||
|
||||
@@ -73,6 +74,7 @@ public class WorkspaceQuotaQuery: GraphQLQuery {
|
||||
public var historyPeriod: AffineGraphQL.SafeInt { __data["historyPeriod"] }
|
||||
public var memberLimit: Int { __data["memberLimit"] }
|
||||
public var memberCount: Int { __data["memberCount"] }
|
||||
public var overcapacityMemberCount: Int { __data["overcapacityMemberCount"] }
|
||||
public var humanReadable: HumanReadable { __data["humanReadable"] }
|
||||
|
||||
/// Workspace.Quota.HumanReadable
|
||||
@@ -90,6 +92,8 @@ public class WorkspaceQuotaQuery: GraphQLQuery {
|
||||
.field("storageQuota", String.self),
|
||||
.field("historyPeriod", String.self),
|
||||
.field("memberLimit", String.self),
|
||||
.field("memberCount", String.self),
|
||||
.field("overcapacityMemberCount", String.self),
|
||||
] }
|
||||
|
||||
public var name: String { __data["name"] }
|
||||
@@ -97,6 +101,8 @@ public class WorkspaceQuotaQuery: GraphQLQuery {
|
||||
public var storageQuota: String { __data["storageQuota"] }
|
||||
public var historyPeriod: String { __data["historyPeriod"] }
|
||||
public var memberLimit: String { __data["memberLimit"] }
|
||||
public var memberCount: String { __data["memberCount"] }
|
||||
public var overcapacityMemberCount: String { __data["overcapacityMemberCount"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
import ApolloAPI
|
||||
|
||||
public enum OAuthProviderType: String, EnumType {
|
||||
case apple = "Apple"
|
||||
case gitHub = "GitHub"
|
||||
case google = "Google"
|
||||
case oidc = "OIDC"
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
/// Search query occur
|
||||
public enum SearchQueryOccur: String, EnumType {
|
||||
case must = "must"
|
||||
case mustNot = "must_not"
|
||||
case should = "should"
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
/// Search query type
|
||||
public enum SearchQueryType: String, EnumType {
|
||||
case all = "all"
|
||||
case boolean = "boolean"
|
||||
case boost = "boost"
|
||||
case exists = "exists"
|
||||
case match = "match"
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
/// Search table
|
||||
public enum SearchTable: String, EnumType {
|
||||
case block = "block"
|
||||
case doc = "doc"
|
||||
}
|
||||
@@ -6,6 +6,8 @@ import ApolloAPI
|
||||
public enum ServerFeature: String, EnumType {
|
||||
case captcha = "Captcha"
|
||||
case copilot = "Copilot"
|
||||
case copilotEmbedding = "CopilotEmbedding"
|
||||
case indexer = "Indexer"
|
||||
case oAuth = "OAuth"
|
||||
case payment = "Payment"
|
||||
}
|
||||
|
||||
@@ -6,6 +6,7 @@ import ApolloAPI
|
||||
/// Member invite status in workspace
|
||||
public enum WorkspaceMemberStatus: String, EnumType {
|
||||
case accepted = "Accepted"
|
||||
case allocatingSeat = "AllocatingSeat"
|
||||
case needMoreSeat = "NeedMoreSeat"
|
||||
case needMoreSeatAndReview = "NeedMoreSeatAndReview"
|
||||
case pending = "Pending"
|
||||
|
||||
@@ -0,0 +1,39 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct AggregateHitsOptions: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
fields: [String],
|
||||
highlights: GraphQLNullable<[SearchHighlight]> = nil,
|
||||
pagination: GraphQLNullable<AggregateHitsPagination> = nil
|
||||
) {
|
||||
__data = InputDict([
|
||||
"fields": fields,
|
||||
"highlights": highlights,
|
||||
"pagination": pagination
|
||||
])
|
||||
}
|
||||
|
||||
public var fields: [String] {
|
||||
get { __data["fields"] }
|
||||
set { __data["fields"] = newValue }
|
||||
}
|
||||
|
||||
public var highlights: GraphQLNullable<[SearchHighlight]> {
|
||||
get { __data["highlights"] }
|
||||
set { __data["highlights"] = newValue }
|
||||
}
|
||||
|
||||
public var pagination: GraphQLNullable<AggregateHitsPagination> {
|
||||
get { __data["pagination"] }
|
||||
set { __data["pagination"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct AggregateHitsPagination: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
limit: GraphQLNullable<Int> = nil,
|
||||
skip: GraphQLNullable<Int> = nil
|
||||
) {
|
||||
__data = InputDict([
|
||||
"limit": limit,
|
||||
"skip": skip
|
||||
])
|
||||
}
|
||||
|
||||
public var limit: GraphQLNullable<Int> {
|
||||
get { __data["limit"] }
|
||||
set { __data["limit"] = newValue }
|
||||
}
|
||||
|
||||
public var skip: GraphQLNullable<Int> {
|
||||
get { __data["skip"] }
|
||||
set { __data["skip"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct AggregateInput: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
field: String,
|
||||
options: AggregateOptions,
|
||||
query: SearchQuery,
|
||||
table: GraphQLEnum<SearchTable>
|
||||
) {
|
||||
__data = InputDict([
|
||||
"field": field,
|
||||
"options": options,
|
||||
"query": query,
|
||||
"table": table
|
||||
])
|
||||
}
|
||||
|
||||
public var field: String {
|
||||
get { __data["field"] }
|
||||
set { __data["field"] = newValue }
|
||||
}
|
||||
|
||||
public var options: AggregateOptions {
|
||||
get { __data["options"] }
|
||||
set { __data["options"] = newValue }
|
||||
}
|
||||
|
||||
public var query: SearchQuery {
|
||||
get { __data["query"] }
|
||||
set { __data["query"] = newValue }
|
||||
}
|
||||
|
||||
public var table: GraphQLEnum<SearchTable> {
|
||||
get { __data["table"] }
|
||||
set { __data["table"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct AggregateOptions: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
hits: AggregateHitsOptions,
|
||||
pagination: GraphQLNullable<SearchPagination> = nil
|
||||
) {
|
||||
__data = InputDict([
|
||||
"hits": hits,
|
||||
"pagination": pagination
|
||||
])
|
||||
}
|
||||
|
||||
public var hits: AggregateHitsOptions {
|
||||
get { __data["hits"] }
|
||||
set { __data["hits"] = newValue }
|
||||
}
|
||||
|
||||
public var pagination: GraphQLNullable<SearchPagination> {
|
||||
get { __data["pagination"] }
|
||||
set { __data["pagination"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -12,11 +12,13 @@ public struct CreateUserInput: InputObject {
|
||||
|
||||
public init(
|
||||
email: String,
|
||||
name: GraphQLNullable<String> = nil
|
||||
name: GraphQLNullable<String> = nil,
|
||||
password: GraphQLNullable<String> = nil
|
||||
) {
|
||||
__data = InputDict([
|
||||
"email": email,
|
||||
"name": name
|
||||
"name": name,
|
||||
"password": password
|
||||
])
|
||||
}
|
||||
|
||||
@@ -29,4 +31,9 @@ public struct CreateUserInput: InputObject {
|
||||
get { __data["name"] }
|
||||
set { __data["name"] = newValue }
|
||||
}
|
||||
|
||||
public var password: GraphQLNullable<String> {
|
||||
get { __data["password"] }
|
||||
set { __data["password"] = newValue }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@ public struct ForkChatSessionInput: InputObject {
|
||||
|
||||
public init(
|
||||
docId: String,
|
||||
latestMessageId: String,
|
||||
latestMessageId: GraphQLNullable<String> = nil,
|
||||
sessionId: String,
|
||||
workspaceId: String
|
||||
) {
|
||||
@@ -30,7 +30,7 @@ public struct ForkChatSessionInput: InputObject {
|
||||
}
|
||||
|
||||
/// Identify a message in the array and keep it with all previous messages into a forked session.
|
||||
public var latestMessageId: String {
|
||||
public var latestMessageId: GraphQLNullable<String> {
|
||||
get { __data["latestMessageId"] }
|
||||
set { __data["latestMessageId"] = newValue }
|
||||
}
|
||||
|
||||
@@ -0,0 +1,39 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct SearchHighlight: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
before: String,
|
||||
end: String,
|
||||
field: String
|
||||
) {
|
||||
__data = InputDict([
|
||||
"before": before,
|
||||
"end": end,
|
||||
"field": field
|
||||
])
|
||||
}
|
||||
|
||||
public var before: String {
|
||||
get { __data["before"] }
|
||||
set { __data["before"] = newValue }
|
||||
}
|
||||
|
||||
public var end: String {
|
||||
get { __data["end"] }
|
||||
set { __data["end"] = newValue }
|
||||
}
|
||||
|
||||
public var field: String {
|
||||
get { __data["field"] }
|
||||
set { __data["field"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct SearchInput: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
options: SearchOptions,
|
||||
query: SearchQuery,
|
||||
table: GraphQLEnum<SearchTable>
|
||||
) {
|
||||
__data = InputDict([
|
||||
"options": options,
|
||||
"query": query,
|
||||
"table": table
|
||||
])
|
||||
}
|
||||
|
||||
public var options: SearchOptions {
|
||||
get { __data["options"] }
|
||||
set { __data["options"] = newValue }
|
||||
}
|
||||
|
||||
public var query: SearchQuery {
|
||||
get { __data["query"] }
|
||||
set { __data["query"] = newValue }
|
||||
}
|
||||
|
||||
public var table: GraphQLEnum<SearchTable> {
|
||||
get { __data["table"] }
|
||||
set { __data["table"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct SearchOptions: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
fields: [String],
|
||||
highlights: GraphQLNullable<[SearchHighlight]> = nil,
|
||||
pagination: GraphQLNullable<SearchPagination> = nil
|
||||
) {
|
||||
__data = InputDict([
|
||||
"fields": fields,
|
||||
"highlights": highlights,
|
||||
"pagination": pagination
|
||||
])
|
||||
}
|
||||
|
||||
public var fields: [String] {
|
||||
get { __data["fields"] }
|
||||
set { __data["fields"] = newValue }
|
||||
}
|
||||
|
||||
public var highlights: GraphQLNullable<[SearchHighlight]> {
|
||||
get { __data["highlights"] }
|
||||
set { __data["highlights"] = newValue }
|
||||
}
|
||||
|
||||
public var pagination: GraphQLNullable<SearchPagination> {
|
||||
get { __data["pagination"] }
|
||||
set { __data["pagination"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct SearchPagination: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
cursor: GraphQLNullable<String> = nil,
|
||||
limit: GraphQLNullable<Int> = nil,
|
||||
skip: GraphQLNullable<Int> = nil
|
||||
) {
|
||||
__data = InputDict([
|
||||
"cursor": cursor,
|
||||
"limit": limit,
|
||||
"skip": skip
|
||||
])
|
||||
}
|
||||
|
||||
public var cursor: GraphQLNullable<String> {
|
||||
get { __data["cursor"] }
|
||||
set { __data["cursor"] = newValue }
|
||||
}
|
||||
|
||||
public var limit: GraphQLNullable<Int> {
|
||||
get { __data["limit"] }
|
||||
set { __data["limit"] = newValue }
|
||||
}
|
||||
|
||||
public var skip: GraphQLNullable<Int> {
|
||||
get { __data["skip"] }
|
||||
set { __data["skip"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,67 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct SearchQuery: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
boost: GraphQLNullable<Double> = nil,
|
||||
field: GraphQLNullable<String> = nil,
|
||||
match: GraphQLNullable<String> = nil,
|
||||
occur: GraphQLNullable<GraphQLEnum<SearchQueryOccur>> = nil,
|
||||
queries: GraphQLNullable<[SearchQuery]> = nil,
|
||||
query: GraphQLNullable<SearchQuery> = nil,
|
||||
type: GraphQLEnum<SearchQueryType>
|
||||
) {
|
||||
__data = InputDict([
|
||||
"boost": boost,
|
||||
"field": field,
|
||||
"match": match,
|
||||
"occur": occur,
|
||||
"queries": queries,
|
||||
"query": query,
|
||||
"type": type
|
||||
])
|
||||
}
|
||||
|
||||
public var boost: GraphQLNullable<Double> {
|
||||
get { __data["boost"] }
|
||||
set { __data["boost"] = newValue }
|
||||
}
|
||||
|
||||
public var field: GraphQLNullable<String> {
|
||||
get { __data["field"] }
|
||||
set { __data["field"] = newValue }
|
||||
}
|
||||
|
||||
public var match: GraphQLNullable<String> {
|
||||
get { __data["match"] }
|
||||
set { __data["match"] = newValue }
|
||||
}
|
||||
|
||||
public var occur: GraphQLNullable<GraphQLEnum<SearchQueryOccur>> {
|
||||
get { __data["occur"] }
|
||||
set { __data["occur"] = newValue }
|
||||
}
|
||||
|
||||
public var queries: GraphQLNullable<[SearchQuery]> {
|
||||
get { __data["queries"] }
|
||||
set { __data["queries"] = newValue }
|
||||
}
|
||||
|
||||
public var query: GraphQLNullable<SearchQuery> {
|
||||
get { __data["query"] }
|
||||
set { __data["query"] = newValue }
|
||||
}
|
||||
|
||||
public var type: GraphQLEnum<SearchQueryType> {
|
||||
get { __data["type"] }
|
||||
set { __data["type"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let AggregateBucketHitsObjectType = ApolloAPI.Object(
|
||||
typename: "AggregateBucketHitsObjectType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let AggregateBucketObjectType = ApolloAPI.Object(
|
||||
typename: "AggregateBucketObjectType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let AggregateResultObjectType = ApolloAPI.Object(
|
||||
typename: "AggregateResultObjectType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let AppConfigValidateResult = ApolloAPI.Object(
|
||||
typename: "AppConfigValidateResult",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let CopilotWorkspaceConfig = ApolloAPI.Object(
|
||||
typename: "CopilotWorkspaceConfig",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let CopilotWorkspaceFile = ApolloAPI.Object(
|
||||
typename: "CopilotWorkspaceFile",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let CopilotWorkspaceFileTypeEdge = ApolloAPI.Object(
|
||||
typename: "CopilotWorkspaceFileTypeEdge",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let CopilotWorkspaceIgnoredDoc = ApolloAPI.Object(
|
||||
typename: "CopilotWorkspaceIgnoredDoc",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let CopilotWorkspaceIgnoredDocTypeEdge = ApolloAPI.Object(
|
||||
typename: "CopilotWorkspaceIgnoredDocTypeEdge",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -4,8 +4,8 @@
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let WorkspacePageMeta = ApolloAPI.Object(
|
||||
typename: "WorkspacePageMeta",
|
||||
static let DocTypeEdge = ApolloAPI.Object(
|
||||
typename: "DocTypeEdge",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let PaginatedCopilotWorkspaceFileType = ApolloAPI.Object(
|
||||
typename: "PaginatedCopilotWorkspaceFileType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let PaginatedDocType = ApolloAPI.Object(
|
||||
typename: "PaginatedDocType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let PaginatedIgnoredDocsType = ApolloAPI.Object(
|
||||
typename: "PaginatedIgnoredDocsType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let SearchNodeObjectType = ApolloAPI.Object(
|
||||
typename: "SearchNodeObjectType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let SearchResultObjectType = ApolloAPI.Object(
|
||||
typename: "SearchResultObjectType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let SearchResultPagination = ApolloAPI.Object(
|
||||
typename: "SearchResultPagination",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let WorkspaceDocMeta = ApolloAPI.Object(
|
||||
typename: "WorkspaceDocMeta",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -20,6 +20,10 @@ public enum SchemaMetadata: ApolloAPI.SchemaMetadata {
|
||||
|
||||
public static func objectType(forTypename typename: String) -> ApolloAPI.Object? {
|
||||
switch typename {
|
||||
case "AggregateBucketHitsObjectType": return AffineGraphQL.Objects.AggregateBucketHitsObjectType
|
||||
case "AggregateBucketObjectType": return AffineGraphQL.Objects.AggregateBucketObjectType
|
||||
case "AggregateResultObjectType": return AffineGraphQL.Objects.AggregateResultObjectType
|
||||
case "AppConfigValidateResult": return AffineGraphQL.Objects.AppConfigValidateResult
|
||||
case "ChatMessage": return AffineGraphQL.Objects.ChatMessage
|
||||
case "ContextMatchedDocChunk": return AffineGraphQL.Objects.ContextMatchedDocChunk
|
||||
case "ContextMatchedFileChunk": return AffineGraphQL.Objects.ContextMatchedFileChunk
|
||||
@@ -36,11 +40,17 @@ public enum SchemaMetadata: ApolloAPI.SchemaMetadata {
|
||||
case "CopilotPromptType": return AffineGraphQL.Objects.CopilotPromptType
|
||||
case "CopilotQuota": return AffineGraphQL.Objects.CopilotQuota
|
||||
case "CopilotSessionType": return AffineGraphQL.Objects.CopilotSessionType
|
||||
case "CopilotWorkspaceConfig": return AffineGraphQL.Objects.CopilotWorkspaceConfig
|
||||
case "CopilotWorkspaceFile": return AffineGraphQL.Objects.CopilotWorkspaceFile
|
||||
case "CopilotWorkspaceFileTypeEdge": return AffineGraphQL.Objects.CopilotWorkspaceFileTypeEdge
|
||||
case "CopilotWorkspaceIgnoredDoc": return AffineGraphQL.Objects.CopilotWorkspaceIgnoredDoc
|
||||
case "CopilotWorkspaceIgnoredDocTypeEdge": return AffineGraphQL.Objects.CopilotWorkspaceIgnoredDocTypeEdge
|
||||
case "CredentialsRequirementType": return AffineGraphQL.Objects.CredentialsRequirementType
|
||||
case "DeleteAccount": return AffineGraphQL.Objects.DeleteAccount
|
||||
case "DocHistoryType": return AffineGraphQL.Objects.DocHistoryType
|
||||
case "DocPermissions": return AffineGraphQL.Objects.DocPermissions
|
||||
case "DocType": return AffineGraphQL.Objects.DocType
|
||||
case "DocTypeEdge": return AffineGraphQL.Objects.DocTypeEdge
|
||||
case "EditorType": return AffineGraphQL.Objects.EditorType
|
||||
case "GrantedDocUserType": return AffineGraphQL.Objects.GrantedDocUserType
|
||||
case "GrantedDocUserTypeEdge": return AffineGraphQL.Objects.GrantedDocUserTypeEdge
|
||||
@@ -57,13 +67,19 @@ public enum SchemaMetadata: ApolloAPI.SchemaMetadata {
|
||||
case "NotificationObjectType": return AffineGraphQL.Objects.NotificationObjectType
|
||||
case "NotificationObjectTypeEdge": return AffineGraphQL.Objects.NotificationObjectTypeEdge
|
||||
case "PageInfo": return AffineGraphQL.Objects.PageInfo
|
||||
case "PaginatedCopilotWorkspaceFileType": return AffineGraphQL.Objects.PaginatedCopilotWorkspaceFileType
|
||||
case "PaginatedDocType": return AffineGraphQL.Objects.PaginatedDocType
|
||||
case "PaginatedGrantedDocUserType": return AffineGraphQL.Objects.PaginatedGrantedDocUserType
|
||||
case "PaginatedIgnoredDocsType": return AffineGraphQL.Objects.PaginatedIgnoredDocsType
|
||||
case "PaginatedNotificationObjectType": return AffineGraphQL.Objects.PaginatedNotificationObjectType
|
||||
case "PasswordLimitsType": return AffineGraphQL.Objects.PasswordLimitsType
|
||||
case "PublicUserType": return AffineGraphQL.Objects.PublicUserType
|
||||
case "Query": return AffineGraphQL.Objects.Query
|
||||
case "ReleaseVersionType": return AffineGraphQL.Objects.ReleaseVersionType
|
||||
case "RemoveAvatar": return AffineGraphQL.Objects.RemoveAvatar
|
||||
case "SearchNodeObjectType": return AffineGraphQL.Objects.SearchNodeObjectType
|
||||
case "SearchResultObjectType": return AffineGraphQL.Objects.SearchResultObjectType
|
||||
case "SearchResultPagination": return AffineGraphQL.Objects.SearchResultPagination
|
||||
case "ServerConfigType": return AffineGraphQL.Objects.ServerConfigType
|
||||
case "SubscriptionPrice": return AffineGraphQL.Objects.SubscriptionPrice
|
||||
case "SubscriptionType": return AffineGraphQL.Objects.SubscriptionType
|
||||
@@ -75,7 +91,7 @@ public enum SchemaMetadata: ApolloAPI.SchemaMetadata {
|
||||
case "UserQuotaUsageType": return AffineGraphQL.Objects.UserQuotaUsageType
|
||||
case "UserSettingsType": return AffineGraphQL.Objects.UserSettingsType
|
||||
case "UserType": return AffineGraphQL.Objects.UserType
|
||||
case "WorkspacePageMeta": return AffineGraphQL.Objects.WorkspacePageMeta
|
||||
case "WorkspaceDocMeta": return AffineGraphQL.Objects.WorkspaceDocMeta
|
||||
case "WorkspacePermissions": return AffineGraphQL.Objects.WorkspacePermissions
|
||||
case "WorkspaceQuotaHumanReadableType": return AffineGraphQL.Objects.WorkspaceQuotaHumanReadableType
|
||||
case "WorkspaceQuotaType": return AffineGraphQL.Objects.WorkspaceQuotaType
|
||||
|
||||
@@ -1,77 +0,0 @@
|
||||
{
|
||||
"pins" : [
|
||||
{
|
||||
"identity" : "apollo-ios",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/apollographql/apollo-ios.git",
|
||||
"state" : {
|
||||
"revision" : "c3f48d45ec1300bc95243bf19f67284f9dc0d14a",
|
||||
"version" : "1.15.3"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "msdisplaylink",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/Lakr233/MSDisplayLink",
|
||||
"state" : {
|
||||
"revision" : "6e92b5513e3473e064685e64056c4ac46470e7b0",
|
||||
"version" : "2.0.3"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "networkimage",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/gonzalezreal/NetworkImage",
|
||||
"state" : {
|
||||
"revision" : "2849f5323265386e200484b0d0f896e73c3411b9",
|
||||
"version" : "6.0.1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "springinterpolation",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/Lakr233/SpringInterpolation",
|
||||
"state" : {
|
||||
"revision" : "f9d1ee3d2466bdb00fd0ade7f256ed20229c8413",
|
||||
"version" : "1.3.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "sqlite.swift",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/stephencelis/SQLite.swift.git",
|
||||
"state" : {
|
||||
"revision" : "a95fc6df17d108bd99210db5e8a9bac90fe984b8",
|
||||
"version" : "0.15.3"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "swift-cmark",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/swiftlang/swift-cmark",
|
||||
"state" : {
|
||||
"revision" : "3ccff77b2dc5b96b77db3da0d68d28068593fa53",
|
||||
"version" : "0.5.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "swift-eventsource",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/LaunchDarkly/swift-eventsource.git",
|
||||
"state" : {
|
||||
"revision" : "57051701c58a93603ffa2051f8e9cf0c8cff7814",
|
||||
"version" : "3.3.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "swift-markdown-ui",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/gonzalezreal/swift-markdown-ui",
|
||||
"state" : {
|
||||
"revision" : "5f613358148239d0292c0cef674a3c2314737f9e",
|
||||
"version" : "2.4.1"
|
||||
}
|
||||
}
|
||||
],
|
||||
"version" : 2
|
||||
}
|
||||
@@ -7,29 +7,30 @@ let package = Package(
|
||||
name: "Intelligents",
|
||||
defaultLocalization: "en",
|
||||
platforms: [
|
||||
.iOS(.v15),
|
||||
.macCatalyst(.v15),
|
||||
.iOS(.v16),
|
||||
],
|
||||
products: [
|
||||
.library(name: "Intelligents", targets: ["Intelligents"]),
|
||||
],
|
||||
dependencies: [
|
||||
.package(path: "../AffineGraphQL"),
|
||||
.package(path: "../MarkdownView"),
|
||||
.package(url: "https://github.com/apollographql/apollo-ios.git", from: "1.22.0"),
|
||||
.package(url: "https://github.com/LaunchDarkly/swift-eventsource.git", from: "3.3.0"),
|
||||
.package(url: "https://github.com/apollographql/apollo-ios.git", from: "1.18.0"),
|
||||
.package(url: "https://github.com/apple/swift-collections", from: "1.2.0"),
|
||||
.package(url: "https://github.com/Lakr233/ChidoriMenu", from: "3.0.0"),
|
||||
.package(url: "https://github.com/devxoul/Then", from: "3.0.0"),
|
||||
.package(url: "https://github.com/SnapKit/SnapKit.git", from: "5.0.1"),
|
||||
.package(url: "https://github.com/SwifterSwift/SwifterSwift.git", from: "6.0.0"),
|
||||
],
|
||||
targets: [
|
||||
.target(name: "Intelligents", dependencies: [
|
||||
"AffineGraphQL",
|
||||
"ChidoriMenu",
|
||||
"MarkdownView",
|
||||
"ChidoriMenu",
|
||||
"SnapKit",
|
||||
"Then",
|
||||
"SwifterSwift",
|
||||
.product(name: "Apollo", package: "apollo-ios"),
|
||||
.product(name: "LDSwiftEventSource", package: "swift-eventsource"),
|
||||
.product(name: "OrderedCollections", package: "swift-collections"),
|
||||
], resources: [
|
||||
.process("Resources/main.metal"),
|
||||
.process("Interface/View/InputBox/InputBox.xcassets"),
|
||||
]),
|
||||
]
|
||||
)
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user