@zackbart/connecta 0.34.1 → 0.35.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/CHANGELOG.md +363 -0
- package/README.md +62 -106
- package/SECURITY.md +3 -2
- package/bin/connecta.mjs +41 -16
- package/bin/version.mjs +1 -1
- package/dist/access-tokens.d.ts +2 -1
- package/dist/access-tokens.js +66 -30
- package/dist/activity.d.ts +1 -1
- package/dist/activity.js +2 -0
- package/dist/agent-config.d.ts +23 -0
- package/dist/agent-config.js +59 -0
- package/dist/agent-description.js +16 -0
- package/dist/agent-identity.js +4 -4
- package/dist/agent-observation.js +39 -0
- package/dist/auth/clerk-sdk/client.d.ts +2 -0
- package/dist/auth/clerk-sdk/generated.js +554 -563
- package/dist/auth/clerk-transport.js +70 -3
- package/dist/auth/clerk.d.ts +13 -0
- package/dist/auth/clerk.js +653 -246
- package/dist/auth/cloudflare-access.js +46 -42
- package/dist/auth/downstream-client-metadata.js +2 -2
- package/dist/auth/downstream-oauth.js +2051 -1160
- package/dist/auth/downstream-revocation.js +88 -88
- package/dist/auth/native-call.js +20 -0
- package/dist/auth/native.js +184 -0
- package/dist/auth/oauth-start-reset.js +11 -5
- package/dist/auth/oauth-token-response.js +121 -102
- package/dist/auth/oauth-v2-migration.js +97 -78
- package/dist/auth/renewable-grant.js +10 -0
- package/dist/auth/static-oauth.js +663 -271
- package/dist/auth/vercel-agent.js +266 -0
- package/dist/auth-admission.js +204 -0
- package/dist/auth-elicitation.js +350 -241
- package/dist/authorization-handoff.js +164 -90
- package/dist/call-admission-context.js +3 -10
- package/dist/call-admission.js +2 -0
- package/dist/call-classification.js +9 -0
- package/dist/call-recovery.js +32 -13
- package/dist/canonical-json.js +8 -0
- package/dist/catalog-cache.js +369 -213
- package/dist/catalog-service.js +659 -530
- package/dist/catalog.js +5 -1
- package/dist/concurrency.js +0 -25
- package/dist/config-defaults.d.ts +1 -0
- package/dist/config-defaults.js +1 -0
- package/dist/config-schema.d.ts +3 -1
- package/dist/config-schema.js +13 -3
- package/dist/config.d.ts +40 -6
- package/dist/config.js +40 -26
- package/dist/connector-caller.d.ts +4 -0
- package/dist/connector-caller.js +17 -4
- package/dist/connectors/api-connector.d.ts +12 -7
- package/dist/connectors/api-connector.js +142 -56
- package/dist/connectors/guarded-fetch.d.ts +51 -17
- package/dist/connectors/guarded-fetch.js +215 -121
- package/dist/connectors/negotiation-cache.js +20 -10
- package/dist/connectors/remote-mcp.d.ts +10 -30
- package/dist/connectors/remote-mcp.js +955 -563
- package/dist/d1.js +10 -243
- package/dist/derived-context.js +5 -0
- package/dist/describe-config.d.ts +3 -1
- package/dist/describe-config.js +2 -0
- package/dist/downstream-input.js +347 -260
- package/dist/errors.d.ts +87 -6
- package/dist/errors.js +114 -4
- package/dist/execute.js +87 -50
- package/dist/executor-admission.js +3 -0
- package/dist/executors/quickjs.js +163 -112
- package/dist/guarded-transport.js +50 -0
- package/dist/guest-runtime.js +1 -1
- package/dist/http/client.js +439 -0
- package/dist/http/errors.js +558 -0
- package/dist/http/fields.js +49 -0
- package/dist/http/hatch-paging.js +318 -0
- package/dist/http/hatch.js +1279 -0
- package/dist/http/json-schema.js +267 -0
- package/dist/http/node-transport.js +241 -0
- package/dist/http/oauth.js +162 -0
- package/dist/http/paging.js +228 -0
- package/dist/http/provider.js +221 -0
- package/dist/http/safety.js +82 -0
- package/dist/http/services.js +79 -0
- package/dist/http/tools.js +383 -0
- package/dist/http/vendor-index.js +138 -0
- package/dist/http/vendor.js +448 -0
- package/dist/http/write-request.js +66 -0
- package/dist/http-policy.d.ts +11 -0
- package/dist/http-policy.js +45 -0
- package/dist/inbound-credential.js +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js +4 -0
- package/dist/invocation-auth.js +30 -19
- package/dist/invocation.js +218 -85
- package/dist/mcp-result.js +0 -4
- package/dist/membership.d.ts +4 -0
- package/dist/meta-output.js +1 -1
- package/dist/meta-tools.js +531 -406
- package/dist/native-recovery.js +52 -0
- package/dist/native-tools.js +382 -0
- package/dist/node.d.ts +4 -3
- package/dist/node.js +45 -8
- package/dist/oauth-handoff.js +177 -104
- package/dist/oauth-partition.js +6 -20
- package/dist/oauth-sealing.js +6 -7
- package/dist/operation-vocabulary.js +101 -0
- package/dist/operator-record.d.ts +2 -2
- package/dist/operator-record.js +17 -4
- package/dist/operator-ui/agents.d.ts +5 -4
- package/dist/operator-ui/agents.js +17 -7
- package/dist/operator-ui/config-summary.js +5 -4
- package/dist/operator-ui/connection-map.js +7 -5
- package/dist/operator-ui/contract.d.ts +7 -3
- package/dist/operator-ui/endpoints.js +4 -13
- package/dist/operator-ui/fix-prompts.d.ts +1 -1
- package/dist/operator-ui/fix-prompts.js +0 -8
- package/dist/operator-ui/generated.js +3 -3
- package/dist/operator-ui/model.d.ts +2 -3
- package/dist/operator-ui/overview.js +5 -2
- package/dist/operator-ui/setup-commands.js +0 -4
- package/dist/operator-ui/view.d.ts +2 -25
- package/dist/operator-ui/view.js +2 -76
- package/dist/program-writes.js +47 -26
- package/dist/provider-call-facts.d.ts +115 -0
- package/dist/provider-call-facts.js +182 -0
- package/dist/provider-call.d.ts +112 -0
- package/dist/provider-call.js +271 -0
- package/dist/provider.d.ts +65 -31
- package/dist/provider.js +116 -39
- package/dist/providers/_shared/google/hatch.js +91 -0
- package/dist/providers/_shared/google/kit.js +537 -0
- package/dist/providers/_shared/google/result-size.js +15 -2
- package/dist/providers/_shared/google/service-account.d.ts +2 -1
- package/dist/providers/_shared/google/service-account.js +8 -4
- package/dist/providers/_shared/google/workspace.d.ts +6 -210
- package/dist/providers/_shared/google/workspace.js +6 -425
- package/dist/providers/_shared/rest/compact-index.js +86 -0
- package/dist/providers/_shared/rest/dispatch.js +3 -23
- package/dist/providers/_shared/rest/kit.js +546 -0
- package/dist/providers/_shared/rest/operation-index.js +230 -14
- package/dist/providers/_shared/rest/response-media.js +11 -0
- package/dist/providers/_shared/rest/tools.js +101 -78
- package/dist/providers/_shared/rest/value-safety.js +353 -195
- package/dist/providers/_shared/sensitive-fields.js +27 -0
- package/dist/providers/breeze/api.js +584 -0
- package/dist/providers/breeze/index.d.ts +1 -3
- package/dist/providers/breeze/index.js +67 -1420
- package/dist/providers/breeze/openapi.generated.js +60 -0
- package/dist/providers/breeze/skill.generated.js +2 -6
- package/dist/providers/breeze/tools.js +696 -0
- package/dist/providers/ccb/api.js +496 -0
- package/dist/providers/ccb/index.d.ts +15 -37
- package/dist/providers/ccb/index.js +77 -1702
- package/dist/providers/ccb/lib/constants.d.ts +34 -0
- package/dist/providers/ccb/lib/constants.js +74 -0
- package/dist/providers/ccb/lib/guide.js +9 -0
- package/dist/providers/ccb/lib/verdicts.js +387 -0
- package/dist/providers/ccb/openapi.generated.js +397 -0
- package/dist/providers/ccb/safety.js +295 -0
- package/dist/providers/ccb/skill.generated.js +2 -6
- package/dist/providers/ccb/tools.js +853 -0
- package/dist/providers/cloudflare/api.js +1066 -0
- package/dist/providers/cloudflare/index.d.ts +5 -22
- package/dist/providers/cloudflare/index.js +79 -197
- package/dist/providers/cloudflare/lib/config.d.ts +16 -0
- package/dist/providers/cloudflare/lib/config.js +2 -0
- package/dist/providers/cloudflare/lib/discovery.js +29 -0
- package/dist/providers/cloudflare/{graphql.js → lib/graphql.js} +1 -1
- package/dist/providers/cloudflare/lib/hatch.js +103 -0
- package/dist/providers/cloudflare/lib/path-bounds.js +28 -0
- package/dist/providers/cloudflare/lib/response-media.js +75 -0
- package/dist/providers/cloudflare/openapi.generated.js +4 -3
- package/dist/providers/cloudflare/{value-safety.js → safety.js} +487 -0
- package/dist/providers/cloudflare/skill.generated.js +2 -10
- package/dist/providers/cloudflare/tools.js +360 -0
- package/dist/providers/docs/api.js +51 -0
- package/dist/providers/docs/index.d.ts +1 -12
- package/dist/providers/docs/index.js +53 -1165
- package/dist/providers/docs/lib/constants.d.ts +18 -0
- package/dist/providers/docs/lib/constants.js +18 -0
- package/dist/providers/docs/lib/discovery.js +26 -0
- package/dist/providers/docs/lib/requests.js +48 -0
- package/dist/providers/docs/lib/schemas.js +168 -0
- package/dist/providers/docs/openapi.generated.js +16 -0
- package/dist/providers/docs/safety.js +54 -0
- package/dist/providers/docs/skill.generated.js +2 -6
- package/dist/providers/docs/tools.js +802 -0
- package/dist/providers/drive/api.js +177 -0
- package/dist/providers/drive/index.d.ts +1 -12
- package/dist/providers/drive/index.js +38 -1448
- package/dist/providers/drive/lib/constants.d.ts +6 -0
- package/dist/providers/drive/lib/constants.js +6 -0
- package/dist/providers/drive/lib/contracts.js +532 -0
- package/dist/providers/drive/lib/hatch.js +197 -0
- package/dist/providers/drive/openapi.generated.js +77 -0
- package/dist/providers/drive/safety.js +90 -0
- package/dist/providers/drive/skill.generated.js +2 -6
- package/dist/providers/drive/tools.js +1290 -0
- package/dist/providers/forms/api.js +71 -0
- package/dist/providers/forms/index.d.ts +1 -12
- package/dist/providers/forms/index.js +49 -1145
- package/dist/providers/forms/lib/constants.d.ts +14 -0
- package/dist/providers/forms/lib/constants.js +19 -0
- package/dist/providers/forms/lib/hatch.js +72 -0
- package/dist/providers/forms/openapi.generated.js +23 -0
- package/dist/providers/forms/safety.js +34 -0
- package/dist/providers/forms/skill.generated.js +2 -8
- package/dist/providers/forms/tools.js +1024 -0
- package/dist/providers/github/api.js +150 -0
- package/dist/providers/github/index.d.ts +4 -5
- package/dist/providers/github/index.js +30 -87
- package/dist/providers/github/{auth.d.ts → lib/auth.d.ts} +5 -3
- package/dist/providers/github/{auth.js → lib/auth.js} +40 -43
- package/dist/providers/github/lib/discovery.js +132 -0
- package/dist/providers/github/lib/operations.js +58 -0
- package/dist/providers/github/{scope.d.ts → lib/scope.d.ts} +2 -0
- package/dist/providers/github/{scope.js → lib/scope.js} +25 -1
- package/dist/providers/github/openapi.generated.js +1216 -0
- package/dist/providers/github/safety.js +216 -0
- package/dist/providers/github/skill.generated.js +2 -5
- package/dist/providers/github/tools.js +506 -0
- package/dist/providers/gmail/api.js +114 -0
- package/dist/providers/gmail/index.d.ts +1 -12
- package/dist/providers/gmail/index.js +73 -1621
- package/dist/providers/gmail/lib/constants.d.ts +13 -0
- package/dist/providers/gmail/lib/constants.js +16 -0
- package/dist/providers/gmail/lib/index.js +173 -0
- package/dist/providers/gmail/lib/schemas.js +176 -0
- package/dist/providers/gmail/lib/threading.js +120 -0
- package/dist/providers/gmail/openapi.generated.js +92 -0
- package/dist/providers/gmail/safety.js +21 -0
- package/dist/providers/gmail/skill.generated.js +2 -6
- package/dist/providers/gmail/tools.js +1435 -0
- package/dist/providers/overflow/api.js +1008 -0
- package/dist/providers/overflow/index.d.ts +1 -17
- package/dist/providers/overflow/index.js +60 -1488
- package/dist/providers/overflow/skill.generated.js +2 -5
- package/dist/providers/overflow/tools.js +873 -0
- package/dist/providers/planning-center/api.js +467 -0
- package/dist/providers/planning-center/index.d.ts +4 -35
- package/dist/providers/planning-center/index.js +69 -2445
- package/dist/providers/planning-center/lib/constants.d.ts +58 -0
- package/dist/providers/planning-center/lib/constants.js +83 -0
- package/dist/providers/planning-center/lib/discovery.js +40 -0
- package/dist/providers/planning-center/lib/guide.js +39 -0
- package/dist/providers/planning-center/lib/json-api.js +83 -0
- package/dist/providers/planning-center/lib/verdicts.js +1758 -0
- package/dist/providers/planning-center/openapi.generated.js +1764 -0
- package/dist/providers/planning-center/safety.js +188 -0
- package/dist/providers/planning-center/skill.generated.js +2 -27
- package/dist/providers/planning-center/tools.js +1010 -0
- package/dist/providers/sheets/api.js +133 -0
- package/dist/providers/sheets/index.d.ts +4 -16
- package/dist/providers/sheets/index.js +61 -1172
- package/dist/providers/sheets/lib/constants.d.ts +14 -0
- package/dist/providers/sheets/lib/constants.js +14 -0
- package/dist/providers/sheets/lib/hatch.js +163 -0
- package/dist/providers/sheets/lib/requests.js +105 -0
- package/dist/providers/sheets/lib/schemas.js +138 -0
- package/dist/providers/sheets/openapi.generated.js +30 -0
- package/dist/providers/sheets/safety.js +27 -0
- package/dist/providers/sheets/skill.generated.js +2 -7
- package/dist/providers/sheets/tools.js +734 -0
- package/dist/providers/slides/api.js +147 -0
- package/dist/providers/slides/index.d.ts +2 -10
- package/dist/providers/slides/index.js +48 -2555
- package/dist/providers/slides/lib/constants.d.ts +11 -0
- package/dist/providers/slides/lib/constants.js +11 -0
- package/dist/providers/slides/lib/requests.js +60 -0
- package/dist/providers/slides/lib/schemas.js +565 -0
- package/dist/providers/slides/openapi.generated.js +18 -0
- package/dist/providers/slides/skill.generated.js +2 -6
- package/dist/providers/slides/tools.js +1968 -0
- package/dist/providers/stripe/api.js +401 -0
- package/dist/providers/stripe/index.d.ts +5 -27
- package/dist/providers/stripe/index.js +74 -210
- package/dist/providers/stripe/lib/config.d.ts +4 -0
- package/dist/providers/stripe/lib/config.js +2 -0
- package/dist/providers/stripe/openapi.generated.js +4 -3
- package/dist/providers/stripe/{value-safety.js → safety.js} +5 -5
- package/dist/providers/stripe/skill.generated.js +2 -11
- package/dist/providers/stripe/tools.js +77 -0
- package/dist/providers/tithely/api.js +531 -0
- package/dist/providers/tithely/index.d.ts +17 -0
- package/dist/providers/tithely/index.js +86 -965
- package/dist/providers/tithely/skill.generated.js +2 -5
- package/dist/providers/tithely/tools.js +426 -0
- package/dist/providers/vercel/api.js +551 -0
- package/dist/providers/vercel/index.d.ts +9 -25
- package/dist/providers/vercel/index.js +66 -260
- package/dist/providers/vercel/lib/config.d.ts +2 -0
- package/dist/providers/vercel/lib/config.js +2 -0
- package/dist/providers/vercel/lib/index.js +117 -0
- package/dist/providers/vercel/lib/logs.js +100 -0
- package/dist/providers/vercel/lib/pin.js +270 -0
- package/dist/providers/vercel/openapi.generated.js +10 -5
- package/dist/providers/vercel/{value-safety.js → safety.js} +247 -38
- package/dist/providers/vercel/skill.generated.js +2 -7
- package/dist/providers/vercel/tools.js +642 -0
- package/dist/redaction-identity.js +47 -0
- package/dist/redaction-marker.js +125 -0
- package/dist/registry.d.ts +21 -15
- package/dist/registry.js +409 -376
- package/dist/routes/access-tokens.js +1 -1
- package/dist/routes/actor-labels.js +1 -1
- package/dist/routes/connect.js +1 -1
- package/dist/routes/dispatch.js +103 -0
- package/dist/routes/mcp.js +170 -79
- package/dist/routes/oauth.js +3 -1
- package/dist/routes/operator.js +2 -2
- package/dist/routes/shared.d.ts +5 -4
- package/dist/routes/shared.js +244 -177
- package/dist/routes/skills.js +10 -8
- package/dist/routes/ui-config.js +27 -3
- package/dist/routes/ui-data.js +21 -20
- package/dist/routes/ui.js +1 -1
- package/dist/runtime/call-admission.js +0 -26
- package/dist/runtime/call-entry.js +30 -0
- package/dist/runtime/call.js +556 -0
- package/dist/runtime/connector-scope.js +7 -0
- package/dist/runtime/credential-probe.js +34 -0
- package/dist/runtime/executor.js +40 -0
- package/dist/runtime/native-storage.js +63 -0
- package/dist/runtime/registry.js +27 -0
- package/dist/runtime/request-scope.js +72 -0
- package/dist/runtime/run.js +15 -7
- package/dist/runtime/shared-read.js +34 -5
- package/dist/runtime/storage.js +34 -21
- package/dist/sent-secrets.d.ts +194 -37
- package/dist/sent-secrets.js +1743 -340
- package/dist/server.js +5 -56
- package/dist/skills.js +322 -222
- package/dist/sqlite.js +15 -14
- package/dist/storage/d1-copy.js +255 -0
- package/dist/storage/d1-driver.js +15 -0
- package/dist/storage/keys.js +28 -0
- package/dist/storage/sql-driver.js +88 -0
- package/dist/storage/sql-native.js +544 -0
- package/dist/storage/sql-schema.d.ts +6 -0
- package/dist/storage/sql-schema.js +15 -0
- package/dist/storage/sql.d.ts +14 -20
- package/dist/storage/sql.js +29 -535
- package/dist/timeout.js +0 -26
- package/dist/tool-safety.js +20 -10
- package/dist/types.d.ts +7 -109
- package/dist/upward.js +3 -0
- package/dist/usage-guide.js +3 -1
- package/dist/validate.d.ts +4 -2
- package/dist/validate.js +86 -9
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/dist/worker.js +312 -292
- package/dist/workspace-subject.js +5 -1
- package/dist/write-outcome.js +454 -34
- package/documentation/README.md +27 -7
- package/documentation/architecture.md +2547 -226
- package/documentation/auth.md +821 -98
- package/documentation/code-mode.md +49 -16
- package/documentation/deploying.md +164 -20
- package/documentation/hosted-mcp-migration.md +460 -0
- package/documentation/integrating.md +129 -144
- package/documentation/meta-tools.md +409 -32
- package/documentation/operating.md +27 -3
- package/documentation/operator-tests.md +3 -0
- package/documentation/operator-ui.md +68 -45
- package/documentation/provider-auth-migration.md +16 -63
- package/documentation/provider-migration-0.29.md +10 -5
- package/documentation/provider-migration-0.35.md +975 -0
- package/documentation/providers.md +965 -0
- package/examples/worker/AGENTS.md +23 -9
- package/examples/worker/README.md +254 -135
- package/examples/worker/alchemy.run.ts +116 -0
- package/examples/worker/gitignore +10 -0
- package/examples/worker/src/connecta.config.ts +23 -21
- package/examples/worker/wrangler.jsonc +14 -5
- package/guides/connecting-agents.md +157 -0
- package/guides/how-it-works.md +156 -0
- package/guides/safety-and-trust.md +153 -0
- package/package.json +27 -46
- package/templates/node/.env.example +3 -0
- package/templates/node/README.md +22 -2
- package/templates/node/docker-compose.yml +1 -0
- package/templates/node/package.json +3 -2
- package/templates/node/src/connecta.config.ts +8 -0
- package/dist/catalog-drift.d.ts +0 -138
- package/dist/catalog-drift.js +0 -578
- package/dist/providers/_shared/request-token.js +0 -83
- package/dist/providers/_shared/rest/operation-index.d.ts +0 -133
- package/dist/providers/_shared/rest/tools.d.ts +0 -141
- package/dist/providers/_shared/rest/value-safety.d.ts +0 -201
- package/dist/providers/basecamp/index.d.ts +0 -45
- package/dist/providers/basecamp/index.js +0 -997
- package/dist/providers/basecamp/skill.generated.js +0 -9
- package/dist/providers/cloudflare/rest.d.ts +0 -37
- package/dist/providers/cloudflare/rest.js +0 -1097
- package/dist/providers/github/hosted.js +0 -218
- package/dist/providers/github/rest.js +0 -321
- package/dist/providers/infisical/index.d.ts +0 -7
- package/dist/providers/infisical/index.js +0 -713
- package/dist/providers/infisical/skill.generated.js +0 -8
- package/dist/providers/intercom/index.d.ts +0 -24
- package/dist/providers/intercom/index.js +0 -121
- package/dist/providers/intercom/skill.generated.js +0 -8
- package/dist/providers/linear/index.d.ts +0 -55
- package/dist/providers/linear/index.js +0 -537
- package/dist/providers/linear/skill.generated.js +0 -8
- package/dist/providers/mixpanel/index.d.ts +0 -59
- package/dist/providers/mixpanel/index.js +0 -472
- package/dist/providers/mixpanel/operations.js +0 -20
- package/dist/providers/mixpanel/rest.js +0 -603
- package/dist/providers/mixpanel/skill.generated.js +0 -10
- package/dist/providers/mixpanel/value-safety.js +0 -16
- package/dist/providers/notion/index.d.ts +0 -67
- package/dist/providers/notion/index.js +0 -368
- package/dist/providers/notion/openapi.generated.js +0 -75
- package/dist/providers/notion/rest.d.ts +0 -24
- package/dist/providers/notion/rest.js +0 -1226
- package/dist/providers/notion/skill.generated.js +0 -11
- package/dist/providers/notion/value-safety.js +0 -56
- package/dist/providers/revenuecat/index.d.ts +0 -51
- package/dist/providers/revenuecat/index.js +0 -697
- package/dist/providers/revenuecat/skill.generated.js +0 -11
- package/dist/providers/stripe/rest.d.ts +0 -14
- package/dist/providers/stripe/rest.js +0 -402
- package/dist/providers/vercel/rest.d.ts +0 -20
- package/dist/providers/vercel/rest.js +0 -1020
- package/dist/providers/wispr-flow/index.d.ts +0 -14
- package/dist/providers/wispr-flow/index.js +0 -117
- package/dist/providers/wispr-flow/skill.generated.js +0 -8
- /package/dist/providers/github/{key.js → lib/key.js} +0 -0
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/** The Slides API root. Every path beneath it names a presentation by id. */
|
|
2
|
+
export declare const SLIDES_API_BASE_URL = "https://slides.googleapis.com/v1";
|
|
3
|
+
/**
|
|
4
|
+
* Exactly the scope this connection requests, and exactly what the Admin
|
|
5
|
+
* console's domain-wide delegation entry must list for it. `presentations`
|
|
6
|
+
* reads and writes every deck the user can open; Slides offers nothing
|
|
7
|
+
* narrower that can also write.
|
|
8
|
+
*/
|
|
9
|
+
export declare const SLIDES_SCOPES: readonly ["https://www.googleapis.com/auth/presentations"];
|
|
10
|
+
/** A bounded whole presentation, including structural hatch reads. */
|
|
11
|
+
export declare const SLIDES_MAX_RESPONSE_BYTES: number;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/** The Slides API root. Every path beneath it names a presentation by id. */
|
|
2
|
+
export const SLIDES_API_BASE_URL = "https://slides.googleapis.com/v1";
|
|
3
|
+
/**
|
|
4
|
+
* Exactly the scope this connection requests, and exactly what the Admin
|
|
5
|
+
* console's domain-wide delegation entry must list for it. `presentations`
|
|
6
|
+
* reads and writes every deck the user can open; Slides offers nothing
|
|
7
|
+
* narrower that can also write.
|
|
8
|
+
*/
|
|
9
|
+
export const SLIDES_SCOPES = ["https://www.googleapis.com/auth/presentations"];
|
|
10
|
+
/** A bounded whole presentation, including structural hatch reads. */
|
|
11
|
+
export const SLIDES_MAX_RESPONSE_BYTES = 16 * 1024 * 1024;
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
// Reviewed Request kinds from the archived Slides Discovery pin. No additional preview methods.
|
|
2
|
+
export const REQUEST_KINDS = [
|
|
3
|
+
"addCommentReply",
|
|
4
|
+
"createImage",
|
|
5
|
+
"createLine",
|
|
6
|
+
"createParagraphBullets",
|
|
7
|
+
"createShape",
|
|
8
|
+
"createSheetsChart",
|
|
9
|
+
"createSlide",
|
|
10
|
+
"createTable",
|
|
11
|
+
"createVideo",
|
|
12
|
+
"deleteComment",
|
|
13
|
+
"deleteCommentReply",
|
|
14
|
+
"deleteObject",
|
|
15
|
+
"deleteParagraphBullets",
|
|
16
|
+
"deleteTableColumn",
|
|
17
|
+
"deleteTableRow",
|
|
18
|
+
"deleteText",
|
|
19
|
+
"duplicateObject",
|
|
20
|
+
"groupObjects",
|
|
21
|
+
"insertComment",
|
|
22
|
+
"insertTableColumns",
|
|
23
|
+
"insertTableRows",
|
|
24
|
+
"insertText",
|
|
25
|
+
"mergeTableCells",
|
|
26
|
+
"refreshSheetsChart",
|
|
27
|
+
"replaceAllShapesWithImage",
|
|
28
|
+
"replaceAllShapesWithSheetsChart",
|
|
29
|
+
"replaceAllText",
|
|
30
|
+
"replaceImage",
|
|
31
|
+
"rerouteLine",
|
|
32
|
+
"ungroupObjects",
|
|
33
|
+
"unmergeTableCells",
|
|
34
|
+
"updateCommentPost",
|
|
35
|
+
"updateImageProperties",
|
|
36
|
+
"updateLineCategory",
|
|
37
|
+
"updateLineProperties",
|
|
38
|
+
"updatePageElementAltText",
|
|
39
|
+
"updatePageElementTransform",
|
|
40
|
+
"updatePageElementsZOrder",
|
|
41
|
+
"updatePageProperties",
|
|
42
|
+
"updateParagraphStyle",
|
|
43
|
+
"updateShapeProperties",
|
|
44
|
+
"updateSlideProperties",
|
|
45
|
+
"updateSlidesPosition",
|
|
46
|
+
"updateTableBorderProperties",
|
|
47
|
+
"updateTableCellProperties",
|
|
48
|
+
"updateTableColumnProperties",
|
|
49
|
+
"updateTableRowProperties",
|
|
50
|
+
"updateTextStyle",
|
|
51
|
+
"updateVideoProperties",
|
|
52
|
+
];
|
|
53
|
+
export const COMMENT_KINDS = new Set([
|
|
54
|
+
"addCommentReply",
|
|
55
|
+
"deleteComment",
|
|
56
|
+
"deleteCommentReply",
|
|
57
|
+
"insertComment",
|
|
58
|
+
"updateCommentPost",
|
|
59
|
+
]);
|
|
60
|
+
export const COMMENTS_UNSAVED = "Slides accepted the write but did not report its comment changes saved (commentUpdateState), so it was not all or none: other changes may have applied. Do not repeat it; re-read with list_comments to see what saved.";
|
|
@@ -0,0 +1,565 @@
|
|
|
1
|
+
// Google Slides named input/output contracts. Effect schemas own decoding and catalog rendering.
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { Integer, isMinChars, isMaxChars } from "../../../http/json-schema.js";
|
|
4
|
+
const matchesPattern = (pattern) => Schema.makeFilter((value) => pattern.test(value), {
|
|
5
|
+
expected: `a string matching ${pattern.source}`,
|
|
6
|
+
toJsonSchema: () => ({ pattern: pattern.source }),
|
|
7
|
+
});
|
|
8
|
+
export const get_presentation = {
|
|
9
|
+
input: Schema.Struct({
|
|
10
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
11
|
+
"limit": Schema.optionalKey(Integer.check(Schema.isGreaterThanOrEqualTo(1), Schema.isLessThanOrEqualTo(100)).annotate({
|
|
12
|
+
"default": 20,
|
|
13
|
+
"description": "Slides per page, 1 to 100; defaults to 20. A page also ends before ~192 KB.",
|
|
14
|
+
})),
|
|
15
|
+
"cursor": Schema.optionalKey(Schema.String.check(isMinChars(1), isMaxChars(4096), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({
|
|
16
|
+
"description": "Opaque page.nextCursor, or a textCursor-style cursor, this connection returned. Pass it back unchanged.",
|
|
17
|
+
})),
|
|
18
|
+
"maxCharsPerSlide": Schema.optionalKey(Integer.check(Schema.isGreaterThanOrEqualTo(0), Schema.isLessThanOrEqualTo(50000)).annotate({
|
|
19
|
+
"description": "Text kept per slide (notes apart), 0 to 50000; defaults to 4000. A cut gives a get_page cursor for the rest.",
|
|
20
|
+
})),
|
|
21
|
+
}),
|
|
22
|
+
output: Schema.Struct({
|
|
23
|
+
"presentationId": Schema.optionalKey(Schema.String),
|
|
24
|
+
"title": Schema.optionalKey(Schema.String),
|
|
25
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
26
|
+
"url": Schema.optionalKey(Schema.String),
|
|
27
|
+
"locale": Schema.optionalKey(Schema.String),
|
|
28
|
+
"canvasSize": Schema.optionalKey(Schema.Struct({
|
|
29
|
+
"width": Schema.optionalKey(Schema.Struct({ "magnitude": Schema.optionalKey(Schema.Finite), "unit": Schema.optionalKey(Schema.String) })),
|
|
30
|
+
"height": Schema.optionalKey(Schema.Struct({ "magnitude": Schema.optionalKey(Schema.Finite), "unit": Schema.optionalKey(Schema.String) })),
|
|
31
|
+
})),
|
|
32
|
+
"slideCount": Schema.optionalKey(Integer),
|
|
33
|
+
"notesMasterId": Schema.optionalKey(Schema.String),
|
|
34
|
+
"layouts": Schema.optionalKey(Schema.Array(Schema.Struct({
|
|
35
|
+
"objectId": Schema.optionalKey(Schema.String),
|
|
36
|
+
"kind": Schema.optionalKey(Schema.Literals(["master", "layout"])),
|
|
37
|
+
"name": Schema.optionalKey(Schema.String),
|
|
38
|
+
"displayName": Schema.optionalKey(Schema.String),
|
|
39
|
+
"masterId": Schema.optionalKey(Schema.String),
|
|
40
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
41
|
+
}))),
|
|
42
|
+
"layoutsCursor": Schema.optionalKey(Schema.String),
|
|
43
|
+
"slides": Schema.optionalKey(Schema.Array(Schema.Struct({
|
|
44
|
+
"objectId": Schema.optionalKey(Schema.String),
|
|
45
|
+
"index": Schema.optionalKey(Integer),
|
|
46
|
+
"layout": Schema.optionalKey(Schema.String),
|
|
47
|
+
"layoutId": Schema.optionalKey(Schema.String),
|
|
48
|
+
"skipped": Schema.optionalKey(Schema.Boolean),
|
|
49
|
+
"title": Schema.optionalKey(Schema.String),
|
|
50
|
+
"elements": Schema.optionalKey(Schema.Array(Schema.Struct({
|
|
51
|
+
"objectId": Schema.optionalKey(Schema.String),
|
|
52
|
+
"kind": Schema.optionalKey(Schema.Literals(["shape", "table", "wordArt", "image", "video", "chart", "line", "other"])),
|
|
53
|
+
"placeholder": Schema.optionalKey(Schema.String),
|
|
54
|
+
"text": Schema.optionalKey(Schema.String),
|
|
55
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
56
|
+
"textCursor": Schema.optionalKey(Schema.String),
|
|
57
|
+
"altText": Schema.optionalKey(Schema.String),
|
|
58
|
+
"spreadsheetId": Schema.optionalKey(Schema.String),
|
|
59
|
+
}))),
|
|
60
|
+
"omittedElements": Schema.optionalKey(Integer),
|
|
61
|
+
"elementsCursor": Schema.optionalKey(Schema.String),
|
|
62
|
+
"notesPageId": Schema.optionalKey(Schema.String),
|
|
63
|
+
"notes": Schema.optionalKey(Schema.String),
|
|
64
|
+
"notesCursor": Schema.optionalKey(Schema.String),
|
|
65
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
66
|
+
}))),
|
|
67
|
+
"page": Schema.optionalKey(Schema.Struct({ "hasMore": Schema.optionalKey(Schema.Boolean), "nextCursor": Schema.optionalKey(Schema.String) })),
|
|
68
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
69
|
+
}),
|
|
70
|
+
};
|
|
71
|
+
export const get_page = {
|
|
72
|
+
input: Schema.Struct({
|
|
73
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
74
|
+
"pageObjectId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_][A-Za-z0-9_:-]*$"))).annotate({ "description": "A slide's, layout's, master's, or notes page's objectId." }),
|
|
75
|
+
"limit": Schema.optionalKey(Integer.check(Schema.isGreaterThanOrEqualTo(1), Schema.isLessThanOrEqualTo(500)).annotate({
|
|
76
|
+
"default": 50,
|
|
77
|
+
"description": "Elements per page, 1 to 500; defaults to 50. A page also ends before ~192 KB.",
|
|
78
|
+
})),
|
|
79
|
+
"cursor": Schema.optionalKey(Schema.String.check(isMinChars(1), isMaxChars(4096), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({
|
|
80
|
+
"description": "Opaque page.nextCursor, or a textCursor-style cursor, this connection returned. Pass it back unchanged.",
|
|
81
|
+
})),
|
|
82
|
+
}),
|
|
83
|
+
output: Schema.Struct({
|
|
84
|
+
"presentationId": Schema.optionalKey(Schema.String),
|
|
85
|
+
"pageObjectId": Schema.optionalKey(Schema.String),
|
|
86
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
87
|
+
"pageType": Schema.optionalKey(Schema.String),
|
|
88
|
+
"layoutId": Schema.optionalKey(Schema.String),
|
|
89
|
+
"masterId": Schema.optionalKey(Schema.String),
|
|
90
|
+
"notesPageId": Schema.optionalKey(Schema.String),
|
|
91
|
+
"skipped": Schema.optionalKey(Schema.Boolean),
|
|
92
|
+
"speakerNotesObjectId": Schema.optionalKey(Schema.String),
|
|
93
|
+
"name": Schema.optionalKey(Schema.String),
|
|
94
|
+
"displayName": Schema.optionalKey(Schema.String),
|
|
95
|
+
"elementCount": Schema.optionalKey(Integer),
|
|
96
|
+
"properties": Schema.optionalKey(Schema.Record(Schema.String, Schema.Unknown)),
|
|
97
|
+
"elements": Schema.optionalKey(Schema.Array(Schema.Struct({
|
|
98
|
+
"objectId": Schema.optionalKey(Schema.String),
|
|
99
|
+
"kind": Schema.optionalKey(Schema.Literals(["shape", "table", "wordArt", "image", "video", "chart", "line", "other"])),
|
|
100
|
+
"groupId": Schema.optionalKey(Schema.String),
|
|
101
|
+
"placeholder": Schema.optionalKey(Schema.String),
|
|
102
|
+
"placeholderIndex": Schema.optionalKey(Integer),
|
|
103
|
+
"placeholderParentId": Schema.optionalKey(Schema.String),
|
|
104
|
+
"text": Schema.optionalKey(Schema.String),
|
|
105
|
+
"textOffset": Schema.optionalKey(Integer),
|
|
106
|
+
"textLength": Schema.optionalKey(Integer),
|
|
107
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
108
|
+
"altText": Schema.optionalKey(Schema.String),
|
|
109
|
+
"spreadsheetId": Schema.optionalKey(Schema.String),
|
|
110
|
+
}))),
|
|
111
|
+
"page": Schema.optionalKey(Schema.Struct({ "hasMore": Schema.optionalKey(Schema.Boolean), "nextCursor": Schema.optionalKey(Schema.String) })),
|
|
112
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
113
|
+
}),
|
|
114
|
+
};
|
|
115
|
+
export const list_layouts = {
|
|
116
|
+
input: Schema.Struct({
|
|
117
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
118
|
+
"limit": Schema.optionalKey(Integer.check(Schema.isGreaterThanOrEqualTo(1), Schema.isLessThanOrEqualTo(500)).annotate({
|
|
119
|
+
"default": 100,
|
|
120
|
+
"description": "Masters and layouts per page, 1 to 500; defaults to 100. A page also ends before ~192 KB.",
|
|
121
|
+
})),
|
|
122
|
+
"cursor": Schema.optionalKey(Schema.String.check(isMinChars(1), isMaxChars(4096), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({
|
|
123
|
+
"description": "Opaque page.nextCursor, or a textCursor-style cursor, this connection returned. Pass it back unchanged.",
|
|
124
|
+
})),
|
|
125
|
+
}),
|
|
126
|
+
output: Schema.Struct({
|
|
127
|
+
"presentationId": Schema.String,
|
|
128
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
129
|
+
"notesMasterId": Schema.optionalKey(Schema.String),
|
|
130
|
+
"page": Schema.Struct({
|
|
131
|
+
"hasMore": Schema.Boolean,
|
|
132
|
+
"nextCursor": Schema.optionalKey(Schema.String),
|
|
133
|
+
"total": Schema.optionalKey(Integer),
|
|
134
|
+
}),
|
|
135
|
+
"items": Schema.Array(Schema.Struct({
|
|
136
|
+
"objectId": Schema.optionalKey(Schema.String),
|
|
137
|
+
"kind": Schema.optionalKey(Schema.Literals(["master", "layout"])),
|
|
138
|
+
"name": Schema.optionalKey(Schema.String),
|
|
139
|
+
"displayName": Schema.optionalKey(Schema.String),
|
|
140
|
+
"masterId": Schema.optionalKey(Schema.String),
|
|
141
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
142
|
+
})),
|
|
143
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
144
|
+
}),
|
|
145
|
+
};
|
|
146
|
+
export const list_comments = {
|
|
147
|
+
input: Schema.Struct({
|
|
148
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
149
|
+
"pageObjectId": Schema.optionalKey(Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_][A-Za-z0-9_:-]*$"))).annotate({ "description": "Only this slide's or notes page's threads; omit for the whole deck." })),
|
|
150
|
+
"limit": Schema.optionalKey(Integer.check(Schema.isGreaterThanOrEqualTo(1), Schema.isLessThanOrEqualTo(500)).annotate({
|
|
151
|
+
"default": 50,
|
|
152
|
+
"description": "Threads per page, 1 to 500; defaults to 50. A page also ends before ~192 KB.",
|
|
153
|
+
})),
|
|
154
|
+
"cursor": Schema.optionalKey(Schema.String.check(isMinChars(1), isMaxChars(4096), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({
|
|
155
|
+
"description": "Opaque page.nextCursor, or a textCursor-style cursor, this connection returned. Pass it back unchanged.",
|
|
156
|
+
})),
|
|
157
|
+
}),
|
|
158
|
+
output: Schema.Struct({
|
|
159
|
+
"presentationId": Schema.String,
|
|
160
|
+
"pageObjectId": Schema.optionalKey(Schema.String),
|
|
161
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
162
|
+
"page": Schema.Struct({
|
|
163
|
+
"hasMore": Schema.Boolean,
|
|
164
|
+
"nextCursor": Schema.optionalKey(Schema.String),
|
|
165
|
+
"total": Schema.optionalKey(Integer),
|
|
166
|
+
}),
|
|
167
|
+
"items": Schema.Array(Schema.Struct({
|
|
168
|
+
"commentId": Schema.optionalKey(Schema.String),
|
|
169
|
+
"anchorId": Schema.optionalKey(Schema.String),
|
|
170
|
+
"status": Schema.optionalKey(Schema.String),
|
|
171
|
+
"pageObjectIds": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
172
|
+
"objectIds": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
173
|
+
"replyCount": Schema.optionalKey(Integer),
|
|
174
|
+
"quote": Schema.optionalKey(Schema.String),
|
|
175
|
+
"quoteOffset": Schema.optionalKey(Integer),
|
|
176
|
+
"quoteLength": Schema.optionalKey(Integer),
|
|
177
|
+
"headPost": Schema.optionalKey(Schema.Struct({
|
|
178
|
+
"postId": Schema.optionalKey(Schema.String),
|
|
179
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
180
|
+
"author": Schema.optionalKey(Schema.Struct({
|
|
181
|
+
"user": Schema.optionalKey(Schema.String),
|
|
182
|
+
"displayName": Schema.optionalKey(Schema.String),
|
|
183
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
184
|
+
"me": Schema.optionalKey(Schema.Boolean),
|
|
185
|
+
"anonymous": Schema.optionalKey(Schema.Boolean),
|
|
186
|
+
})),
|
|
187
|
+
"content": Schema.optionalKey(Schema.String),
|
|
188
|
+
"contentOffset": Schema.optionalKey(Integer),
|
|
189
|
+
"contentLength": Schema.optionalKey(Integer),
|
|
190
|
+
"commentAction": Schema.optionalKey(Schema.String),
|
|
191
|
+
"assigneeEmail": Schema.optionalKey(Schema.String),
|
|
192
|
+
"createTime": Schema.optionalKey(Schema.String),
|
|
193
|
+
"updateTime": Schema.optionalKey(Schema.String),
|
|
194
|
+
"deleted": Schema.optionalKey(Schema.Boolean),
|
|
195
|
+
"imported": Schema.optionalKey(Schema.Boolean),
|
|
196
|
+
})),
|
|
197
|
+
"replies": Schema.optionalKey(Schema.Array(Schema.Struct({
|
|
198
|
+
"postId": Schema.optionalKey(Schema.String),
|
|
199
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
200
|
+
"author": Schema.optionalKey(Schema.Struct({
|
|
201
|
+
"user": Schema.optionalKey(Schema.String),
|
|
202
|
+
"displayName": Schema.optionalKey(Schema.String),
|
|
203
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
204
|
+
"me": Schema.optionalKey(Schema.Boolean),
|
|
205
|
+
"anonymous": Schema.optionalKey(Schema.Boolean),
|
|
206
|
+
})),
|
|
207
|
+
"content": Schema.optionalKey(Schema.String),
|
|
208
|
+
"contentOffset": Schema.optionalKey(Integer),
|
|
209
|
+
"contentLength": Schema.optionalKey(Integer),
|
|
210
|
+
"commentAction": Schema.optionalKey(Schema.String),
|
|
211
|
+
"assigneeEmail": Schema.optionalKey(Schema.String),
|
|
212
|
+
"createTime": Schema.optionalKey(Schema.String),
|
|
213
|
+
"updateTime": Schema.optionalKey(Schema.String),
|
|
214
|
+
"deleted": Schema.optionalKey(Schema.Boolean),
|
|
215
|
+
"imported": Schema.optionalKey(Schema.Boolean),
|
|
216
|
+
}))),
|
|
217
|
+
"repliesOffset": Schema.optionalKey(Integer),
|
|
218
|
+
"continued": Schema.optionalKey(Schema.Boolean),
|
|
219
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
220
|
+
"idsNotShown": Schema.optionalKey(Schema.Boolean),
|
|
221
|
+
})),
|
|
222
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
223
|
+
}),
|
|
224
|
+
};
|
|
225
|
+
export const get_slide_thumbnail = {
|
|
226
|
+
input: Schema.Struct({
|
|
227
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
228
|
+
"slideObjectId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_][A-Za-z0-9_:-]*$"))).annotate({ "description": "Slide objectId from get_presentation." }),
|
|
229
|
+
"size": Schema.optionalKey(Schema.Literals(["SMALL", "MEDIUM", "LARGE", "WIDTH2000_PX"]).annotate({
|
|
230
|
+
"description": "Width: SMALL 200px, MEDIUM 800px, LARGE 1600px, WIDTH2000_PX 2000px; Slides chooses when omitted.",
|
|
231
|
+
})),
|
|
232
|
+
}),
|
|
233
|
+
output: Schema.Struct({
|
|
234
|
+
"contentUrl": Schema.optionalKey(Schema.String),
|
|
235
|
+
"width": Schema.optionalKey(Integer),
|
|
236
|
+
"height": Schema.optionalKey(Integer),
|
|
237
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
238
|
+
}),
|
|
239
|
+
};
|
|
240
|
+
export const create_presentation = {
|
|
241
|
+
input: Schema.Struct({
|
|
242
|
+
"title": Schema.String.check(isMinChars(1), isMaxChars(1000), matchesPattern(new RegExp("^[^\\r\\n]*$"))).annotate({
|
|
243
|
+
"description": "The deck's title, as Drive shows it.",
|
|
244
|
+
}),
|
|
245
|
+
}),
|
|
246
|
+
output: Schema.Struct({
|
|
247
|
+
"presentationId": Schema.String,
|
|
248
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
249
|
+
"title": Schema.optionalKey(Schema.String),
|
|
250
|
+
"url": Schema.optionalKey(Schema.String),
|
|
251
|
+
"slideObjectIds": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
252
|
+
"slideObjectIdsNotShown": Schema.optionalKey(Integer),
|
|
253
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
254
|
+
}),
|
|
255
|
+
};
|
|
256
|
+
export const create_slide = {
|
|
257
|
+
input: Schema.Struct({
|
|
258
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
259
|
+
"layout": Schema.optionalKey(Schema.Literals([
|
|
260
|
+
"BLANK",
|
|
261
|
+
"CAPTION_ONLY",
|
|
262
|
+
"TITLE",
|
|
263
|
+
"TITLE_AND_BODY",
|
|
264
|
+
"TITLE_AND_TWO_COLUMNS",
|
|
265
|
+
"TITLE_ONLY",
|
|
266
|
+
"SECTION_HEADER",
|
|
267
|
+
"SECTION_TITLE_AND_DESCRIPTION",
|
|
268
|
+
"ONE_COLUMN_TEXT",
|
|
269
|
+
"MAIN_POINT",
|
|
270
|
+
"BIG_NUMBER",
|
|
271
|
+
]).annotate({
|
|
272
|
+
"description": "Predefined layout; the deck's theme must have it. Omit both layout and layoutId for BLANK.",
|
|
273
|
+
})),
|
|
274
|
+
"layoutId": Schema.optionalKey(Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_][A-Za-z0-9_:-]*$"))).annotate({ "description": "A layouts[].objectId from get_presentation, instead of layout." })),
|
|
275
|
+
"insertionIndex": Schema.optionalKey(Integer.check(Schema.isGreaterThanOrEqualTo(0), Schema.isLessThanOrEqualTo(100000)).annotate({
|
|
276
|
+
"description": "0-based position, as get_presentation numbers slides; omit to append.",
|
|
277
|
+
})),
|
|
278
|
+
}),
|
|
279
|
+
output: Schema.Struct({
|
|
280
|
+
"presentationId": Schema.String,
|
|
281
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
282
|
+
"slideObjectId": Schema.String,
|
|
283
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
284
|
+
}),
|
|
285
|
+
};
|
|
286
|
+
export const replace_all_text = {
|
|
287
|
+
input: Schema.Struct({
|
|
288
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
289
|
+
"replacements": Schema.Array(Schema.Struct({
|
|
290
|
+
"find": Schema.String.check(isMinChars(1), isMaxChars(1000)).annotate({
|
|
291
|
+
"description": "Literal text to find.",
|
|
292
|
+
}),
|
|
293
|
+
"replace": Schema.String.check(isMaxChars(10000)).annotate({
|
|
294
|
+
"description": "Replacement; empty deletes the match.",
|
|
295
|
+
}),
|
|
296
|
+
"matchCase": Schema.optionalKey(Schema.Boolean.annotate({ "description": "Case-sensitive; defaults to true." })),
|
|
297
|
+
}).annotate({ "description": "One find-and-replace." }))
|
|
298
|
+
.check(Schema.isMinLength(1), Schema.isMaxLength(50))
|
|
299
|
+
.annotate({ "description": "Applied in order, 1 to 50 (connecta's bound)." }),
|
|
300
|
+
"slideObjectIds": Schema.optionalKey(Schema.Array(Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_][A-Za-z0-9_:-]*$"))).annotate({ "description": "A slide objectId." }))
|
|
301
|
+
.check(Schema.isMinLength(1), Schema.isMaxLength(500))
|
|
302
|
+
.annotate({ "description": "Limit to these slides; omit for every slide." })),
|
|
303
|
+
"requiredRevisionId": Schema.optionalKey(Schema.String.check(isMinChars(1), isMaxChars(512), matchesPattern(new RegExp("^[^\\s]+$"))).annotate({
|
|
304
|
+
"description": "revisionId from get_presentation; the write is refused, unapplied, if the deck changed since.",
|
|
305
|
+
})),
|
|
306
|
+
}),
|
|
307
|
+
output: Schema.Struct({
|
|
308
|
+
"presentationId": Schema.String,
|
|
309
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
310
|
+
"occurrencesChanged": Integer,
|
|
311
|
+
"replacements": Schema.Array(Schema.Struct({ "find": Schema.optionalKey(Schema.String), "occurrencesChanged": Schema.optionalKey(Integer) })),
|
|
312
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
313
|
+
}),
|
|
314
|
+
};
|
|
315
|
+
export const create_comment = {
|
|
316
|
+
input: Schema.Struct({
|
|
317
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
318
|
+
"objectId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_][A-Za-z0-9_:-]*$"))).annotate({ "description": "The page or element to comment on: the shape or table, for text or a cell." }),
|
|
319
|
+
"content": Schema.String.check(isMinChars(1), isMaxChars(2048)).annotate({
|
|
320
|
+
"description": "Plain text; Slides' cap is 2048 UTF-8 bytes.",
|
|
321
|
+
}),
|
|
322
|
+
"textRange": Schema.optionalKey(Schema.Struct({
|
|
323
|
+
"startIndex": Integer.check(Schema.isGreaterThanOrEqualTo(0), Schema.isLessThanOrEqualTo(10000000)).annotate({
|
|
324
|
+
"description": "First character.",
|
|
325
|
+
}),
|
|
326
|
+
"endIndex": Integer.check(Schema.isGreaterThanOrEqualTo(1), Schema.isLessThanOrEqualTo(10000000)).annotate({
|
|
327
|
+
"description": "One past the last.",
|
|
328
|
+
}),
|
|
329
|
+
}).annotate({ "description": "Anchor to this text of the shape, or of the cell: 0-based, end exclusive." })),
|
|
330
|
+
"cell": Schema.optionalKey(Schema.Struct({
|
|
331
|
+
"rowIndex": Integer.check(Schema.isGreaterThanOrEqualTo(0), Schema.isLessThanOrEqualTo(100000)).annotate({
|
|
332
|
+
"description": "Row.",
|
|
333
|
+
}),
|
|
334
|
+
"columnIndex": Integer.check(Schema.isGreaterThanOrEqualTo(0), Schema.isLessThanOrEqualTo(100000)).annotate({
|
|
335
|
+
"description": "Column.",
|
|
336
|
+
}),
|
|
337
|
+
}).annotate({ "description": "A table cell, 0-based: with textRange, that text in it; else the whole cell." })),
|
|
338
|
+
"assigneeEmail": Schema.optionalKey(Schema.String.check(isMinChars(3), isMaxChars(320), matchesPattern(new RegExp("^[^\\s@]+@[^\\s@]+$"))).annotate({
|
|
339
|
+
"description": "Assign the thread to this address; Slides notifies them.",
|
|
340
|
+
})),
|
|
341
|
+
"requiredRevisionId": Schema.optionalKey(Schema.String.check(isMinChars(1), isMaxChars(512), matchesPattern(new RegExp("^[^\\s]+$"))).annotate({
|
|
342
|
+
"description": "Refuse, unapplied, if the deck changed since this revision.",
|
|
343
|
+
})),
|
|
344
|
+
}),
|
|
345
|
+
output: Schema.Struct({
|
|
346
|
+
"presentationId": Schema.String,
|
|
347
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
348
|
+
"commentUpdateState": Schema.optionalKey(Schema.String),
|
|
349
|
+
"note": Schema.optionalKey(Schema.String),
|
|
350
|
+
"commentId": Schema.optionalKey(Schema.String),
|
|
351
|
+
"anchorId": Schema.optionalKey(Schema.String),
|
|
352
|
+
"status": Schema.optionalKey(Schema.String),
|
|
353
|
+
"quote": Schema.optionalKey(Schema.String),
|
|
354
|
+
"headPost": Schema.optionalKey(Schema.Struct({
|
|
355
|
+
"postId": Schema.optionalKey(Schema.String),
|
|
356
|
+
"author": Schema.optionalKey(Schema.Struct({
|
|
357
|
+
"user": Schema.optionalKey(Schema.String),
|
|
358
|
+
"displayName": Schema.optionalKey(Schema.String),
|
|
359
|
+
"me": Schema.optionalKey(Schema.Boolean),
|
|
360
|
+
"anonymous": Schema.optionalKey(Schema.Boolean),
|
|
361
|
+
})),
|
|
362
|
+
"content": Schema.optionalKey(Schema.String),
|
|
363
|
+
"contentOffset": Schema.optionalKey(Integer),
|
|
364
|
+
"contentLength": Schema.optionalKey(Integer),
|
|
365
|
+
"commentAction": Schema.optionalKey(Schema.String),
|
|
366
|
+
"assigneeEmail": Schema.optionalKey(Schema.String),
|
|
367
|
+
"createTime": Schema.optionalKey(Schema.String),
|
|
368
|
+
"updateTime": Schema.optionalKey(Schema.String),
|
|
369
|
+
"deleted": Schema.optionalKey(Schema.Boolean),
|
|
370
|
+
"imported": Schema.optionalKey(Schema.Boolean),
|
|
371
|
+
})),
|
|
372
|
+
"replies": Schema.optionalKey(Schema.Array(Schema.Struct({
|
|
373
|
+
"postId": Schema.optionalKey(Schema.String),
|
|
374
|
+
"author": Schema.optionalKey(Schema.Struct({
|
|
375
|
+
"user": Schema.optionalKey(Schema.String),
|
|
376
|
+
"displayName": Schema.optionalKey(Schema.String),
|
|
377
|
+
"me": Schema.optionalKey(Schema.Boolean),
|
|
378
|
+
"anonymous": Schema.optionalKey(Schema.Boolean),
|
|
379
|
+
})),
|
|
380
|
+
"content": Schema.optionalKey(Schema.String),
|
|
381
|
+
"contentOffset": Schema.optionalKey(Integer),
|
|
382
|
+
"contentLength": Schema.optionalKey(Integer),
|
|
383
|
+
"commentAction": Schema.optionalKey(Schema.String),
|
|
384
|
+
"assigneeEmail": Schema.optionalKey(Schema.String),
|
|
385
|
+
"createTime": Schema.optionalKey(Schema.String),
|
|
386
|
+
"updateTime": Schema.optionalKey(Schema.String),
|
|
387
|
+
"deleted": Schema.optionalKey(Schema.Boolean),
|
|
388
|
+
"imported": Schema.optionalKey(Schema.Boolean),
|
|
389
|
+
}))),
|
|
390
|
+
"idsNotShown": Schema.optionalKey(Schema.Boolean),
|
|
391
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
392
|
+
}),
|
|
393
|
+
};
|
|
394
|
+
export const create_comment_reply = {
|
|
395
|
+
input: Schema.Struct({
|
|
396
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
397
|
+
"commentId": Schema.String.check(isMinChars(1), isMaxChars(1024), matchesPattern(new RegExp("^\\S+$"))).annotate({
|
|
398
|
+
"description": "commentId from list_comments or create_comment.",
|
|
399
|
+
}),
|
|
400
|
+
"content": Schema.String.check(isMinChars(1), isMaxChars(2048)).annotate({
|
|
401
|
+
"description": "Plain text, up to 2048 UTF-8 bytes.",
|
|
402
|
+
}),
|
|
403
|
+
}),
|
|
404
|
+
output: Schema.Struct({
|
|
405
|
+
"presentationId": Schema.String,
|
|
406
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
407
|
+
"commentUpdateState": Schema.optionalKey(Schema.String),
|
|
408
|
+
"note": Schema.optionalKey(Schema.String),
|
|
409
|
+
"commentId": Schema.String,
|
|
410
|
+
"post": Schema.optionalKey(Schema.Struct({
|
|
411
|
+
"postId": Schema.optionalKey(Schema.String),
|
|
412
|
+
"author": Schema.optionalKey(Schema.Struct({
|
|
413
|
+
"user": Schema.optionalKey(Schema.String),
|
|
414
|
+
"displayName": Schema.optionalKey(Schema.String),
|
|
415
|
+
"me": Schema.optionalKey(Schema.Boolean),
|
|
416
|
+
"anonymous": Schema.optionalKey(Schema.Boolean),
|
|
417
|
+
})),
|
|
418
|
+
"content": Schema.optionalKey(Schema.String),
|
|
419
|
+
"contentOffset": Schema.optionalKey(Integer),
|
|
420
|
+
"contentLength": Schema.optionalKey(Integer),
|
|
421
|
+
"commentAction": Schema.optionalKey(Schema.String),
|
|
422
|
+
"assigneeEmail": Schema.optionalKey(Schema.String),
|
|
423
|
+
"createTime": Schema.optionalKey(Schema.String),
|
|
424
|
+
"updateTime": Schema.optionalKey(Schema.String),
|
|
425
|
+
"deleted": Schema.optionalKey(Schema.Boolean),
|
|
426
|
+
"imported": Schema.optionalKey(Schema.Boolean),
|
|
427
|
+
})),
|
|
428
|
+
"idsNotShown": Schema.optionalKey(Schema.Boolean),
|
|
429
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
430
|
+
}),
|
|
431
|
+
};
|
|
432
|
+
export const update_comment_thread = {
|
|
433
|
+
input: Schema.Struct({
|
|
434
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
435
|
+
"commentId": Schema.String.check(isMinChars(1), isMaxChars(1024), matchesPattern(new RegExp("^\\S+$"))).annotate({
|
|
436
|
+
"description": "commentId from list_comments or create_comment.",
|
|
437
|
+
}),
|
|
438
|
+
"status": Schema.optionalKey(Schema.Literals(["RESOLVED", "OPEN"]).annotate({ "description": "Resolve the thread, or reopen it." })),
|
|
439
|
+
"assigneeEmail": Schema.optionalKey(Schema.String.check(isMinChars(3), isMaxChars(320), matchesPattern(new RegExp("^[^\\s@]+@[^\\s@]+$"))).annotate({
|
|
440
|
+
"description": "Reassign an assigned thread instead; needs content.",
|
|
441
|
+
})),
|
|
442
|
+
"content": Schema.optionalKey(Schema.String.check(isMinChars(1), isMaxChars(2048)).annotate({
|
|
443
|
+
"description": "Note posted with it, up to 2048 UTF-8 bytes; required to reassign.",
|
|
444
|
+
})),
|
|
445
|
+
}),
|
|
446
|
+
output: Schema.Struct({
|
|
447
|
+
"presentationId": Schema.String,
|
|
448
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
449
|
+
"commentUpdateState": Schema.optionalKey(Schema.String),
|
|
450
|
+
"note": Schema.optionalKey(Schema.String),
|
|
451
|
+
"commentId": Schema.String,
|
|
452
|
+
"post": Schema.optionalKey(Schema.Struct({
|
|
453
|
+
"postId": Schema.optionalKey(Schema.String),
|
|
454
|
+
"author": Schema.optionalKey(Schema.Struct({
|
|
455
|
+
"user": Schema.optionalKey(Schema.String),
|
|
456
|
+
"displayName": Schema.optionalKey(Schema.String),
|
|
457
|
+
"me": Schema.optionalKey(Schema.Boolean),
|
|
458
|
+
"anonymous": Schema.optionalKey(Schema.Boolean),
|
|
459
|
+
})),
|
|
460
|
+
"content": Schema.optionalKey(Schema.String),
|
|
461
|
+
"contentOffset": Schema.optionalKey(Integer),
|
|
462
|
+
"contentLength": Schema.optionalKey(Integer),
|
|
463
|
+
"commentAction": Schema.optionalKey(Schema.String),
|
|
464
|
+
"assigneeEmail": Schema.optionalKey(Schema.String),
|
|
465
|
+
"createTime": Schema.optionalKey(Schema.String),
|
|
466
|
+
"updateTime": Schema.optionalKey(Schema.String),
|
|
467
|
+
"deleted": Schema.optionalKey(Schema.Boolean),
|
|
468
|
+
"imported": Schema.optionalKey(Schema.Boolean),
|
|
469
|
+
})),
|
|
470
|
+
"idsNotShown": Schema.optionalKey(Schema.Boolean),
|
|
471
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
472
|
+
}),
|
|
473
|
+
};
|
|
474
|
+
export const update_comment_post = {
|
|
475
|
+
input: Schema.Struct({
|
|
476
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
477
|
+
"commentId": Schema.String.check(isMinChars(1), isMaxChars(1024), matchesPattern(new RegExp("^\\S+$"))).annotate({
|
|
478
|
+
"description": "commentId from list_comments or create_comment.",
|
|
479
|
+
}),
|
|
480
|
+
"postId": Schema.String.check(isMinChars(1), isMaxChars(1024), matchesPattern(new RegExp("^\\S+$"))).annotate({
|
|
481
|
+
"description": "postId of the post, from list_comments.",
|
|
482
|
+
}),
|
|
483
|
+
"content": Schema.String.check(isMinChars(1), isMaxChars(2048)).annotate({
|
|
484
|
+
"description": "The new plain text, up to 2048 UTF-8 bytes.",
|
|
485
|
+
}),
|
|
486
|
+
}),
|
|
487
|
+
output: Schema.Struct({
|
|
488
|
+
"presentationId": Schema.String,
|
|
489
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
490
|
+
"commentUpdateState": Schema.optionalKey(Schema.String),
|
|
491
|
+
"note": Schema.optionalKey(Schema.String),
|
|
492
|
+
"commentId": Schema.String,
|
|
493
|
+
"postId": Schema.String,
|
|
494
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
495
|
+
}),
|
|
496
|
+
};
|
|
497
|
+
export const delete_comment = {
|
|
498
|
+
input: Schema.Struct({
|
|
499
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
500
|
+
"commentId": Schema.String.check(isMinChars(1), isMaxChars(1024), matchesPattern(new RegExp("^\\S+$"))).annotate({
|
|
501
|
+
"description": "commentId from list_comments or create_comment.",
|
|
502
|
+
}),
|
|
503
|
+
}),
|
|
504
|
+
output: Schema.Struct({
|
|
505
|
+
"presentationId": Schema.String,
|
|
506
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
507
|
+
"commentUpdateState": Schema.optionalKey(Schema.String),
|
|
508
|
+
"note": Schema.optionalKey(Schema.String),
|
|
509
|
+
"commentId": Schema.String,
|
|
510
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
511
|
+
}),
|
|
512
|
+
};
|
|
513
|
+
export const delete_comment_reply = {
|
|
514
|
+
input: Schema.Struct({
|
|
515
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
516
|
+
"commentId": Schema.String.check(isMinChars(1), isMaxChars(1024), matchesPattern(new RegExp("^\\S+$"))).annotate({
|
|
517
|
+
"description": "commentId from list_comments or create_comment.",
|
|
518
|
+
}),
|
|
519
|
+
"postId": Schema.String.check(isMinChars(1), isMaxChars(1024), matchesPattern(new RegExp("^\\S+$"))).annotate({
|
|
520
|
+
"description": "postId of the reply, from list_comments.",
|
|
521
|
+
}),
|
|
522
|
+
}),
|
|
523
|
+
output: Schema.Struct({
|
|
524
|
+
"presentationId": Schema.String,
|
|
525
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
526
|
+
"commentUpdateState": Schema.optionalKey(Schema.String),
|
|
527
|
+
"note": Schema.optionalKey(Schema.String),
|
|
528
|
+
"commentId": Schema.String,
|
|
529
|
+
"postId": Schema.String,
|
|
530
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
531
|
+
}),
|
|
532
|
+
};
|
|
533
|
+
export const batch_update_presentation = {
|
|
534
|
+
input: Schema.Struct({
|
|
535
|
+
"presentationId": Schema.String.check(isMinChars(1), isMaxChars(256), matchesPattern(new RegExp("^[A-Za-z0-9_-]+$"))).annotate({ "description": "Presentation id: the part after /presentation/d/ in its URL, or from Drive." }),
|
|
536
|
+
"requiredRevisionId": Schema.String.check(isMinChars(1), isMaxChars(512), matchesPattern(new RegExp("^[^\\s]+$"))).annotate({
|
|
537
|
+
"description": "revisionId from get_presentation; the write is refused, unapplied, if the deck changed since.",
|
|
538
|
+
}),
|
|
539
|
+
"requests": Schema.Array(Schema.Record(Schema.String, Schema.Unknown)
|
|
540
|
+
.check(Schema.makeFilter((value) => Object.keys(value).length >= 1, {
|
|
541
|
+
expected: "minProperties 1",
|
|
542
|
+
toJsonSchema: () => ({ minProperties: 1 }),
|
|
543
|
+
}), Schema.makeFilter((value) => Object.keys(value).length <= 1, {
|
|
544
|
+
expected: "maxProperties 1",
|
|
545
|
+
toJsonSchema: () => ({ maxProperties: 1 }),
|
|
546
|
+
}))
|
|
547
|
+
.annotate({
|
|
548
|
+
"description": 'One Request with one key, as the Slides reference defines it: {"insertText": {...}}.',
|
|
549
|
+
}))
|
|
550
|
+
.check(Schema.isMinLength(1), Schema.isMaxLength(100))
|
|
551
|
+
.annotate({
|
|
552
|
+
"description": "Slides Request objects, applied in order, all or none but comments; 1 to 100 (connecta's bound).",
|
|
553
|
+
}),
|
|
554
|
+
}),
|
|
555
|
+
output: Schema.Struct({
|
|
556
|
+
"presentationId": Schema.String,
|
|
557
|
+
"revisionId": Schema.optionalKey(Schema.String),
|
|
558
|
+
"replies": Schema.Array(Schema.Struct({ "truncated": Schema.optionalKey(Schema.Array(Schema.String)) })),
|
|
559
|
+
"commentUpdateState": Schema.optionalKey(Schema.String),
|
|
560
|
+
"note": Schema.optionalKey(Schema.String),
|
|
561
|
+
"truncated": Schema.optionalKey(Schema.Array(Schema.String)),
|
|
562
|
+
}),
|
|
563
|
+
};
|
|
564
|
+
export const LayoutRow = list_layouts.output.fields.items.value;
|
|
565
|
+
export const CommentRow = list_comments.output.fields.items.value;
|