@gitpod/gitpod-protocol 0.1.5-procmount.0 → 0.1.5-protected-secrets.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/data/gitpod-schema.json +149 -29
- package/lib/accounting-protocol.d.ts +163 -0
- package/lib/accounting-protocol.d.ts.map +1 -0
- package/lib/accounting-protocol.js +111 -0
- package/lib/accounting-protocol.js.map +1 -0
- package/lib/admin-protocol.d.ts +39 -4
- package/lib/admin-protocol.d.ts.map +1 -1
- package/lib/admin-protocol.js +15 -0
- package/lib/admin-protocol.js.map +1 -1
- package/lib/analytics.d.ts +44 -0
- package/lib/analytics.d.ts.map +1 -0
- package/lib/analytics.js +10 -0
- package/lib/analytics.js.map +1 -0
- package/lib/attribution.d.ts +23 -0
- package/lib/attribution.d.ts.map +1 -0
- package/lib/attribution.js +50 -0
- package/lib/attribution.js.map +1 -0
- package/lib/auth.d.ts.map +1 -1
- package/lib/billing-mode.d.ts +43 -0
- package/lib/billing-mode.d.ts.map +1 -0
- package/lib/billing-mode.js +44 -0
- package/lib/billing-mode.js.map +1 -0
- package/lib/blocked-repositories-protocol.d.ts +13 -0
- package/lib/blocked-repositories-protocol.d.ts.map +1 -0
- package/lib/blocked-repositories-protocol.js +8 -0
- package/lib/blocked-repositories-protocol.js.map +1 -0
- package/lib/context-url.d.ts +31 -0
- package/lib/context-url.d.ts.map +1 -0
- package/lib/context-url.js +102 -0
- package/lib/context-url.js.map +1 -0
- package/lib/context-url.spec.d.ts +14 -0
- package/lib/context-url.spec.d.ts.map +1 -0
- package/lib/context-url.spec.js +109 -0
- package/lib/context-url.spec.js.map +1 -0
- package/lib/encryption/container-module.d.ts.map +1 -1
- package/lib/encryption/container-module.js +5 -4
- package/lib/encryption/container-module.js.map +1 -1
- package/lib/encryption/encryption-engine.d.ts.map +1 -1
- package/lib/encryption/encryption-engine.js +25 -26
- package/lib/encryption/encryption-engine.js.map +1 -1
- package/lib/encryption/encryption-engine.spec.d.ts.map +1 -1
- package/lib/encryption/encryption-engine.spec.js +29 -37
- package/lib/encryption/encryption-engine.spec.js.map +1 -1
- package/lib/encryption/encryption-service.d.ts.map +1 -1
- package/lib/encryption/encryption-service.js +30 -44
- package/lib/encryption/encryption-service.js.map +1 -1
- package/lib/encryption/key-provider.d.ts.map +1 -1
- package/lib/encryption/key-provider.js +31 -38
- package/lib/encryption/key-provider.js.map +1 -1
- package/lib/env.d.ts +0 -6
- package/lib/env.d.ts.map +1 -1
- package/lib/env.js +7 -27
- package/lib/env.js.map +1 -1
- package/lib/experiments/always-default.d.ts +8 -0
- package/lib/experiments/always-default.d.ts.map +1 -0
- package/lib/experiments/always-default.js +20 -0
- package/lib/experiments/always-default.js.map +1 -0
- package/lib/experiments/configcat-server.d.ts +10 -0
- package/lib/experiments/configcat-server.d.ts.map +1 -0
- package/lib/experiments/configcat-server.js +36 -0
- package/lib/experiments/configcat-server.js.map +1 -0
- package/lib/experiments/configcat.d.ts +21 -0
- package/lib/experiments/configcat.d.ts.map +1 -0
- package/lib/experiments/configcat.js +51 -0
- package/lib/experiments/configcat.js.map +1 -0
- package/lib/experiments/types.d.ts +22 -0
- package/lib/experiments/types.d.ts.map +1 -0
- package/lib/experiments/types.js +10 -0
- package/lib/experiments/types.js.map +1 -0
- package/lib/gitpod-file-parser.d.ts.map +1 -1
- package/lib/gitpod-file-parser.js +26 -42
- package/lib/gitpod-file-parser.js.map +1 -1
- package/lib/gitpod-file-parser.spec.js +145 -142
- package/lib/gitpod-file-parser.spec.js.map +1 -1
- package/lib/gitpod-service.d.ts +195 -39
- package/lib/gitpod-service.d.ts.map +1 -1
- package/lib/gitpod-service.js +204 -271
- package/lib/gitpod-service.js.map +1 -1
- package/lib/headless-workspace-log.d.ts +9 -11
- package/lib/headless-workspace-log.d.ts.map +1 -1
- package/lib/headless-workspace-log.js +6 -8
- package/lib/headless-workspace-log.js.map +1 -1
- package/lib/ide-frontend-service.d.ts +5 -1
- package/lib/ide-frontend-service.d.ts.map +1 -1
- package/lib/ide-protocol.d.ts +113 -0
- package/lib/ide-protocol.d.ts.map +1 -0
- package/lib/{util/without.js → ide-protocol.js} +2 -2
- package/lib/ide-protocol.js.map +1 -0
- package/lib/index.d.ts +16 -10
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +8 -2
- package/lib/index.js.map +1 -1
- package/lib/installation-admin-protocol.d.ts +30 -0
- package/lib/installation-admin-protocol.d.ts.map +1 -0
- package/lib/installation-admin-protocol.js +31 -0
- package/lib/installation-admin-protocol.js.map +1 -0
- package/lib/license-protocol.d.ts +7 -0
- package/lib/license-protocol.d.ts.map +1 -1
- package/lib/license-protocol.js.map +1 -1
- package/lib/messaging/browser/connection.d.ts +5 -3
- package/lib/messaging/browser/connection.d.ts.map +1 -1
- package/lib/messaging/browser/connection.js +184 -34
- package/lib/messaging/browser/connection.js.map +1 -1
- package/lib/messaging/browser/window-connection.d.ts +4 -4
- package/lib/messaging/browser/window-connection.d.ts.map +1 -1
- package/lib/messaging/browser/window-connection.js +42 -59
- package/lib/messaging/browser/window-connection.js.map +1 -1
- package/lib/messaging/client-call-metrics.d.ts +19 -0
- package/lib/messaging/client-call-metrics.d.ts.map +1 -0
- package/lib/messaging/client-call-metrics.js +82 -0
- package/lib/messaging/client-call-metrics.js.map +1 -0
- package/lib/messaging/error.d.ts +11 -2
- package/lib/messaging/error.d.ts.map +1 -1
- package/lib/messaging/error.js +22 -4
- package/lib/messaging/error.js.map +1 -1
- package/lib/messaging/handler.d.ts +10 -0
- package/lib/messaging/handler.d.ts.map +1 -1
- package/lib/messaging/handler.js +1 -1
- package/lib/messaging/node/connection.d.ts +1 -17
- package/lib/messaging/node/connection.d.ts.map +1 -1
- package/lib/messaging/node/connection.js +24 -60
- package/lib/messaging/node/connection.js.map +1 -1
- package/lib/messaging/proxy-factory.d.ts +3 -1
- package/lib/messaging/proxy-factory.d.ts.map +1 -1
- package/lib/messaging/proxy-factory.js +75 -162
- package/lib/messaging/proxy-factory.js.map +1 -1
- package/lib/oss-allowlist.d.ts +14 -0
- package/lib/oss-allowlist.d.ts.map +1 -0
- package/lib/oss-allowlist.js +8 -0
- package/lib/oss-allowlist.js.map +1 -0
- package/lib/payment-protocol.d.ts +18 -0
- package/lib/payment-protocol.d.ts.map +1 -0
- package/lib/payment-protocol.js +13 -0
- package/lib/payment-protocol.js.map +1 -0
- package/lib/permission.d.ts +10 -3
- package/lib/permission.d.ts.map +1 -1
- package/lib/permission.js +41 -31
- package/lib/permission.js.map +1 -1
- package/lib/plans.d.ts +211 -0
- package/lib/plans.d.ts.map +1 -0
- package/lib/plans.js +609 -0
- package/lib/plans.js.map +1 -0
- package/lib/protocol.d.ts +285 -95
- package/lib/protocol.d.ts.map +1 -1
- package/lib/protocol.js +383 -206
- package/lib/protocol.js.map +1 -1
- package/{src/util/without.ts → lib/protocol.spec.d.ts} +2 -3
- package/lib/protocol.spec.d.ts.map +1 -0
- package/lib/protocol.spec.js +127 -0
- package/lib/protocol.spec.js.map +1 -0
- package/lib/snapshot-url.d.ts +14 -0
- package/lib/snapshot-url.d.ts.map +1 -0
- package/lib/snapshot-url.js +26 -0
- package/lib/snapshot-url.js.map +1 -0
- package/{src/theia-plugins.ts → lib/snapshot-url.spec.d.ts} +2 -6
- package/lib/snapshot-url.spec.d.ts.map +1 -0
- package/lib/snapshot-url.spec.js +41 -0
- package/lib/snapshot-url.spec.js.map +1 -0
- package/lib/team-subscription-protocol.d.ts +92 -0
- package/lib/team-subscription-protocol.d.ts.map +1 -0
- package/lib/team-subscription-protocol.js +78 -0
- package/lib/team-subscription-protocol.js.map +1 -0
- package/lib/teams-projects-protocol.d.ts +130 -0
- package/lib/teams-projects-protocol.d.ts.map +1 -0
- package/lib/teams-projects-protocol.js +30 -0
- package/lib/teams-projects-protocol.js.map +1 -0
- package/lib/typings/globals.d.ts +2 -2
- package/lib/typings/globals.d.ts.map +1 -1
- package/lib/usage.d.ts +61 -0
- package/lib/usage.d.ts.map +1 -0
- package/lib/usage.js +14 -0
- package/lib/usage.js.map +1 -0
- package/lib/util/analytics.d.ts +8 -0
- package/lib/util/analytics.d.ts.map +1 -0
- package/lib/util/analytics.js +88 -0
- package/lib/util/analytics.js.map +1 -0
- package/lib/util/async-iterator.d.ts.map +1 -1
- package/lib/util/async-iterator.js +57 -135
- package/lib/util/async-iterator.js.map +1 -1
- package/lib/util/cancelable.js +17 -59
- package/lib/util/cancelable.js.map +1 -1
- package/lib/util/date-time.js +11 -11
- package/lib/util/date-time.js.map +1 -1
- package/lib/util/debug-app.d.ts +25 -0
- package/lib/util/debug-app.d.ts.map +1 -0
- package/lib/util/debug-app.js +100 -0
- package/lib/util/debug-app.js.map +1 -0
- package/lib/util/deferred.js +10 -12
- package/lib/util/deferred.js.map +1 -1
- package/lib/util/disposable.d.ts.map +1 -1
- package/lib/util/disposable.js +27 -40
- package/lib/util/disposable.js.map +1 -1
- package/lib/util/event.d.ts.map +1 -1
- package/lib/util/event.js +63 -77
- package/lib/util/event.js.map +1 -1
- package/lib/util/garbage-collected-cache.d.ts +1 -0
- package/lib/util/garbage-collected-cache.d.ts.map +1 -1
- package/lib/util/garbage-collected-cache.js +32 -47
- package/lib/util/garbage-collected-cache.js.map +1 -1
- package/lib/util/generate-workspace-id.d.ts +6 -1
- package/lib/util/generate-workspace-id.d.ts.map +1 -1
- package/lib/util/generate-workspace-id.js +469 -502
- package/lib/util/generate-workspace-id.js.map +1 -1
- package/lib/util/generate-workspace-id.spec.js +68 -78
- package/lib/util/generate-workspace-id.spec.js.map +1 -1
- package/lib/util/gitpod-cookie.d.ts +20 -0
- package/lib/util/gitpod-cookie.d.ts.map +1 -0
- package/lib/util/gitpod-cookie.js +41 -0
- package/lib/util/gitpod-cookie.js.map +1 -0
- package/lib/util/gitpod-host-url.d.ts +4 -2
- package/lib/util/gitpod-host-url.d.ts.map +1 -1
- package/lib/util/gitpod-host-url.js +126 -109
- package/lib/util/gitpod-host-url.js.map +1 -1
- package/lib/util/gitpod-host-url.spec.d.ts +7 -1
- package/lib/util/gitpod-host-url.spec.d.ts.map +1 -1
- package/lib/util/gitpod-host-url.spec.js +113 -31
- package/lib/util/gitpod-host-url.spec.js.map +1 -1
- package/lib/util/grpc.d.ts +34 -0
- package/lib/util/grpc.d.ts.map +1 -0
- package/lib/util/grpc.js +90 -0
- package/lib/util/grpc.js.map +1 -0
- package/lib/util/jaeger-client-types.d.ts +68 -0
- package/lib/util/jaeger-client-types.d.ts.map +1 -0
- package/lib/{theia-plugins.js → util/jaeger-client-types.js} +1 -1
- package/lib/util/jaeger-client-types.js.map +1 -0
- package/lib/util/logging.d.ts +49 -33
- package/lib/util/logging.d.ts.map +1 -1
- package/lib/util/logging.js +132 -129
- package/lib/util/logging.js.map +1 -1
- package/lib/util/logging.spec.d.ts +7 -0
- package/lib/util/logging.spec.d.ts.map +1 -0
- package/lib/util/logging.spec.js +52 -0
- package/lib/util/logging.spec.js.map +1 -0
- package/lib/util/make-link.js +5 -5
- package/lib/util/make-link.js.map +1 -1
- package/lib/util/nice-grpc.d.ts +9 -0
- package/lib/util/nice-grpc.d.ts.map +1 -0
- package/lib/util/nice-grpc.js +119 -0
- package/lib/util/nice-grpc.js.map +1 -0
- package/lib/util/parse-workspace-id.d.ts +10 -0
- package/lib/util/parse-workspace-id.d.ts.map +1 -1
- package/lib/util/parse-workspace-id.js +31 -7
- package/lib/util/parse-workspace-id.js.map +1 -1
- package/lib/util/parse-workspace-id.spec.d.ts +4 -0
- package/lib/util/parse-workspace-id.spec.d.ts.map +1 -1
- package/lib/util/parse-workspace-id.spec.js +123 -84
- package/lib/util/parse-workspace-id.spec.js.map +1 -1
- package/lib/util/queue.js +16 -55
- package/lib/util/queue.js.map +1 -1
- package/lib/util/queue.spec.js +147 -288
- package/lib/util/queue.spec.js.map +1 -1
- package/lib/util/repeat.d.ts +15 -0
- package/lib/util/repeat.d.ts.map +1 -0
- package/lib/util/repeat.js +55 -0
- package/lib/util/repeat.js.map +1 -0
- package/lib/util/semaphore.d.ts.map +1 -1
- package/lib/util/semaphore.js +15 -46
- package/lib/util/semaphore.js.map +1 -1
- package/lib/util/skip-if.d.ts.map +1 -1
- package/lib/util/skip-if.js +6 -6
- package/lib/util/skip-if.js.map +1 -1
- package/lib/util/timeutil.d.ts +2 -0
- package/lib/util/timeutil.d.ts.map +1 -1
- package/lib/util/timeutil.js +41 -17
- package/lib/util/timeutil.js.map +1 -1
- package/lib/util/timeutil.spec.d.ts +2 -0
- package/lib/util/timeutil.spec.d.ts.map +1 -1
- package/lib/util/timeutil.spec.js +54 -23
- package/lib/util/timeutil.spec.js.map +1 -1
- package/lib/util/tracing.d.ts +52 -6
- package/lib/util/tracing.d.ts.map +1 -1
- package/lib/util/tracing.js +197 -64
- package/lib/util/tracing.js.map +1 -1
- package/lib/util/tracing.spec.d.ts +7 -0
- package/lib/util/tracing.spec.d.ts.map +1 -0
- package/lib/util/tracing.spec.js +121 -0
- package/lib/util/tracing.spec.js.map +1 -0
- package/lib/util/workspace-port-authentication.d.ts +7 -7
- package/lib/util/workspace-port-authentication.d.ts.map +1 -1
- package/lib/util/workspace-port-authentication.js +10 -12
- package/lib/util/workspace-port-authentication.js.map +1 -1
- package/lib/webhook-event.d.ts +44 -0
- package/lib/webhook-event.d.ts.map +1 -0
- package/lib/webhook-event.js +8 -0
- package/lib/webhook-event.js.map +1 -0
- package/lib/workspace-class.d.ts +14 -0
- package/lib/workspace-class.d.ts.map +1 -0
- package/lib/workspace-class.js +8 -0
- package/lib/workspace-class.js.map +1 -0
- package/lib/workspace-cluster.d.ts +75 -0
- package/lib/workspace-cluster.d.ts.map +1 -0
- package/lib/workspace-cluster.js +31 -0
- package/lib/workspace-cluster.js.map +1 -0
- package/lib/workspace-instance.d.ts +46 -5
- package/lib/workspace-instance.d.ts.map +1 -1
- package/lib/wsready.d.ts +1 -1
- package/lib/wsready.d.ts.map +1 -1
- package/lib/wsready.js +2 -2
- package/package.json +40 -18
- package/pkg-yarn.lock +23 -10
- package/provenance-bundle.jsonl +2 -0
- package/src/accounting-protocol.ts +244 -0
- package/src/admin-protocol.ts +80 -19
- package/src/analytics.ts +52 -0
- package/src/attribution.ts +59 -0
- package/src/auth.ts +2 -2
- package/src/billing-mode.ts +81 -0
- package/src/blocked-repositories-protocol.ts +13 -0
- package/src/context-url.spec.ts +67 -0
- package/src/context-url.ts +109 -0
- package/src/encryption/container-module.ts +2 -3
- package/src/encryption/encryption-engine.spec.ts +9 -8
- package/src/encryption/encryption-engine.ts +20 -16
- package/src/encryption/encryption-service.ts +4 -5
- package/src/encryption/key-provider.ts +16 -19
- package/src/env.ts +0 -22
- package/src/experiments/always-default.ts +24 -0
- package/src/experiments/configcat-server.ts +41 -0
- package/src/experiments/configcat.ts +56 -0
- package/src/experiments/types.ts +34 -0
- package/src/gitpod-file-parser.spec.ts +55 -61
- package/src/gitpod-file-parser.ts +16 -17
- package/src/gitpod-service.ts +385 -117
- package/src/headless-workspace-log.ts +12 -14
- package/src/ide-frontend-service.ts +6 -2
- package/src/ide-protocol.ts +129 -0
- package/src/index.ts +16 -10
- package/src/installation-admin-protocol.ts +45 -0
- package/src/license-protocol.ts +12 -6
- package/src/messaging/browser/connection.ts +197 -18
- package/src/messaging/browser/window-connection.ts +39 -29
- package/src/messaging/client-call-metrics.ts +77 -0
- package/src/messaging/error.ts +32 -7
- package/src/messaging/handler.ts +13 -1
- package/src/messaging/node/connection.ts +23 -70
- package/src/messaging/proxy-factory.ts +35 -34
- package/src/oss-allowlist.ts +15 -0
- package/src/payment-protocol.ts +20 -0
- package/src/permission.ts +42 -33
- package/src/plans.ts +683 -0
- package/src/protocol.spec.ts +97 -0
- package/src/protocol.ts +680 -282
- package/src/snapshot-url.spec.ts +27 -0
- package/src/snapshot-url.ts +27 -0
- package/src/team-subscription-protocol.ts +150 -0
- package/src/teams-projects-protocol.ts +166 -0
- package/src/typings/globals.ts +4 -4
- package/src/usage.ts +71 -0
- package/src/util/analytics.ts +109 -0
- package/src/util/async-iterator.ts +4 -5
- package/src/util/cancelable.ts +3 -3
- package/src/util/date-time.ts +8 -8
- package/src/util/debug-app.ts +81 -0
- package/src/util/deferred.ts +6 -6
- package/src/util/disposable.ts +3 -6
- package/src/util/event.ts +9 -11
- package/src/util/garbage-collected-cache.ts +16 -8
- package/src/util/generate-workspace-id.spec.ts +37 -10
- package/src/util/generate-workspace-id.ts +464 -438
- package/src/util/gitpod-cookie.ts +38 -0
- package/src/util/gitpod-host-url.spec.ts +59 -8
- package/src/util/gitpod-host-url.ts +72 -39
- package/src/util/grpc.ts +104 -0
- package/src/util/jaeger-client-types.ts +102 -0
- package/src/util/logging.spec.ts +23 -0
- package/src/util/logging.ts +156 -74
- package/src/util/make-link.ts +6 -7
- package/src/util/nice-grpc.ts +93 -0
- package/src/util/parse-workspace-id.spec.ts +37 -8
- package/src/util/parse-workspace-id.ts +32 -7
- package/src/util/queue.spec.ts +28 -26
- package/src/util/repeat.ts +45 -0
- package/src/util/semaphore.ts +6 -8
- package/src/util/skip-if.ts +10 -7
- package/src/util/timeutil.spec.ts +40 -14
- package/src/util/timeutil.ts +31 -15
- package/src/util/tracing.spec.ts +88 -0
- package/src/util/tracing.ts +200 -31
- package/src/util/workspace-port-authentication.ts +10 -13
- package/src/webhook-event.ts +55 -0
- package/src/workspace-class.ts +14 -0
- package/src/workspace-cluster.ts +109 -0
- package/src/workspace-instance.ts +105 -31
- package/src/wsready.ts +3 -3
- package/data/builtin-theia-plugins.json +0 -372
- package/lib/email-protocol.d.ts +0 -50
- package/lib/email-protocol.d.ts.map +0 -1
- package/lib/email-protocol.js +0 -28
- package/lib/email-protocol.js.map +0 -1
- package/lib/messaging/connection-error-handler.d.ts +0 -27
- package/lib/messaging/connection-error-handler.d.ts.map +0 -1
- package/lib/messaging/connection-error-handler.js +0 -46
- package/lib/messaging/connection-error-handler.js.map +0 -1
- package/lib/theia-plugins.d.ts +0 -11
- package/lib/theia-plugins.d.ts.map +0 -1
- package/lib/theia-plugins.js.map +0 -1
- package/lib/util/context-url.d.ts +0 -13
- package/lib/util/context-url.d.ts.map +0 -1
- package/lib/util/context-url.js +0 -26
- package/lib/util/context-url.js.map +0 -1
- package/lib/util/context-url.spec.d.ts +0 -10
- package/lib/util/context-url.spec.d.ts.map +0 -1
- package/lib/util/context-url.spec.js +0 -52
- package/lib/util/context-url.spec.js.map +0 -1
- package/lib/util/repeater.d.ts +0 -22
- package/lib/util/repeater.d.ts.map +0 -1
- package/lib/util/repeater.js +0 -118
- package/lib/util/repeater.js.map +0 -1
- package/lib/util/safe-promise.d.ts +0 -11
- package/lib/util/safe-promise.d.ts.map +0 -1
- package/lib/util/safe-promise.js +0 -34
- package/lib/util/safe-promise.js.map +0 -1
- package/lib/util/without.d.ts +0 -7
- package/lib/util/without.d.ts.map +0 -1
- package/lib/util/without.js.map +0 -1
- package/src/email-protocol.ts +0 -67
- package/src/messaging/connection-error-handler.ts +0 -62
- package/src/util/context-url.spec.ts +0 -25
- package/src/util/context-url.ts +0 -23
- package/src/util/jaeger-client.d.ts +0 -105
- package/src/util/repeater.ts +0 -49
- package/src/util/safe-promise.ts +0 -26
package/lib/protocol.d.ts
CHANGED
|
@@ -5,6 +5,8 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import { WorkspaceInstance, PortVisibility } from "./workspace-instance";
|
|
7
7
|
import { RoleOrPermission } from "./permission";
|
|
8
|
+
import { Project } from "./teams-projects-protocol";
|
|
9
|
+
import { AttributionId } from "./attribution";
|
|
8
10
|
export interface UserInfo {
|
|
9
11
|
name?: string;
|
|
10
12
|
}
|
|
@@ -18,7 +20,6 @@ export interface User {
|
|
|
18
20
|
/** Optional for backwards compatibility */
|
|
19
21
|
fullName?: string;
|
|
20
22
|
identities: Identity[];
|
|
21
|
-
allowsMarketingCommunication: boolean;
|
|
22
23
|
/**
|
|
23
24
|
* Whether the user has been blocked to use our service, because of TOS violation for example.
|
|
24
25
|
* Optional for backwards compatibility.
|
|
@@ -31,26 +32,76 @@ export interface User {
|
|
|
31
32
|
/** Whether the user is logical deleted. This flag is respected by all queries in UserDB */
|
|
32
33
|
markedDeleted?: boolean;
|
|
33
34
|
additionalData?: AdditionalUserData;
|
|
35
|
+
usageAttributionId?: string;
|
|
36
|
+
lastVerificationTime?: string;
|
|
37
|
+
verificationPhoneNumber?: string;
|
|
34
38
|
}
|
|
35
39
|
export declare namespace User {
|
|
36
40
|
function is(data: any): data is User;
|
|
37
41
|
function getIdentity(user: User, authProviderId: string): Identity | undefined;
|
|
38
42
|
function censor(user: User): User;
|
|
39
|
-
|
|
43
|
+
/**
|
|
44
|
+
* Returns the stored email or if it doesn't exist returns the primaryEmail of the first identity this user signed up with.
|
|
45
|
+
* @param user
|
|
46
|
+
* @returns A primaryEmail, or undefined if there is none.
|
|
47
|
+
*/
|
|
48
|
+
function getPrimaryEmail(user: User): string | undefined;
|
|
40
49
|
function getName(user: User): string | undefined;
|
|
50
|
+
function hasPreferredIde(user: User): boolean;
|
|
51
|
+
function isOnboardingUser(user: User): boolean;
|
|
52
|
+
function migrationIDESettings(user: User): void;
|
|
53
|
+
function getProfile(user: User): Profile;
|
|
54
|
+
function setProfile(user: User, profile: Profile): User;
|
|
55
|
+
interface Profile {
|
|
56
|
+
name: string;
|
|
57
|
+
email: string;
|
|
58
|
+
company?: string;
|
|
59
|
+
avatarURL?: string;
|
|
60
|
+
}
|
|
61
|
+
namespace Profile {
|
|
62
|
+
function hasChanges(before: Profile, after: Profile): boolean;
|
|
63
|
+
}
|
|
41
64
|
}
|
|
42
65
|
export interface AdditionalUserData {
|
|
43
66
|
platforms?: UserPlatform[];
|
|
44
67
|
emailNotificationSettings?: EmailNotificationSettings;
|
|
45
68
|
featurePreview?: boolean;
|
|
46
69
|
ideSettings?: IDESettings;
|
|
70
|
+
whatsNewSeen?: {
|
|
71
|
+
[key: string]: string;
|
|
72
|
+
};
|
|
73
|
+
oauthClientsApproved?: {
|
|
74
|
+
[key: string]: string;
|
|
75
|
+
};
|
|
76
|
+
knownGitHubOrgs?: string[];
|
|
77
|
+
dotfileRepo?: string;
|
|
78
|
+
workspaceClasses?: WorkspaceClasses;
|
|
79
|
+
profile?: ProfileDetails;
|
|
80
|
+
}
|
|
81
|
+
export declare namespace AdditionalUserData {
|
|
82
|
+
function set(user: User, partialData: Partial<AdditionalUserData>): User;
|
|
83
|
+
}
|
|
84
|
+
export interface ProfileDetails {
|
|
85
|
+
lastUpdatedDetailsNudge?: string;
|
|
86
|
+
companyName?: string;
|
|
87
|
+
emailAddress?: string;
|
|
47
88
|
}
|
|
48
89
|
export interface EmailNotificationSettings {
|
|
49
|
-
|
|
90
|
+
allowsChangelogMail?: boolean;
|
|
91
|
+
allowsDevXMail?: boolean;
|
|
92
|
+
allowsOnboardingMail?: boolean;
|
|
50
93
|
}
|
|
51
94
|
export declare type IDESettings = {
|
|
95
|
+
settingVersion?: string;
|
|
52
96
|
defaultIde?: string;
|
|
97
|
+
useDesktopIde?: boolean;
|
|
98
|
+
defaultDesktopIde?: string;
|
|
99
|
+
useLatestVersion?: boolean;
|
|
53
100
|
};
|
|
101
|
+
export interface WorkspaceClasses {
|
|
102
|
+
regular: string;
|
|
103
|
+
prebuild: string;
|
|
104
|
+
}
|
|
54
105
|
export interface UserPlatform {
|
|
55
106
|
uid: string;
|
|
56
107
|
userAgent: string;
|
|
@@ -68,44 +119,81 @@ export interface UserPlatform {
|
|
|
68
119
|
browserExtensionUninstalledSince?: string;
|
|
69
120
|
}
|
|
70
121
|
export interface UserFeatureSettings {
|
|
71
|
-
/**
|
|
72
|
-
* This field is used as marker to grant users a free trial for using private repositories,
|
|
73
|
-
* independent of any subscription or Chargebee.
|
|
74
|
-
* - it is set when the user uses their first private repo
|
|
75
|
-
* - whether the trial is expired or not is juged by the UserService
|
|
76
|
-
*/
|
|
77
|
-
privateRepoTrialStartDate?: string;
|
|
78
122
|
/**
|
|
79
123
|
* Permanent feature flags are added to each and every workspace instance
|
|
80
124
|
* this user starts.
|
|
81
125
|
*/
|
|
82
126
|
permanentWSFeatureFlags?: NamedWorkspaceFeatureFlag[];
|
|
83
127
|
}
|
|
128
|
+
export declare type BillingTier = "paid" | "free";
|
|
84
129
|
/**
|
|
85
130
|
* The values of this type MUST MATCH enum values in WorkspaceFeatureFlag from ws-manager/client/core_pb.d.ts
|
|
86
131
|
* If they don't we'll break things during workspace startup.
|
|
87
132
|
*/
|
|
88
133
|
export declare const WorkspaceFeatureFlags: {
|
|
89
|
-
registry_facade: undefined;
|
|
90
134
|
full_workspace_backup: undefined;
|
|
91
|
-
|
|
92
|
-
|
|
135
|
+
persistent_volume_claim: undefined;
|
|
136
|
+
workspace_class_limiting: undefined;
|
|
137
|
+
workspace_connection_limiting: undefined;
|
|
138
|
+
workspace_psi: undefined;
|
|
93
139
|
};
|
|
94
|
-
export declare type NamedWorkspaceFeatureFlag = keyof
|
|
95
|
-
export
|
|
96
|
-
|
|
140
|
+
export declare type NamedWorkspaceFeatureFlag = keyof typeof WorkspaceFeatureFlags;
|
|
141
|
+
export declare namespace NamedWorkspaceFeatureFlag {
|
|
142
|
+
const WORKSPACE_PERSISTED_FEATTURE_FLAGS: NamedWorkspaceFeatureFlag[];
|
|
143
|
+
function isWorkspacePersisted(ff: NamedWorkspaceFeatureFlag): boolean;
|
|
144
|
+
}
|
|
145
|
+
export interface EnvVarWithValue {
|
|
97
146
|
name: string;
|
|
98
|
-
repositoryPattern: string;
|
|
99
147
|
value: string;
|
|
100
148
|
}
|
|
149
|
+
export interface ProjectEnvVarWithValue extends EnvVarWithValue {
|
|
150
|
+
id: string;
|
|
151
|
+
projectId: string;
|
|
152
|
+
censored: boolean;
|
|
153
|
+
}
|
|
154
|
+
export declare type ProjectEnvVar = Omit<ProjectEnvVarWithValue, "value">;
|
|
155
|
+
export interface UserEnvVarValue extends EnvVarWithValue {
|
|
156
|
+
id?: string;
|
|
157
|
+
repositoryPattern: string;
|
|
158
|
+
}
|
|
101
159
|
export interface UserEnvVar extends UserEnvVarValue {
|
|
102
160
|
id: string;
|
|
103
161
|
userId: string;
|
|
104
162
|
deleted?: boolean;
|
|
105
163
|
}
|
|
106
164
|
export declare namespace UserEnvVar {
|
|
165
|
+
/**
|
|
166
|
+
* @param variable
|
|
167
|
+
* @returns Either a string containing an error message or undefined.
|
|
168
|
+
*/
|
|
169
|
+
function validate(variable: UserEnvVarValue): string | undefined;
|
|
107
170
|
function normalizeRepoPattern(pattern: string): string;
|
|
171
|
+
function score(value: UserEnvVarValue): number;
|
|
108
172
|
function filter<T extends UserEnvVarValue>(vars: T[], owner: string, repo: string): T[];
|
|
173
|
+
function splitRepositoryPattern(repositoryPattern: string): string[];
|
|
174
|
+
}
|
|
175
|
+
export interface SSHPublicKeyValue {
|
|
176
|
+
name: string;
|
|
177
|
+
key: string;
|
|
178
|
+
}
|
|
179
|
+
export interface UserSSHPublicKey extends SSHPublicKeyValue {
|
|
180
|
+
id: string;
|
|
181
|
+
key: string;
|
|
182
|
+
userId: string;
|
|
183
|
+
fingerprint: string;
|
|
184
|
+
creationTime: string;
|
|
185
|
+
lastUsedTime?: string;
|
|
186
|
+
}
|
|
187
|
+
export declare type UserSSHPublicKeyValue = Omit<UserSSHPublicKey, "key" | "userId">;
|
|
188
|
+
export declare namespace SSHPublicKeyValue {
|
|
189
|
+
function validate(value: SSHPublicKeyValue): string | undefined;
|
|
190
|
+
function getData(value: SSHPublicKeyValue): {
|
|
191
|
+
type: string;
|
|
192
|
+
key: string;
|
|
193
|
+
email: string | undefined;
|
|
194
|
+
};
|
|
195
|
+
function getFingerprint(value: SSHPublicKeyValue): string;
|
|
196
|
+
const MAXIMUM_KEY_LENGTH = 5;
|
|
109
197
|
}
|
|
110
198
|
export interface GitpodToken {
|
|
111
199
|
/** Hash value (SHA256) of the token (primary key). */
|
|
@@ -198,25 +286,31 @@ export interface PendingGithubEvent {
|
|
|
198
286
|
creationDate: Date;
|
|
199
287
|
type: string;
|
|
200
288
|
event: string;
|
|
289
|
+
deleted: boolean;
|
|
201
290
|
}
|
|
202
291
|
export interface Snapshot {
|
|
203
292
|
id: string;
|
|
204
293
|
creationTime: string;
|
|
294
|
+
availableTime?: string;
|
|
205
295
|
originalWorkspaceId: string;
|
|
206
296
|
bucketId: string;
|
|
207
|
-
|
|
297
|
+
state: SnapshotState;
|
|
298
|
+
message?: string;
|
|
208
299
|
}
|
|
209
|
-
export interface
|
|
300
|
+
export interface VolumeSnapshot {
|
|
301
|
+
id: string;
|
|
210
302
|
workspaceId: string;
|
|
211
|
-
|
|
212
|
-
|
|
303
|
+
creationTime: string;
|
|
304
|
+
volumeHandle: string;
|
|
213
305
|
}
|
|
306
|
+
export declare type SnapshotState = "pending" | "available" | "error";
|
|
214
307
|
export interface Workspace {
|
|
215
308
|
id: string;
|
|
216
309
|
creationTime: string;
|
|
217
310
|
contextURL: string;
|
|
218
311
|
description: string;
|
|
219
312
|
ownerId: string;
|
|
313
|
+
projectId?: string;
|
|
220
314
|
context: WorkspaceContext;
|
|
221
315
|
config: WorkspaceConfig;
|
|
222
316
|
/**
|
|
@@ -257,7 +351,7 @@ export interface Workspace {
|
|
|
257
351
|
basedOnSnapshotId?: string;
|
|
258
352
|
}
|
|
259
353
|
export declare type WorkspaceSoftDeletion = "user" | "gc";
|
|
260
|
-
export declare type WorkspaceType = "regular" | "prebuild"
|
|
354
|
+
export declare type WorkspaceType = "regular" | "prebuild";
|
|
261
355
|
export declare namespace Workspace {
|
|
262
356
|
function getFullRepositoryName(ws: Workspace): string | undefined;
|
|
263
357
|
function getFullRepositoryUrl(ws: Workspace): string | undefined;
|
|
@@ -266,33 +360,51 @@ export declare namespace Workspace {
|
|
|
266
360
|
function getBranchName(ws: Workspace): string | undefined;
|
|
267
361
|
function getCommit(ws: Workspace): string | undefined;
|
|
268
362
|
}
|
|
269
|
-
export interface
|
|
270
|
-
|
|
363
|
+
export interface GuessGitTokenScopesParams {
|
|
364
|
+
host: string;
|
|
365
|
+
repoUrl: string;
|
|
366
|
+
gitCommand: string;
|
|
367
|
+
currentToken: GitToken;
|
|
368
|
+
}
|
|
369
|
+
export interface GitToken {
|
|
370
|
+
token: string;
|
|
371
|
+
user: string;
|
|
372
|
+
scopes: string[];
|
|
373
|
+
}
|
|
374
|
+
export interface GuessedGitTokenScopes {
|
|
375
|
+
message?: string;
|
|
376
|
+
scopes?: string[];
|
|
271
377
|
}
|
|
272
|
-
export interface
|
|
273
|
-
|
|
274
|
-
builtins?: ResolvedPlugins;
|
|
275
|
-
vsxRegistryUrl?: string;
|
|
378
|
+
export interface VSCodeConfig {
|
|
379
|
+
extensions?: string[];
|
|
276
380
|
}
|
|
277
|
-
export interface
|
|
278
|
-
|
|
381
|
+
export interface JetBrainsConfig {
|
|
382
|
+
intellij?: JetBrainsProductConfig;
|
|
383
|
+
goland?: JetBrainsProductConfig;
|
|
384
|
+
pycharm?: JetBrainsProductConfig;
|
|
385
|
+
phpstorm?: JetBrainsProductConfig;
|
|
386
|
+
rubymine?: JetBrainsProductConfig;
|
|
387
|
+
webstorm?: JetBrainsProductConfig;
|
|
279
388
|
}
|
|
280
|
-
export interface
|
|
281
|
-
|
|
389
|
+
export interface JetBrainsProductConfig {
|
|
390
|
+
prebuilds?: JetBrainsPrebuilds;
|
|
391
|
+
vmoptions?: string;
|
|
282
392
|
}
|
|
283
|
-
export
|
|
284
|
-
|
|
285
|
-
[pluginId: string]: ResolvedPlugin | undefined;
|
|
393
|
+
export interface JetBrainsPrebuilds {
|
|
394
|
+
version?: "stable" | "latest" | "both";
|
|
286
395
|
}
|
|
287
|
-
export interface
|
|
288
|
-
fullPluginName: string;
|
|
396
|
+
export interface RepositoryCloneInformation {
|
|
289
397
|
url: string;
|
|
290
|
-
|
|
398
|
+
checkoutLocation?: string;
|
|
291
399
|
}
|
|
292
|
-
export interface
|
|
293
|
-
|
|
400
|
+
export interface CoreDumpConfig {
|
|
401
|
+
enabled?: boolean;
|
|
402
|
+
softLimit?: number;
|
|
403
|
+
hardLimit?: number;
|
|
294
404
|
}
|
|
295
405
|
export interface WorkspaceConfig {
|
|
406
|
+
mainConfiguration?: string;
|
|
407
|
+
additionalRepositories?: RepositoryCloneInformation[];
|
|
296
408
|
image?: ImageConfig;
|
|
297
409
|
ports?: PortConfig[];
|
|
298
410
|
tasks?: TaskConfig[];
|
|
@@ -303,15 +415,20 @@ export interface WorkspaceConfig {
|
|
|
303
415
|
};
|
|
304
416
|
github?: GithubAppConfig;
|
|
305
417
|
vscode?: VSCodeConfig;
|
|
418
|
+
jetbrains?: JetBrainsConfig;
|
|
419
|
+
coreDump?: CoreDumpConfig;
|
|
420
|
+
/** deprecated. Enabled by default **/
|
|
421
|
+
experimentalNetwork?: boolean;
|
|
306
422
|
/**
|
|
307
423
|
* Where the config object originates from.
|
|
308
424
|
*
|
|
309
425
|
* repo - from the repository
|
|
310
426
|
* definitly-gp - from github.com/gitpod-io/definitely-gp
|
|
311
427
|
* derived - computed based on analyzing the repository
|
|
428
|
+
* additional-content - config comes from additional content, usually provided through the project's configuration
|
|
312
429
|
* default - our static catch-all default config
|
|
313
430
|
*/
|
|
314
|
-
_origin?:
|
|
431
|
+
_origin?: "repo" | "definitely-gp" | "derived" | "additional-content" | "default";
|
|
315
432
|
/**
|
|
316
433
|
* Set of automatically infered feature flags. That's not something the user can set, but
|
|
317
434
|
* that is set by gitpod at workspace creation time.
|
|
@@ -326,7 +443,7 @@ export interface GithubAppPrebuildConfig {
|
|
|
326
443
|
branches?: boolean;
|
|
327
444
|
pullRequests?: boolean;
|
|
328
445
|
pullRequestsFromForks?: boolean;
|
|
329
|
-
addCheck?: boolean;
|
|
446
|
+
addCheck?: boolean | "prevent-merge-on-error";
|
|
330
447
|
addBadge?: boolean;
|
|
331
448
|
addLabel?: boolean | string;
|
|
332
449
|
addComment?: boolean;
|
|
@@ -336,9 +453,9 @@ export declare namespace GithubAppPrebuildConfig {
|
|
|
336
453
|
}
|
|
337
454
|
export declare type WorkspaceImageSource = WorkspaceImageSourceDocker | WorkspaceImageSourceReference;
|
|
338
455
|
export interface WorkspaceImageSourceDocker {
|
|
339
|
-
dockerFileHash: string;
|
|
340
|
-
dockerFileSource: Commit;
|
|
341
456
|
dockerFilePath: string;
|
|
457
|
+
dockerFileHash: string;
|
|
458
|
+
dockerFileSource?: Commit;
|
|
342
459
|
}
|
|
343
460
|
export declare namespace WorkspaceImageSourceDocker {
|
|
344
461
|
function is(obj: object): obj is WorkspaceImageSourceDocker;
|
|
@@ -350,14 +467,17 @@ export interface WorkspaceImageSourceReference {
|
|
|
350
467
|
export declare namespace WorkspaceImageSourceReference {
|
|
351
468
|
function is(obj: object): obj is WorkspaceImageSourceReference;
|
|
352
469
|
}
|
|
353
|
-
export declare type PrebuiltWorkspaceState = "queued" | "building" | "aborted" | "timeout" | "available";
|
|
470
|
+
export declare type PrebuiltWorkspaceState = "queued" | "building" | "aborted" | "timeout" | "available" | "failed";
|
|
354
471
|
export interface PrebuiltWorkspace {
|
|
355
472
|
id: string;
|
|
356
473
|
cloneURL: string;
|
|
474
|
+
branch?: string;
|
|
475
|
+
projectId?: string;
|
|
357
476
|
commit: string;
|
|
358
477
|
buildWorkspaceId: string;
|
|
359
478
|
creationTime: string;
|
|
360
479
|
state: PrebuiltWorkspaceState;
|
|
480
|
+
statusVersion: number;
|
|
361
481
|
error?: string;
|
|
362
482
|
snapshot?: string;
|
|
363
483
|
}
|
|
@@ -373,6 +493,10 @@ export interface PrebuiltWorkspaceUpdatable {
|
|
|
373
493
|
repo: string;
|
|
374
494
|
isResolved: boolean;
|
|
375
495
|
installationId: string;
|
|
496
|
+
/**
|
|
497
|
+
* the commitSHA of the commit that triggered the prebuild
|
|
498
|
+
*/
|
|
499
|
+
commitSHA?: string;
|
|
376
500
|
issue?: string;
|
|
377
501
|
contextUrl?: string;
|
|
378
502
|
}
|
|
@@ -382,11 +506,13 @@ export interface WhitelistedRepository {
|
|
|
382
506
|
description?: string;
|
|
383
507
|
avatar?: string;
|
|
384
508
|
}
|
|
385
|
-
export declare type PortOnOpen =
|
|
509
|
+
export declare type PortOnOpen = "open-browser" | "open-preview" | "notify" | "ignore";
|
|
386
510
|
export interface PortConfig {
|
|
387
511
|
port: number;
|
|
388
512
|
onOpen?: PortOnOpen;
|
|
389
513
|
visibility?: PortVisibility;
|
|
514
|
+
description?: string;
|
|
515
|
+
name?: string;
|
|
390
516
|
}
|
|
391
517
|
export declare namespace PortConfig {
|
|
392
518
|
function is(config: any): config is PortConfig;
|
|
@@ -405,16 +531,16 @@ export interface TaskConfig {
|
|
|
405
531
|
prebuild?: string;
|
|
406
532
|
command?: string;
|
|
407
533
|
env?: {
|
|
408
|
-
[env: string]:
|
|
534
|
+
[env: string]: any;
|
|
409
535
|
};
|
|
410
|
-
openIn?:
|
|
411
|
-
openMode?:
|
|
536
|
+
openIn?: "bottom" | "main" | "left" | "right";
|
|
537
|
+
openMode?: "split-top" | "split-left" | "split-right" | "split-bottom" | "tab-before" | "tab-after";
|
|
412
538
|
}
|
|
413
539
|
export declare namespace TaskConfig {
|
|
414
540
|
function is(config: any): config is TaskConfig;
|
|
415
541
|
}
|
|
416
542
|
export declare namespace WorkspaceImageBuild {
|
|
417
|
-
type Phase =
|
|
543
|
+
type Phase = "BaseImage" | "GitpodLayer" | "Error" | "Done";
|
|
418
544
|
interface StateInfo {
|
|
419
545
|
phase: Phase;
|
|
420
546
|
currentStep?: number;
|
|
@@ -451,8 +577,11 @@ export declare namespace ExternalImageConfigFile {
|
|
|
451
577
|
}
|
|
452
578
|
export interface WorkspaceContext {
|
|
453
579
|
title: string;
|
|
580
|
+
ref?: string;
|
|
581
|
+
/** This contains the URL portion of the contextURL (which might contain other modifiers as well). It's optional because it's not set for older workspaces. */
|
|
454
582
|
normalizedContextURL?: string;
|
|
455
583
|
forceCreateNewWorkspace?: boolean;
|
|
584
|
+
forceImageBuild?: boolean;
|
|
456
585
|
}
|
|
457
586
|
export declare namespace WorkspaceContext {
|
|
458
587
|
function is(context: any): context is WorkspaceContext;
|
|
@@ -463,14 +592,24 @@ export interface WithSnapshot {
|
|
|
463
592
|
export declare namespace WithSnapshot {
|
|
464
593
|
function is(context: any): context is WithSnapshot;
|
|
465
594
|
}
|
|
466
|
-
export interface WithPrebuild {
|
|
467
|
-
snapshotBucketId: string;
|
|
595
|
+
export interface WithPrebuild extends WithSnapshot {
|
|
468
596
|
prebuildWorkspaceId: string;
|
|
469
597
|
wasPrebuilt: true;
|
|
470
598
|
}
|
|
471
599
|
export declare namespace WithPrebuild {
|
|
472
600
|
function is(context: any): context is WithPrebuild;
|
|
473
601
|
}
|
|
602
|
+
/**
|
|
603
|
+
* WithDefaultConfig contexts disable the download of the gitpod.yml from the repository
|
|
604
|
+
* and fall back to the built-in configuration.
|
|
605
|
+
*/
|
|
606
|
+
export interface WithDefaultConfig {
|
|
607
|
+
withDefaultConfig: true;
|
|
608
|
+
}
|
|
609
|
+
export declare namespace WithDefaultConfig {
|
|
610
|
+
function is(context: any): context is WithDefaultConfig;
|
|
611
|
+
function mark(ctx: WorkspaceContext): WorkspaceContext & WithDefaultConfig;
|
|
612
|
+
}
|
|
474
613
|
export interface SnapshotContext extends WorkspaceContext, WithSnapshot {
|
|
475
614
|
snapshotId: string;
|
|
476
615
|
}
|
|
@@ -479,6 +618,13 @@ export declare namespace SnapshotContext {
|
|
|
479
618
|
}
|
|
480
619
|
export interface StartPrebuildContext extends WorkspaceContext {
|
|
481
620
|
actual: WorkspaceContext;
|
|
621
|
+
commitHistory?: string[];
|
|
622
|
+
additionalRepositoryCommitHistories?: {
|
|
623
|
+
cloneUrl: string;
|
|
624
|
+
commitHistory: string[];
|
|
625
|
+
}[];
|
|
626
|
+
project?: Project;
|
|
627
|
+
branch?: string;
|
|
482
628
|
}
|
|
483
629
|
export declare namespace StartPrebuildContext {
|
|
484
630
|
function is(context: any): context is StartPrebuildContext;
|
|
@@ -491,19 +637,19 @@ export interface PrebuiltWorkspaceContext extends WorkspaceContext {
|
|
|
491
637
|
export declare namespace PrebuiltWorkspaceContext {
|
|
492
638
|
function is(context: any): context is PrebuiltWorkspaceContext;
|
|
493
639
|
}
|
|
640
|
+
export interface WithReferrerContext extends WorkspaceContext {
|
|
641
|
+
referrer: string;
|
|
642
|
+
referrerIde?: string;
|
|
643
|
+
}
|
|
644
|
+
export declare namespace WithReferrerContext {
|
|
645
|
+
function is(context: any): context is WithReferrerContext;
|
|
646
|
+
}
|
|
494
647
|
export interface WithEnvvarsContext extends WorkspaceContext {
|
|
495
|
-
envvars:
|
|
648
|
+
envvars: EnvVarWithValue[];
|
|
496
649
|
}
|
|
497
650
|
export declare namespace WithEnvvarsContext {
|
|
498
651
|
function is(context: any): context is WithEnvvarsContext;
|
|
499
652
|
}
|
|
500
|
-
export interface WorkspaceProbeContext extends WorkspaceContext {
|
|
501
|
-
responseURL: string;
|
|
502
|
-
responseToken: string;
|
|
503
|
-
}
|
|
504
|
-
export declare namespace WorkspaceProbeContext {
|
|
505
|
-
function is(context: any): context is WorkspaceProbeContext;
|
|
506
|
-
}
|
|
507
653
|
export declare type RefType = "branch" | "tag" | "revision";
|
|
508
654
|
export declare namespace RefType {
|
|
509
655
|
const getRefType: (commit: Commit) => RefType;
|
|
@@ -514,9 +660,45 @@ export interface Commit {
|
|
|
514
660
|
ref?: string;
|
|
515
661
|
refType?: RefType;
|
|
516
662
|
}
|
|
517
|
-
export interface
|
|
663
|
+
export interface AdditionalContentContext extends WorkspaceContext {
|
|
664
|
+
/**
|
|
665
|
+
* utf-8 encoded contents that will be copied on top of the workspace's filesystem
|
|
666
|
+
*/
|
|
667
|
+
additionalFiles: {
|
|
668
|
+
[filePath: string]: string;
|
|
669
|
+
};
|
|
670
|
+
}
|
|
671
|
+
export declare namespace AdditionalContentContext {
|
|
672
|
+
function is(ctx: any): ctx is AdditionalContentContext;
|
|
673
|
+
function hasDockerConfig(ctx: any, config: WorkspaceConfig): boolean;
|
|
674
|
+
}
|
|
675
|
+
export interface OpenPrebuildContext extends WorkspaceContext {
|
|
676
|
+
openPrebuildID: string;
|
|
677
|
+
}
|
|
678
|
+
export declare namespace OpenPrebuildContext {
|
|
679
|
+
function is(ctx: any): ctx is OpenPrebuildContext;
|
|
680
|
+
}
|
|
681
|
+
export interface CommitContext extends WorkspaceContext, GitCheckoutInfo {
|
|
518
682
|
/** @deprecated Moved to .repository.cloneUrl, left here for backwards-compatibility for old workspace contextes in the DB */
|
|
519
683
|
cloneUrl?: string;
|
|
684
|
+
/**
|
|
685
|
+
* The clone and checkout information for additional repositories in case of multi-repo projects.
|
|
686
|
+
*/
|
|
687
|
+
additionalRepositoryCheckoutInfo?: GitCheckoutInfo[];
|
|
688
|
+
}
|
|
689
|
+
export declare namespace CommitContext {
|
|
690
|
+
/**
|
|
691
|
+
* Creates a hash for all the commits of the CommitContext and all sub-repo commit infos.
|
|
692
|
+
* The hash is max 255 chars long.
|
|
693
|
+
* @param commitContext
|
|
694
|
+
* @returns hash for commitcontext
|
|
695
|
+
*/
|
|
696
|
+
function computeHash(commitContext: CommitContext): string;
|
|
697
|
+
}
|
|
698
|
+
export interface GitCheckoutInfo extends Commit {
|
|
699
|
+
checkoutLocation?: string;
|
|
700
|
+
upstreamRemoteURI?: string;
|
|
701
|
+
localBranch?: string;
|
|
520
702
|
}
|
|
521
703
|
export declare namespace CommitContext {
|
|
522
704
|
function is(commit: any): commit is CommitContext;
|
|
@@ -552,6 +734,7 @@ export interface Repository {
|
|
|
552
734
|
owner: string;
|
|
553
735
|
name: string;
|
|
554
736
|
cloneUrl: string;
|
|
737
|
+
repoKind?: string;
|
|
555
738
|
description?: string;
|
|
556
739
|
avatarUrl?: string;
|
|
557
740
|
webUrl?: string;
|
|
@@ -562,6 +745,18 @@ export interface Repository {
|
|
|
562
745
|
parent: Repository;
|
|
563
746
|
};
|
|
564
747
|
}
|
|
748
|
+
export interface Branch {
|
|
749
|
+
name: string;
|
|
750
|
+
commit: CommitInfo;
|
|
751
|
+
htmlUrl: string;
|
|
752
|
+
}
|
|
753
|
+
export interface CommitInfo {
|
|
754
|
+
author: string;
|
|
755
|
+
sha: string;
|
|
756
|
+
commitMessage: string;
|
|
757
|
+
authorAvatarUrl?: string;
|
|
758
|
+
authorDate?: string;
|
|
759
|
+
}
|
|
565
760
|
export declare namespace Repository {
|
|
566
761
|
function fullRepoName(repo: Repository): string;
|
|
567
762
|
}
|
|
@@ -578,6 +773,9 @@ export interface WorkspaceInfo {
|
|
|
578
773
|
workspace: Workspace;
|
|
579
774
|
latestInstance?: WorkspaceInstance;
|
|
580
775
|
}
|
|
776
|
+
export declare namespace WorkspaceInfo {
|
|
777
|
+
function lastActiveISODate(info: WorkspaceInfo): string;
|
|
778
|
+
}
|
|
581
779
|
export declare type RunningWorkspaceInfo = WorkspaceInfo & {
|
|
582
780
|
latestInstance: WorkspaceInstance;
|
|
583
781
|
};
|
|
@@ -588,12 +786,13 @@ export interface WorkspaceCreationResult {
|
|
|
588
786
|
runningWorkspacePrebuild?: {
|
|
589
787
|
prebuildID: string;
|
|
590
788
|
workspaceID: string;
|
|
789
|
+
instanceID: string;
|
|
591
790
|
starting: RunningWorkspacePrebuildStarting;
|
|
592
791
|
sameCluster: boolean;
|
|
593
792
|
};
|
|
594
793
|
runningPrebuildWorkspaceID?: string;
|
|
595
794
|
}
|
|
596
|
-
export declare type RunningWorkspacePrebuildStarting =
|
|
795
|
+
export declare type RunningWorkspacePrebuildStarting = "queued" | "starting" | "running";
|
|
597
796
|
export declare enum CreateWorkspaceMode {
|
|
598
797
|
Default = "default",
|
|
599
798
|
ForceNew = "force-new",
|
|
@@ -640,6 +839,8 @@ export interface AuthProviderEntry {
|
|
|
640
839
|
readonly ownerId: string;
|
|
641
840
|
readonly status: AuthProviderEntry.Status;
|
|
642
841
|
readonly oauth: OAuth2Config;
|
|
842
|
+
/** A random string that is to change whenever oauth changes (enforced on DB level) */
|
|
843
|
+
readonly oauthRevision?: string;
|
|
643
844
|
}
|
|
644
845
|
export interface OAuth2Config {
|
|
645
846
|
readonly clientId: string;
|
|
@@ -658,40 +859,12 @@ export interface OAuth2Config {
|
|
|
658
859
|
export declare namespace AuthProviderEntry {
|
|
659
860
|
type Type = "GitHub" | "GitLab" | string;
|
|
660
861
|
type Status = "pending" | "verified";
|
|
661
|
-
type NewEntry = Pick<AuthProviderEntry, "ownerId" | "host" | "type"
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
export interface Branding {
|
|
665
|
-
readonly name: string;
|
|
666
|
-
readonly favicon?: string;
|
|
667
|
-
/** Either including domain OR absolute path (interpreted relative to host URL) */
|
|
668
|
-
readonly logo: string;
|
|
669
|
-
readonly startupLogo: string;
|
|
670
|
-
readonly showProductivityTips: boolean;
|
|
671
|
-
readonly redirectUrlIfNotAuthenticated?: string;
|
|
672
|
-
readonly redirectUrlAfterLogout?: string;
|
|
673
|
-
readonly homepage: string;
|
|
674
|
-
readonly ide?: {
|
|
675
|
-
readonly logo: string;
|
|
676
|
-
readonly showReleaseNotes: boolean;
|
|
677
|
-
readonly helpMenu: Branding.Link[];
|
|
862
|
+
type NewEntry = Pick<AuthProviderEntry, "ownerId" | "host" | "type"> & {
|
|
863
|
+
clientId?: string;
|
|
864
|
+
clientSecret?: string;
|
|
678
865
|
};
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
readonly footer: Branding.Link[];
|
|
682
|
-
readonly social: Branding.SocialLink[];
|
|
683
|
-
readonly legal: Branding.Link[];
|
|
684
|
-
};
|
|
685
|
-
}
|
|
686
|
-
export declare namespace Branding {
|
|
687
|
-
interface Link {
|
|
688
|
-
readonly name: string;
|
|
689
|
-
readonly url: string;
|
|
690
|
-
}
|
|
691
|
-
interface SocialLink {
|
|
692
|
-
readonly type: string;
|
|
693
|
-
readonly url: string;
|
|
694
|
-
}
|
|
866
|
+
type UpdateEntry = Pick<AuthProviderEntry, "id" | "ownerId"> & Pick<OAuth2Config, "clientId" | "clientSecret">;
|
|
867
|
+
function redact(entry: AuthProviderEntry): AuthProviderEntry;
|
|
695
868
|
}
|
|
696
869
|
export interface Configuration {
|
|
697
870
|
readonly daysBeforeGarbageCollection: number;
|
|
@@ -730,4 +903,21 @@ export interface Terms {
|
|
|
730
903
|
readonly content: string;
|
|
731
904
|
readonly formElements?: object;
|
|
732
905
|
}
|
|
906
|
+
export interface StripeConfig {
|
|
907
|
+
individualUsagePriceIds: {
|
|
908
|
+
[currency: string]: string;
|
|
909
|
+
};
|
|
910
|
+
teamUsagePriceIds: {
|
|
911
|
+
[currency: string]: string;
|
|
912
|
+
};
|
|
913
|
+
}
|
|
914
|
+
export declare type BillingStrategy = "other" | "stripe";
|
|
915
|
+
export interface CostCenter {
|
|
916
|
+
readonly id: AttributionId;
|
|
917
|
+
/**
|
|
918
|
+
* Unit: credits
|
|
919
|
+
*/
|
|
920
|
+
spendingLimit: number;
|
|
921
|
+
billingStrategy: BillingStrategy;
|
|
922
|
+
}
|
|
733
923
|
//# sourceMappingURL=protocol.d.ts.map
|