@withgateway/sdk 0.2.0 → 0.2.1
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/README.md +30 -6
- package/dist/cli.js +7815 -2406
- package/dist/cli.js.map +1 -1
- package/dist/cli.mjs +7807 -2398
- package/dist/cli.mjs.map +1 -1
- package/dist/files/index.d.mts +2 -0
- package/dist/files/index.d.ts +2 -0
- package/dist/files/index.js +446 -0
- package/dist/files/index.js.map +1 -0
- package/dist/files/index.mjs +395 -0
- package/dist/files/index.mjs.map +1 -0
- package/dist/index-BgvvQ3BC.d.ts +170 -0
- package/dist/index-CLkMr6VG.d.ts +171 -0
- package/dist/index-CdbmO4aX.d.mts +171 -0
- package/dist/index-CiKWoroJ.d.mts +170 -0
- package/dist/index.d.mts +3 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.js +2283 -116
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2255 -116
- package/dist/index.mjs.map +1 -1
- package/dist/traces/index.d.mts +2 -0
- package/dist/traces/index.d.ts +2 -0
- package/dist/traces/index.js +320 -0
- package/dist/traces/index.js.map +1 -0
- package/dist/traces/index.mjs +278 -0
- package/dist/traces/index.mjs.map +1 -0
- package/dist/tracing/index.js +16 -1
- package/dist/tracing/index.js.map +1 -1
- package/dist/tracing/index.mjs +16 -1
- package/dist/tracing/index.mjs.map +1 -1
- package/dist/worlds/index.d.mts +685 -1
- package/dist/worlds/index.d.ts +685 -1
- package/dist/worlds/index.js +1876 -32
- package/dist/worlds/index.js.map +1 -1
- package/dist/worlds/index.mjs +1875 -32
- package/dist/worlds/index.mjs.map +1 -1
- package/package.json +16 -1
- package/runtime/gatewaysdk/environment/_world.py +14 -1
- package/runtime/gatewaysdk/environment/schema/__init__.py +8 -0
- package/runtime/gatewaysdk/environment/schema/__main__.py +154 -19
- package/runtime/gatewaysdk/environment/schema/api.py +233 -37
- package/runtime/gatewaysdk/environment/schema/batch.py +38 -8
- package/runtime/gatewaysdk/environment/schema/compiler.py +89 -11
- package/runtime/gatewaysdk/environment/schema/conform.py +105 -13
- package/runtime/gatewaysdk/environment/schema/connector.py +442 -103
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/api/handlers.py +778 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/connector.toml +671 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/handlers.py +3 -2
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/parity.json +11 -5
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/provenance.json +1635 -100
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/instruction.md +7 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_activities.json +24 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_activity_devices.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_applecare_coverages.json +52 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_apps.json +35 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_audit_events.json +139 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_blueprint_apps.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_blueprint_configurations.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_blueprint_devices.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_blueprint_packages.json +8 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_blueprint_user_groups.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_blueprint_users.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_blueprints.json +39 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_configurations.json +64 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_device_assignments.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_mdm_device_details.json +55 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_mdm_devices.json +33 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_mdm_servers.json +56 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_org_devices.json +178 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_organizational_unit_memberships.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_organizational_units.json +24 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_packages.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_user_group_memberships.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_user_groups.json +30 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scenarios/default/seed/abm_users.json +115 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/scope.toml +49 -22
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/tests/tools.json +48 -0
- package/runtime/gatewaysdk/environment/schema/connectors/apple-business-manager/world.json +1180 -194
- package/runtime/gatewaysdk/environment/schema/connectors/asana/api/handlers.py +1026 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/connector.toml +511 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/fidelity.json +89 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/handlers.py +40 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/provenance.json +101 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/account_settings.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/custom_field_settings.json +60 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/custom_fields.json +43 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/enum_options.json +52 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/notifications.json +103 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/project_favorites.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/project_memberships.json +144 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/projects.json +120 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/recent_projects.json +19 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/sections.json +102 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/stories.json +852 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/task_custom_fields.json +508 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/task_followers.json +368 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/task_memberships.json +184 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/tasks.json +1921 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/teams.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/user_task_list_sections.json +32 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/user_task_lists.json +11 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/users.json +60 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/workspace_memberships.json +76 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scenarios/default/seed/workspaces.json +13 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/scope.toml +156 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/tests/routes.json +298 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/tests/tools.json +152 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/ui/static/assets/index-DTTTJ6a4.css +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/ui/static/assets/index-WS8dLEjv.js +67 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/ui/static/index.html +40 -0
- package/runtime/gatewaysdk/environment/schema/connectors/asana/world.json +1911 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/api/handlers.py +847 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/connector.toml +457 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/handlers.py +176 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/provenance.json +187 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/instruction.md +39 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/scenario.toml +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_favourites.json +29 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_footer_comments.json +984 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_inline_comments.json +355 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_labels.json +99 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_notifications.json +40 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_page_labels.json +209 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_page_versions.json +828 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_pages.json +949 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_recently_viewed_pages.json +59 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_sites.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_spaces.json +128 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_users.json +100 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/scenarios/default/seed/confluence_watches.json +96 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/tests/routes.json +212 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/tests/tools.json +140 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/tests/writes.json +201 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/assets/index-BWaOVdpn.js +70 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/assets/index-CKyfi3i5.css +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/avatars/acct-01.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/avatars/acct-02.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/avatars/acct-03.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/avatars/acct-04.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/avatars/acct-05.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/avatars/acct-06.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/avatars/space-DES.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/avatars/space-ENG.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/avatars/space-OPS.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/avatars/space-ORB.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/avatars/space-PN.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/fonts/AtlassianMono-latin.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/fonts/AtlassianSans-latin.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/fonts/AtlassianSansItalic-latin.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/ui/static/index.html +47 -0
- package/runtime/gatewaysdk/environment/schema/connectors/confluence/world.json +1346 -0
- package/runtime/gatewaysdk/environment/schema/connectors/custom/provenance.json +35 -0
- package/runtime/gatewaysdk/environment/schema/connectors/custom/tests/tools.json +123 -0
- package/runtime/gatewaysdk/environment/schema/connectors/custom/world.json +112 -24
- package/runtime/gatewaysdk/environment/schema/connectors/github/api/handlers.py +2923 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/connector.toml +2091 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/provenance.json +109 -81
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/instruction.md +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_apps.json +49 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_artifacts.json +26 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_branches.json +443 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_check_runs.json +220 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_check_suites.json +404 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_code_scanning_alerts.json +126 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_collaborators.json +100 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_commit_comments.json +43 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_commit_statuses.json +80 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_commits.json +461 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_dependabot_alerts.json +168 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_deployment_statuses.json +86 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_deployments.json +94 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_environments.json +31 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_gist_comments.json +38 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_gists.json +118 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_git_refs.json +59 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_installations.json +54 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_issue_comments.json +151 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_issue_events.json +606 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_issue_types.json +26 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_issues.json +758 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_labels.json +64 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_licenses.json +54 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_milestones.json +130 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_organization_memberships.json +139 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_organizations.json +38 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_pull_requests.json +874 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_release_assets.json +45 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_releases.json +92 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_repositories.json +797 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_repository_invitations.json +184 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_review_comments.json +66 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_reviews.json +138 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_secret_scanning_alerts.json +50 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_stargazers.json +88 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_tags.json +28 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_team_memberships.json +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_team_repositories.json +258 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_teams.json +130 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_users.json +174 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_webhooks.json +31 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_workflow_jobs.json +115 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_workflow_runs.json +1021 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scenarios/default/seed/github_workflows.json +30 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/scope.toml +501 -62
- package/runtime/gatewaysdk/environment/schema/connectors/github/tests/tools.json +79 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/vendor-openapi.json +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/github/world.json +14340 -4447
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/api/handlers.py +1413 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/connector.toml +630 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/handlers.py +136 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/scenarios/default/scenario.toml +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/scenarios/default/seed/10-gmail_profiles.json +10 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/scenarios/default/seed/20-gmail_labels.json +205 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/scenarios/default/seed/30-gmail_contacts.json +234 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/scenarios/default/seed/40-gmail_threads.json +374 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/scenarios/default/seed/50-gmail_messages.json +1015 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/scenarios/default/seed/60-gmail_message_parts.json +3039 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/scenarios/default/seed/70-gmail_attachments.json +28 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/scenarios/default/seed/80-gmail_drafts.json +39 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/scenarios/default/seed/90-gmail_client_settings.json +103 -0
- package/runtime/gatewaysdk/environment/schema/connectors/gmail/world.json +784 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/api/handlers.py +454 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/connector.toml +519 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/provenance.json +229 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/scenarios/default/instruction.md +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/scenarios/default/scenario.toml +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/scenarios/default/seed/10-calendar_calendars.json +75 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/scenarios/default/seed/20-calendar_calendar_list_entries.json +115 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/scenarios/default/seed/30-calendar_acl_rules.json +124 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/scenarios/default/seed/40-calendar_events.json +810 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/scenarios/default/seed/50-calendar_settings.json +76 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/scenarios/default/seed/60-calendar_channels.json +26 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/scenarios/default/seed/70-calendar_colors.json +48 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/scope.toml +105 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/tests/tools.json +53 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/vendor-openapi.json +4185 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-calendar/world.json +1255 -80
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/api/handlers.py +782 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/connector.toml +373 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/google-docs-types.json +4939 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/handlers.py +197 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/provenance.json +191 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/scenarios/default/instruction.md +29 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/scenarios/default/seed/gdocs_comments.json +50 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/scenarios/default/seed/gdocs_documents.json +8096 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/scenarios/default/seed/gdocs_files.json +1187 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/scenarios/default/seed/gdocs_permissions.json +543 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/scenarios/default/seed/gdocs_replies.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/scenarios/default/seed/gdocs_revisions.json +643 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/scenarios/default/seed/gdocs_users.json +32 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/scope.toml +148 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/tests/api.json +319 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/tests/tools.json +262 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/ui/static/assets/index-BH9fmZSS.css +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/ui/static/assets/index-CU4Fk9dX.js +67 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/ui/static/fonts/README.md +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/ui/static/fonts/google-sans-variable.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/ui/static/fonts/roboto-italic-variable-latin.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/ui/static/fonts/roboto-variable-latin-ext.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/ui/static/fonts/roboto-variable-latin.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/ui/static/icons/material_common_sprite1038_gm3_grey_medium.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/ui/static/index.html +13 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-docs/world.json +4489 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/api/handlers.py +466 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/connector.toml +626 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/handlers.py +42 -5
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/provenance.json +342 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scenarios/default/instruction.md +11 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scenarios/default/seed/drive_access_proposals.json +31 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scenarios/default/seed/drive_approvals.json +145 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scenarios/default/seed/drive_apps.json +81 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scenarios/default/seed/drive_comments.json +70 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scenarios/default/seed/drive_drives.json +71 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scenarios/default/seed/drive_files.json +700 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scenarios/default/seed/drive_labels.json +75 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scenarios/default/seed/drive_permissions.json +93 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scenarios/default/seed/drive_replies.json +66 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scenarios/default/seed/drive_revisions.json +82 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/scope.toml +126 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/tests/tools.json +101 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/vendor-openapi.json +6193 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-drive/world.json +1972 -108
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/api/handlers.py +1645 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/connector.toml +414 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/handlers.py +200 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/scenarios/default/seed/gsheets_cells.json +10252 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/scenarios/default/seed/gsheets_charts.json +103 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/scenarios/default/seed/gsheets_conditional_formats.json +138 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/scenarios/default/seed/gsheets_dimensions.json +256 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/scenarios/default/seed/gsheets_named_ranges.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/scenarios/default/seed/gsheets_permissions.json +31 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/scenarios/default/seed/gsheets_sheets.json +95 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/scenarios/default/seed/gsheets_spreadsheets.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/scenarios/default/seed/gsheets_view_states.json +26 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/tests/page.json +311 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/tests/vendor.json +843 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/ui/static/assets/index-CUpfKgm_.js +40 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/ui/static/assets/index-D3VhwBIC.css +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/ui/static/fonts/GoogleSans-400.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/ui/static/fonts/GoogleSans-500.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/ui/static/fonts/GoogleSans-700.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/ui/static/fonts/GoogleSansText-400.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/ui/static/fonts/GoogleSansText-500.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/ui/static/fonts/GoogleSansText-700.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/ui/static/fonts/Roboto-400.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/ui/static/fonts/Roboto-500.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/ui/static/fonts/Roboto-700.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/ui/static/index.html +26 -0
- package/runtime/gatewaysdk/environment/schema/connectors/google-sheets/world.json +4029 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/api/handlers.py +800 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/connector.toml +776 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/handlers.py +226 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/instruction.md +11 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_accounts.json +17 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_associations.json +1478 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_calls.json +147 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_companies.json +144 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_contacts.json +284 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_deals.json +204 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_emails.json +160 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_meetings.json +147 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_nav_items.json +204 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_notes.json +160 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_notifications.json +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_object_views.json +334 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_owners.json +76 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_pipeline_stages.json +109 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_pipelines.json +13 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_properties.json +1220 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_tasks.json +394 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/scenarios/default/seed/hubspot_tickets.json +34 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/assets/index-hdb5vB78.css +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/assets/index-xhg5ASqE.js +68 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/fonts/lexend-deca-300.ttf +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/fonts/lexend-deca-400.ttf +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/fonts/lexend-deca-500.ttf +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/fonts/lexend-deca-600.ttf +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/fonts/lexend-deca-700.ttf +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/fonts/lexend-deca-latin.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/add.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/avatar.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/bell.svg +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/breeze.svg +4 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/call.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/chevron-up.svg +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/companies.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/contact.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/contacts.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/date.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/deals.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/duplicate.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/export.svg +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/external-link.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/filter-lines.svg +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/frame-expand.svg +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/funnel.svg +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/help.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/hierarchy.svg +4 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/home.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/hubspot-logo.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/info.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/kanban.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/marketing-email.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/marketplace.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/meetings.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/more.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/pencil.svg +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/pin.svg +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/prospecting.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/refresh.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/search.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/settings.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/sidebar-collapse.svg +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/sort.svg +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/table.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/tasks.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/thumbs-down.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/thumbs-up.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/undo.svg +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/upgrade-arrow.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/vertical-dots.svg +5 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/icons/workflows.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/ui/static/index.html +37 -0
- package/runtime/gatewaysdk/environment/schema/connectors/hubspot/world.json +1347 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/api/handlers.py +987 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/connector.toml +3057 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/provenance.json +9443 -129
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/scenario.toml +4 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_account_groups.json +64 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_accounts.json +58 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_advanced_computer_searches.json +139 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_advanced_mobile_device_searches.json +61 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_advanced_user_content_searches.json +61 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_advanced_user_searches.json +124 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_api_integrations.json +37 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_api_roles.json +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_app_request_form_input_fields.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_buildings.json +34 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_byo_profiles.json +46 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_categories.json +19 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_classes.json +217 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_cloud_idps.json +19 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_computer_group_members.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_computer_groups.json +38 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_computer_invitations.json +82 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_computer_prestages.json +274 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_computers.json +1537 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_configuration_profiles.json +649 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_departments.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_device_enrollment_devices.json +70 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_device_enrollments.json +46 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_directory_bindings.json +34 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_disk_encryption_configurations.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_distribution_points.json +91 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_dock_items.json +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_ebooks.json +43 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_enrollment_customizations.json +43 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_extension_attributes.json +52 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_ibeacons.json +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_inventory_preload_records.json +100 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_ios_branding_configurations.json +31 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_ldap_servers.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_licensed_software_records.json +244 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_mac_applications.json +610 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_macos_branding_configurations.json +34 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_managed_software_update_plans.json +67 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_mdm_commands.json +58 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_mobile_device_applications.json +700 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_mobile_device_configuration_profiles.json +652 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_mobile_device_enrollment_profiles.json +160 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_mobile_device_extension_attributes.json +43 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_mobile_device_group_members.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_mobile_device_groups.json +38 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_mobile_device_prestages.json +280 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_mobile_device_provisioning_profiles.json +31 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_mobile_devices.json +1558 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_network_segments.json +46 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_packages.json +118 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_patch_software_title_configurations.json +88 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_policies.json +1054 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_printers.json +52 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_removable_mac_addresses.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_restricted_software_titles.json +289 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_return_to_service_configurations.json +19 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_scripts.json +61 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_sites.json +19 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_software_update_servers.json +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_supervision_identities.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_user_extension_attributes.json +31 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_user_groups.json +112 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_users.json +37 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_volume_purchasing_locations.json +106 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_volume_purchasing_subscriptions.json +76 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scenarios/default/seed/jamf_webhooks.json +70 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/scope.toml +839 -67
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/tests/tools.json +95 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/vendor-openapi.json +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jamf/world.json +10835 -1494
- package/runtime/gatewaysdk/environment/schema/connectors/jira/api/handlers.py +1056 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/connector.toml +955 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/handlers.py +73 -14
- package/runtime/gatewaysdk/environment/schema/connectors/jira/parity.json +27 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/provenance.json +166 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/instruction.md +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/scenario.toml +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_boards.json +61 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_changelogs.json +136 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_comments.json +205 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_components.json +78 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_fields.json +498 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_issue_link_types.json +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_issue_links.json +190 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_issue_types.json +44 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_issues.json +1448 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_priorities.json +40 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_project_categories.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_projects.json +111 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_resolutions.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_sprint_issues.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_sprints.json +39 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_status_categories.json +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_statuses.json +60 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_transitions.json +179 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_users.json +83 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_versions.json +30 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scenarios/default/seed/jira_worklogs.json +96 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/scope.toml +255 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/tests/tools.json +151 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/vendor-openapi.json +13562 -0
- package/runtime/gatewaysdk/environment/schema/connectors/jira/world.json +3381 -183
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/api/handlers.py +406 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/connector.toml +531 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/provenance.json +229 -46
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_blueprint_items.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_blueprint_template_categories.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_blueprint_templates.json +38 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_blueprints.json +52 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_custom_apps.json +45 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_custom_profiles.json +32 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_custom_scripts.json +27 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_device_activities.json +43 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_device_apps.json +52 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_device_commands.json +41 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_device_notes.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_device_parameters.json +28 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_device_tags.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_devices.json +122 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_in_house_apps.json +33 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_library_item_activities.json +33 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_library_item_statuses.json +98 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_library_items.json +24 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_self_service_categories.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_tags.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scenarios/default/seed/kandji_users.json +61 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/scope.toml +118 -39
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/tests/tools.json +64 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/vendor-openapi.json +5463 -0
- package/runtime/gatewaysdk/environment/schema/connectors/kandji/world.json +1257 -205
- package/runtime/gatewaysdk/environment/schema/connectors/linear/api/handlers.py +139 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/connector.toml +1574 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/handlers.py +8 -5
- package/runtime/gatewaysdk/environment/schema/connectors/linear/provenance.json +142 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/attachments.json +21 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/comments.json +79 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/customer_needs.json +21 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/customer_statuses.json +26 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/customer_tiers.json +26 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/customers.json +48 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/cycles.json +86 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/documents.json +27 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/initiative_projects.json +13 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/initiative_updates.json +23 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/initiatives.json +41 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/issue_labels.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/issue_relations.json +13 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/issues.json +264 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/labels.json +52 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/organizations.json +53 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/project_labels.json +34 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/project_members.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/project_milestones.json +30 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/project_relations.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/project_statuses.json +76 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/project_updates.json +42 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/projects.json +110 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/reactions.json +28 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/roadmap_projects.json +13 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/roadmaps.json +19 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/team_memberships.json +34 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/teams.json +114 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/templates.json +27 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/users.json +106 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/webhooks.json +21 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scenarios/default/seed/workflow_states.json +108 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/scope.toml +87 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/tests/tools.json +52 -0
- package/runtime/gatewaysdk/environment/schema/connectors/linear/world.json +5957 -172
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/api/handlers.py +1218 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/connector.toml +1246 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/fidelity.json +49 -19
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/provenance.json +785 -4
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/instruction.md +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_async_operations.json +47 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_channel_hosted_contents.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_channel_members.json +88 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_channel_messages.json +313 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_channel_replies.json +128 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_channels.json +319 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_chat_hosted_contents.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_chat_members.json +155 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_chat_messages.json +265 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_chat_views.json +37 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_chats.json +167 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_incoming_channels.json +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_pinned_messages.json +9 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_reply_hosted_contents.json +13 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_shared_channel_teams.json +32 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_tag_members.json +31 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_tags.json +32 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_team_members.json +117 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scenarios/default/seed/teams_teams.json +193 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/scope.md +76 -4
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/teams-types.json +29 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/tests/routes.json +101 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/vendor-openapi.json +11280 -0
- package/runtime/gatewaysdk/environment/schema/connectors/microsoft-teams/world.json +74 -6
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/api/handlers.py +571 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/connector.toml +1484 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/parity.json +28 -1
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/provenance.json +215 -49
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/instruction.md +11 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_accounting_periods.json +107 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_accounts.json +514 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_classifications.json +64 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_contacts.json +90 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_credit_memos.json +112 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_currencies.json +37 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_customer_payments.json +108 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_customers.json +232 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_departments.json +80 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_employees.json +124 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_invoices.json +229 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_item_fulfillments.json +85 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_items.json +237 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_journal_entries.json +217 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_locations.json +62 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_price_levels.json +28 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_purchase_orders.json +152 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_sales_order_lines.json +235 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_sales_orders.json +219 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_subsidiaries.json +85 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_terms.json +48 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_vendor_bills.json +170 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scenarios/default/seed/netsuite_vendors.json +140 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/scope.toml +251 -33
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/tests/tools.json +82 -0
- package/runtime/gatewaysdk/environment/schema/connectors/netsuite/world.json +31065 -8232
- package/runtime/gatewaysdk/environment/schema/connectors/notion/api/handlers.py +1330 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/connector.toml +386 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/handlers.py +54 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/scenarios/default/seed/blocks.json +4197 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/scenarios/default/seed/calendar_events.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/scenarios/default/seed/collection_views.json +175 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/scenarios/default/seed/comments.json +109 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/scenarios/default/seed/databases.json +417 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/scenarios/default/seed/favorites.json +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/scenarios/default/seed/notifications.json +49 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/scenarios/default/seed/pages.json +3758 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/scenarios/default/seed/spaces.json +28 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/scenarios/default/seed/teamspaces.json +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/scenarios/default/seed/users.json +92 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/tests/01-reads.json +165 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/assets/index-DQ36W7RG.css +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/assets/index-DythuuUy.js +67 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/avatars/eeee0000000000000000000000000002.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/avatars/eeee0000000000000000000000000003.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/avatars/eeee0000000000000000000000000004.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/avatars/eeee0000000000000000000000000005.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/avatars/eeee0000000000000000000000000006.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/avatars/eeee0000000000000000000000000007.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/avatars/eeee0000000000000000000000000008.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/covers/dusk-harbor.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/covers/ember-coast.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/covers/green-ridge.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f30a.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f331.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f373.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f3a7.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f3a8.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f3ac.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f3af.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f3c4.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f3d6.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f3e0.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f44b.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4a1.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4b0.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4bc.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4c5.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4c8.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4cb.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4ce.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4d1.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4d3.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4d6.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4da.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4dd.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4ec.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f4f7.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f527.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f55b.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f5c2.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f5d3.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f680.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f6a2.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f9ca.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f9e0.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f9ea.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f9ed.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1f9f0.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/1fab6.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/2600.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/2693.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/2705.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/2708.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/270f.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/emoji/2b50.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/favicon.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/fonts/SourceSerif4-latin.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/index.html +31 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/learn/content-blocks.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/learn/databases.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/learn/sharing.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/learn/style-content.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/photos/home-icon.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/photos/viewer.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/ui/static/photos/workspace.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/notion/world.json +2796 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_admin_role_assignments.json +44 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_app_assignments.json +40 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_app_group_assignments.json +59 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_applications.json +265 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_console_dashboards.json +91 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_device_users.json +32 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_devices.json +89 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_group_memberships.json +156 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_groups.json +100 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_orgs.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_policies.json +84 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_system_log_events.json +9656 -0
- package/runtime/gatewaysdk/environment/schema/connectors/okta/scenarios/default/seed/okta_users.json +744 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/api/handlers.py +624 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/connector.toml +381 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/handlers.py +54 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/provenance.json +408 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/scenarios/default/instruction.md +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/scenarios/default/seed/outlook_attachments.json +44 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/scenarios/default/seed/outlook_calendars.json +52 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/scenarios/default/seed/outlook_contacts.json +326 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/scenarios/default/seed/outlook_events.json +3050 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/scenarios/default/seed/outlook_mail_folders.json +84 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/scenarios/default/seed/outlook_mailbox_settings.json +35 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/scenarios/default/seed/outlook_mailboxes.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/scenarios/default/seed/outlook_messages.json +1400 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/scenarios/default/seed/outlook_system_senders.json +44 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/scenarios/default/seed/outlook_users.json +256 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/tests/routes.json +333 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/assets/index-DRVA5ahH.js +67 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/assets/index-kOnvVBhA.css +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/fonts/FluentSystemIcons-Filled.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/fonts/FluentSystemIcons-Regular.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/fonts/FluentSystemIcons-Resizable.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/fonts/controlIcons.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/fonts/segoeui-bold.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/fonts/segoeui-light.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/fonts/segoeui-regular.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/fonts/segoeui-semibold.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/fonts/segoeui-semilight.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/bookings.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/calendar.svg +35 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/copilot.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/excel.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/mail.svg +32 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/my-day.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/newsletters.svg +37 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/no-mail-selected-dark.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/no-mail-selected.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/onedrive.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/onenote.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/org-explorer.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/outlook.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/people.svg +34 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/powerpoint.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/ribbon-layout.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/sharepoint.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/teams-chat.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/teams.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/to-do.png +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/viva.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/img/word.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/ui/static/index.html +34 -0
- package/runtime/gatewaysdk/environment/schema/connectors/outlook/world.json +686 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/api/handlers.py +447 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/connector.toml +3478 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/handlers.py +695 -616
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/provenance.json +4254 -111
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/instruction.md +8 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_account_contact_relations.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_account_contact_roles.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_account_partners.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_account_team_members.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_accounts.json +38 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_assets.json +35 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_attachments.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_business_hours.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_campaign_member_statuses.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_campaign_members.json +38 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_campaigns.json +35 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_case_comments.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_case_histories.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_case_milestones.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_case_statuses.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_case_team_members.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_case_team_roles.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_cases.json +42 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_collaboration_group_members.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_collaboration_groups.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_contact_point_addresses.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_contact_point_emails.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_contact_point_phones.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_contacts.json +34 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_content_document_links.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_content_documents.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_content_folders.json +13 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_content_notes.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_content_versions.json +24 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_content_workspaces.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_contract_contact_roles.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_contract_line_items.json +32 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_contracts.json +40 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_dashboards.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_documents.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_email_message_relations.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_email_messages.json +21 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_email_templates.json +24 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_entitlements.json +32 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_events.json +26 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_feed_comments.json +19 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_feed_items.json +24 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_fiscal_year_settings.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_folders.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_group_members.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_groups.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_holidays.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_individuals.json +21 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_lead_statuses.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_leads.json +45 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_list_views.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_login_histories.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_milestone_types.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_notes.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_object_territory_associations.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_opportunities.json +48 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_opportunity_competitors.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_opportunity_contact_roles.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_opportunity_field_histories.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_opportunity_histories.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_opportunity_line_items.json +32 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_opportunity_partners.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_opportunity_stages.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_opportunity_team_members.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_order_items.json +33 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_orders.json +44 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_organizations.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_partners.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_periods.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_permission_set_assignments.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_permission_sets.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_pricebook_entries.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_pricebooks.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_products.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_profiles.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_queue_sobjects.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_quote_line_items.json +43 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_quotes.json +40 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_record_actions.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_record_types.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_reports.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_service_contracts.json +32 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_sla_processes.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_solutions.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_task_priorities.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_task_relations.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_task_statuses.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_tasks.json +26 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_territories.json +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_territory_models.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_territory_types.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_topic_assignments.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_topics.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_user_roles.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_user_territory_associations.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_users.json +57 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_web_links.json +26 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_work_order_line_items.json +42 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scenarios/default/seed/sf_work_orders.json +46 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/scope.toml +624 -104
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/tests/tools.json +69 -0
- package/runtime/gatewaysdk/environment/schema/connectors/salesforce/world.json +19222 -2654
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/api/handlers.py +630 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/connector.toml +266 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/handlers.py +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/provenance.json +245 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/instruction.md +15 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/scenario.toml +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/10-snow_users.json +268 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/11-snow_user_groups.json +40 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/20-snow_configuration_items.json +684 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/30-snow_catalog_categories.json +52 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/31-snow_catalog_items.json +334 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/40-snow_incidents.json +3086 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/41-snow_incident_tasks.json +54 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/42-snow_task_slas.json +64 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/43-snow_problems.json +148 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/44-snow_change_requests.json +364 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/45-snow_knowledge_articles.json +214 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/46-snow_journal_entries.json +1612 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/60-snow_ui_current_users.json +19 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/61-snow_ui_navigation_applications.json +187 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/62-snow_ui_home_widgets.json +91 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/63-snow_ui_notifications.json +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/64-snow_ui_employee_center_pages.json +74 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/65-snow_ui_list_layouts.json +54 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/66-snow_ui_search_facets.json +29 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/67-snow_ui_activity_entries.json +1076 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scenarios/default/seed/68-snow_ui_instances.json +9 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/scope.toml +166 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/tests/routes.json +272 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/assets/index-5QHcQLCI.css +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/assets/index-BzeVnzFt.js +67 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/cabin-400-700-italic.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/cabin-400-700.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-0-lato-v17-latin-ext_latin-100.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-1-lato-v17-latin-ext_latin-100.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-10-lato-v17-latin-ext_latin-italic.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-11-lato-v17-latin-ext_latin-italic.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-12-lato-v17-latin-ext_latin-700.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-13-lato-v17-latin-ext_latin-700.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-14-lato-v17-latin-ext_latin-700italic.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-15-lato-v17-latin-ext_latin-700italic.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-16-source-sans-pro-v11-latin-300.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-17-source-sans-pro-v11-latin-300.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-18-source-sans-pro-v11-latin-regular.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-19-source-sans-pro-v11-latin-regular.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-2-lato-v17-latin-ext_latin-100italic.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-20-source-sans-pro-v11-latin-600.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-21-source-sans-pro-v11-latin-600.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-22-source-sans-pro-v11-latin-700.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-23-source-sans-pro-v11-latin-700.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-3-lato-v17-latin-ext_latin-100italic.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-4-lato-v17-latin-ext_latin-300.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-5-lato-v17-latin-ext_latin-300.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-6-lato-v17-latin-ext_latin-300italic.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-7-lato-v17-latin-ext_latin-300italic.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-8-lato-v17-latin-ext_latin-regular.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/font-9-lato-v17-latin-ext_latin-regular.woff +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/index.json +122 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/lato-300.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/lato-600-italic.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/lato-600.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/lato-bold-italic.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/lato-bold.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/lato-normal-italic.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/fonts/lato-normal.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/appsee-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/arrow-up-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/available.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/bell-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/caret-down-fill.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/check-fill.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/chevron-right-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/circle-close-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/circle-info-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/circle-question-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/circleinfooutline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/ellipsis-v-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/eye-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-bell-fill.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-caret-down-fill.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-check-square.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-chevron-right.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-clock-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-comment-chat.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-external-link.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-facebook.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-heart-fill.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-heart-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-home-fill-teal.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-home-fill.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-linkedin.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-list-alt-fill.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-pencil-square.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-question-circle-fill.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-times.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/fa-twitter.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/filter-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/gear-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/globe-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/home-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/icon-2.svg +17 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/icon-3.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/icon-4.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/icon.svg +45 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/keyboard-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/link-icon-associated-to-view-all-adoption-blueprints.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/link-icon-associated-to-view-all-applications.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/list-fill.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/loading-2.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/loading.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/magnifying-glass-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/ongoing-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/open-link-right-fill.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/open-link-right-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/pencil-page-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/plus-fill.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/serverbox-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/servicenow-wordmark.svg +20 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/signal-live-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/square-arrow-left-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/star-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/sync-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/task-slas-related-list.svg +24 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/thumbtack-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/trending-downward.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/trending-neutral.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/unpinned-all-menu.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/unpinned-favorites-menu.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/unpinned-history-menu.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/icons/user-outline.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/adoption-blueprints.svg +40 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/avatar-admin.jpg +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/now-assist-admin.svg +17 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/quick-link-desk.jpg +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/quick-link-password.jpg +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/quick-link-status.jpg +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/topic-accessories.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/topic-computers.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/topic-developer.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/topic-email.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/topic-phone.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/topic-software-catalog.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/topic-software.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/img/topic-technology.svg +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/ui/static/index.html +36 -0
- package/runtime/gatewaysdk/environment/schema/connectors/servicenow/world.json +2004 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/MODEL.md +28 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/api/handlers.py +1880 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/capabilities.json +19 -2
- package/runtime/gatewaysdk/environment/schema/connectors/slack/connector.toml +892 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/provenance.json +65 -10
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/scenario.toml +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_apps.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_bookmarks.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_bots.json +19 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_channels.json +206 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_conversation_states.json +50 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_emojis.json +19 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_ephemeral_message_files.json +12 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_ephemeral_message_threads.json +11 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_ephemeral_messages.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_file_channel_observations.json +16 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_file_reaction_summaries.json +10 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_file_reaction_users.json +10 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_file_shares.json +29 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_file_user_states.json +10 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_files.json +64 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_memberships.json +79 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_message_files.json +18 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_message_threads.json +10 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_message_user_states.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_messages.json +127 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_pins.json +11 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_presence.json +35 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_reaction_summaries.json +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_reaction_users.json +32 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_scheduled_message_threads.json +10 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_scheduled_messages.json +15 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_unavailable_message_files.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_user_profile_fields.json +28 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_usergroup_channels.json +10 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_usergroup_memberships.json +14 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_usergroups.json +33 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_users.json +228 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_view_state_entries.json +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_views.json +53 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scenarios/default/seed/slack_workspaces.json +37 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/scope.toml +6 -2
- package/runtime/gatewaysdk/environment/schema/connectors/slack/tests/api.json +177 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/tests/test_threads.py +49 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/tests/tools.json +92 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/assets/index-BSqGskph.css +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/assets/index-CKQh1igo.js +81 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/fonts/README.md +15 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/fonts/lato-black.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/fonts/lato-bold.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/fonts/lato-italic-black.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/fonts/lato-italic-bold.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/fonts/lato-italic-light.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/fonts/lato-italic.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/fonts/lato-light.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/fonts/lato-regular.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/fonts/slack-icons-v2.woff2 +0 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/ui/static/index.html +35 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/vendor-openapi.json +12515 -0
- package/runtime/gatewaysdk/environment/schema/connectors/slack/world.json +396 -8
- package/runtime/gatewaysdk/environment/schema/connectors/workday/api/handlers.py +175 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/connector.toml +610 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/parity.json +39 -6
- package/runtime/gatewaysdk/environment/schema/connectors/workday/provenance.json +253 -25
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/instruction.md +10 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/scenario.toml +2 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_compensations.json +219 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_job_profiles.json +76 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_locations.json +142 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_organizations.json +124 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_positions.json +280 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_absence_leaves.json +66 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_business_title_changes.json +44 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_check_in_topics.json +48 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_check_ins.json +46 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_countries.json +28 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_currencies.json +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_job_change_reasons.json +28 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_job_families.json +40 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_job_profiles.json +202 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_jobs.json +120 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_organization_types.json +19 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_organizations.json +24 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_persons.json +100 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_scorecard_results.json +57 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_scorecards.json +68 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_supervisory_organizations.json +64 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_time_off_details.json +112 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_time_off_entries.json +91 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_worker_history_events.json +58 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_rest_workers.json +90 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_time_off_requests.json +181 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scenarios/default/seed/workday_workers.json +492 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/scope.toml +178 -14
- package/runtime/gatewaysdk/environment/schema/connectors/workday/tests/tools.json +81 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/vendor-openapi.json +10646 -0
- package/runtime/gatewaysdk/environment/schema/connectors/workday/world.json +3787 -407
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/api/handlers.py +1183 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/connector.toml +645 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/handlers.py +377 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/instruction.md +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/scenario.toml +3 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/seed/zendesk_brands.json +25 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/seed/zendesk_group_memberships.json +49 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/seed/zendesk_groups.json +37 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/seed/zendesk_macros.json +154 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/seed/zendesk_organizations.json +65 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/seed/zendesk_ticket_audits.json +3328 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/seed/zendesk_ticket_comments.json +2642 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/seed/zendesk_tickets.json +1439 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/seed/zendesk_users.json +624 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/seed/zendesk_views.json +510 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/scenarios/default/seed/zendesk_workspace_tabs.json +10 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/ui/static/assets/index-JWq7XNO5.css +1 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/ui/static/assets/index-bn8ezNTi.js +67 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/ui/static/index.html +22 -0
- package/runtime/gatewaysdk/environment/schema/connectors/zendesk/world.json +1707 -0
- package/runtime/gatewaysdk/environment/schema/data.py +349 -35
- package/runtime/gatewaysdk/environment/schema/dependencies.py +235 -0
- package/runtime/gatewaysdk/environment/schema/extract.py +6 -6
- package/runtime/gatewaysdk/environment/schema/host.py +226 -62
- package/runtime/gatewaysdk/environment/schema/host_surfaces.py +62 -17
- package/runtime/gatewaysdk/environment/schema/ingest.py +528 -0
- package/runtime/gatewaysdk/environment/schema/local.py +536 -0
- package/runtime/gatewaysdk/environment/schema/mapping.py +944 -0
- package/runtime/gatewaysdk/environment/schema/platform.py +678 -202
- package/runtime/gatewaysdk/environment/schema/reconcile.py +202 -0
- package/runtime/gatewaysdk/environment/schema/redaction.py +378 -0
- package/runtime/gatewaysdk/environment/schema/scaffold.py +68 -7
- package/runtime/gatewaysdk/environment/schema/skill.py +1 -0
- package/runtime/gatewaysdk/environment/schema/skills/benchmarks-getting-started/SKILL.md +391 -0
- package/runtime/gatewaysdk/environment/schema/skills/connector-schema-authoring/CONNECTORS.md +64 -31
- package/runtime/gatewaysdk/environment/schema/skills/connector-schema-authoring/SKILL.md +86 -36
- package/runtime/gatewaysdk/environment/schema/skills/world-data-ingestion/ROWS.md +20 -0
- package/runtime/gatewaysdk/environment/schema/skills/world-data-ingestion/SKILL.md +178 -11
- package/runtime/gatewaysdk/environment/schema/skills/worlds-getting-started/SKILL.md +184 -74
- package/runtime/gatewaysdk/environment/schema/skills/worlds-getting-started/references/cli-mcp-map.md +49 -0
- package/runtime/gatewaysdk/environment/schema/skills/worlds-getting-started/references/ui-map.md +18 -0
- package/runtime/gatewaysdk/environment/schema/store.py +103 -3
- package/runtime/gatewaysdk/environment/schema/tasks.py +8 -3
- package/runtime/gatewaysdk/environment/schema/tools_world.py +424 -57
- package/runtime/gatewaysdk/environment/schema/transform.py +200 -0
- package/runtime/gatewaysdk/environment/schema/transforms.py +103 -0
- package/runtime/gatewaysdk/environment/schema/ui.py +455 -0
- package/runtime/gatewaysdk/environment/schema/ui_static/app.js +581 -0
- package/runtime/gatewaysdk/environment/schema/ui_static/index.html +72 -0
- package/runtime/gatewaysdk/environment/schema/validation.py +59 -12
- package/runtime/gatewaysdk/environment/schema/world_tests.py +245 -51
- package/skills/benchmarks-getting-started/SKILL.md +391 -0
- package/skills/connector-schema-authoring/CONNECTORS.md +64 -31
- package/skills/connector-schema-authoring/SKILL.md +86 -36
- package/skills/connector-schema-authoring/connector-worlds.md +355 -0
- package/skills/connector-schema-authoring/world-schema.md +620 -0
- package/skills/world-data-ingestion/ROWS.md +20 -0
- package/skills/world-data-ingestion/SKILL.md +178 -11
- package/skills/worlds-getting-started/SKILL.md +184 -74
- package/skills/worlds-getting-started/references/cli-mcp-map.md +49 -0
- package/skills/worlds-getting-started/references/ui-map.md +18 -0
package/dist/worlds/index.js
CHANGED
|
@@ -38,9 +38,9 @@ function surfaceKinds(s) {
|
|
|
38
38
|
if (s.browser) kinds.push("browser");
|
|
39
39
|
return kinds;
|
|
40
40
|
}
|
|
41
|
-
function uiUrl(ui,
|
|
41
|
+
function uiUrl(ui, path8) {
|
|
42
42
|
const base = ui.url.replace(/\/+$/, "");
|
|
43
|
-
const rel =
|
|
43
|
+
const rel = path8.startsWith("/") ? path8 : `/${path8}`;
|
|
44
44
|
if (!ui.token) return base + rel;
|
|
45
45
|
const [beforeHash, hash] = splitHash(rel);
|
|
46
46
|
const joiner = beforeHash.includes("?") ? "&" : "?";
|
|
@@ -124,12 +124,12 @@ async function openBrowser(surfaces, opts = {}) {
|
|
|
124
124
|
function computerUseToolkit(browser, opts = {}) {
|
|
125
125
|
const maxText = opts.maxText ?? 2e4;
|
|
126
126
|
const observe = async (selector = "body") => {
|
|
127
|
-
const
|
|
127
|
+
const text2 = await browser.text(selector);
|
|
128
128
|
return {
|
|
129
129
|
url: browser.url,
|
|
130
130
|
title: await browser.title(),
|
|
131
|
-
text:
|
|
132
|
-
truncated:
|
|
131
|
+
text: text2.slice(0, maxText),
|
|
132
|
+
truncated: text2.length > maxText
|
|
133
133
|
};
|
|
134
134
|
};
|
|
135
135
|
const impls = {
|
|
@@ -213,8 +213,8 @@ var init_browser = __esm({
|
|
|
213
213
|
}
|
|
214
214
|
resolveBase() {
|
|
215
215
|
if (this.base === null) {
|
|
216
|
-
const
|
|
217
|
-
this.base =
|
|
216
|
+
const resolve6 = this.opts.resumeFrom ?? (async () => 0);
|
|
217
|
+
this.base = resolve6().then((n) => {
|
|
218
218
|
if (!Number.isInteger(n) || n < 0)
|
|
219
219
|
throw new Error(
|
|
220
220
|
`browser event base seq must be a non-negative integer, got ${String(n)}`
|
|
@@ -415,11 +415,11 @@ var init_browser = __esm({
|
|
|
415
415
|
await this.settle();
|
|
416
416
|
});
|
|
417
417
|
}
|
|
418
|
-
async type(selector,
|
|
418
|
+
async type(selector, text2) {
|
|
419
419
|
await this.act(
|
|
420
420
|
"browser_type",
|
|
421
|
-
{ selector, text },
|
|
422
|
-
() => this.page.fill(selector,
|
|
421
|
+
{ selector, text: text2 },
|
|
422
|
+
() => this.page.fill(selector, text2)
|
|
423
423
|
);
|
|
424
424
|
}
|
|
425
425
|
async press(key) {
|
|
@@ -722,6 +722,11 @@ var init_session = __esm({
|
|
|
722
722
|
get taskName() {
|
|
723
723
|
return this.current.taskName;
|
|
724
724
|
}
|
|
725
|
+
/** The platform's notices about the world this session runs on (empty
|
|
726
|
+
* for a schema world). Printed by the CLI on stderr at open. */
|
|
727
|
+
get deprecations() {
|
|
728
|
+
return this.current.deprecations ?? [];
|
|
729
|
+
}
|
|
725
730
|
/** The task this session runs: bundled scenario, stored task or inline
|
|
726
731
|
* spec, its name, hash and the caller's metadata. */
|
|
727
732
|
get taskInfo() {
|
|
@@ -753,20 +758,20 @@ var init_session = __esm({
|
|
|
753
758
|
}
|
|
754
759
|
/** Base URL of the world's own HTTP API for this session. */
|
|
755
760
|
async api() {
|
|
756
|
-
const { api } = await this.surfaces();
|
|
757
|
-
if (!
|
|
761
|
+
const { api: api2 } = await this.surfaces();
|
|
762
|
+
if (!api2)
|
|
758
763
|
throw new WorldSurfaceUnavailable(
|
|
759
764
|
"api",
|
|
760
765
|
"open the session with surfaces: ['api'] on an api-type world"
|
|
761
766
|
);
|
|
762
|
-
return
|
|
767
|
+
return api2.url;
|
|
763
768
|
}
|
|
764
769
|
/** Headers every request to `api()` needs. A World Host session gates its
|
|
765
770
|
* api surface on a per-session token; a pod or hosted twin answers with the
|
|
766
771
|
* world's own declared auth and this is `{}`. */
|
|
767
772
|
async apiHeaders() {
|
|
768
|
-
const { api } = await this.surfaces();
|
|
769
|
-
return
|
|
773
|
+
const { api: api2 } = await this.surfaces();
|
|
774
|
+
return api2?.token ? { Authorization: `Bearer ${api2.token}` } : {};
|
|
770
775
|
}
|
|
771
776
|
/** URL of the world's UI entry page for this session. */
|
|
772
777
|
async ui() {
|
|
@@ -795,18 +800,18 @@ var init_session = __esm({
|
|
|
795
800
|
}
|
|
796
801
|
/** The reporter `browser()` uses; exposed for a page you drive yourself. */
|
|
797
802
|
browserRecorder(agentId) {
|
|
798
|
-
const
|
|
803
|
+
const path8 = `/api/public/world-sessions/${encodeURIComponent(this.sessionId)}/browser-events`;
|
|
799
804
|
const id = agentId ?? process.env.GATEWAY_AGENT_ID ?? `agent-${(0, import_node_crypto.randomUUID)().replace(/-/g, "").slice(0, 8)}`;
|
|
800
805
|
return new BrowserActionRecorder(
|
|
801
806
|
async (events) => {
|
|
802
|
-
await apiRequest(this.options, "POST",
|
|
807
|
+
await apiRequest(this.options, "POST", path8, { events });
|
|
803
808
|
},
|
|
804
809
|
id,
|
|
805
810
|
{
|
|
806
811
|
// Continue this agent's timeline where the platform has it, so the
|
|
807
812
|
// same id reopened later never re-numbers from zero.
|
|
808
813
|
resumeFrom: async () => {
|
|
809
|
-
const summary = await apiRequest(this.options, "GET",
|
|
814
|
+
const summary = await apiRequest(this.options, "GET", path8);
|
|
810
815
|
return summary.agents.find((a) => a.agentId === id)?.nextSeq ?? 0;
|
|
811
816
|
}
|
|
812
817
|
}
|
|
@@ -863,7 +868,7 @@ var init_session = __esm({
|
|
|
863
868
|
const { callId } = enqueued;
|
|
864
869
|
const judged = enqueued.pending === true;
|
|
865
870
|
const budgetMs = timeoutMs ?? (judged ? JUDGED_GRADE_TIMEOUT_MS : CALL_TIMEOUT_MS);
|
|
866
|
-
const
|
|
871
|
+
const pollMs2 = judged ? JUDGED_GRADE_POLL_MS : CALL_POLL_MS;
|
|
867
872
|
const deadline = Date.now() + budgetMs;
|
|
868
873
|
for (; ; ) {
|
|
869
874
|
const call = await apiRequest(
|
|
@@ -879,7 +884,7 @@ var init_session = __esm({
|
|
|
879
884
|
throw new WorldSessionTimeout(
|
|
880
885
|
judged ? `Grade ${callId} still ${call.state} after ${Math.round(budgetMs / 1e3)}s \u2014 the judge has not answered; the platform finalizes the call on its own, read it back with export().` : `Call ${callId} still ${call.state} after ${Math.round(budgetMs / 1e3)}s \u2014 the container may have died.`
|
|
881
886
|
);
|
|
882
|
-
await sleep(
|
|
887
|
+
await sleep(pollMs2);
|
|
883
888
|
}
|
|
884
889
|
}
|
|
885
890
|
/**
|
|
@@ -954,8 +959,12 @@ var init_session = __esm({
|
|
|
954
959
|
*/
|
|
955
960
|
async seed(rows, opts = {}) {
|
|
956
961
|
const mode = opts.mode ?? "append";
|
|
962
|
+
const redact = opts.redact ?? "off";
|
|
957
963
|
return await this.exchange(
|
|
958
|
-
{
|
|
964
|
+
{
|
|
965
|
+
kind: "seed",
|
|
966
|
+
args: { mode, rows, ...redact !== "off" ? { redact } : {} }
|
|
967
|
+
},
|
|
959
968
|
opts.timeoutMs
|
|
960
969
|
);
|
|
961
970
|
}
|
|
@@ -1126,6 +1135,22 @@ var init_tasks = __esm({
|
|
|
1126
1135
|
});
|
|
1127
1136
|
|
|
1128
1137
|
// src/worlds/hub.ts
|
|
1138
|
+
var hub_exports = {};
|
|
1139
|
+
__export(hub_exports, {
|
|
1140
|
+
DEFAULT_BRANCH: () => DEFAULT_BRANCH,
|
|
1141
|
+
buildSourceTarball: () => buildSourceTarball,
|
|
1142
|
+
collectArchiveRelPaths: () => collectArchiveRelPaths,
|
|
1143
|
+
computeContentHash: () => computeContentHash,
|
|
1144
|
+
createRef: () => createRef,
|
|
1145
|
+
isIncludedInContentHash: () => isIncludedInContentHash,
|
|
1146
|
+
localTreeState: () => localTreeState,
|
|
1147
|
+
propose: () => propose,
|
|
1148
|
+
pull: () => pull,
|
|
1149
|
+
push: () => push,
|
|
1150
|
+
readLocalMeta: () => readLocalMeta,
|
|
1151
|
+
snapshotTreeHashes: () => snapshotTreeHashes,
|
|
1152
|
+
writeLocalMeta: () => writeLocalMeta
|
|
1153
|
+
});
|
|
1129
1154
|
function isExcludedDirComponent(component) {
|
|
1130
1155
|
return component.startsWith(".") || ROOT_EXCLUDED_DIRS.has(component) || component.endsWith(".egg-info");
|
|
1131
1156
|
}
|
|
@@ -1259,8 +1284,8 @@ function localTreeState(dir) {
|
|
|
1259
1284
|
}
|
|
1260
1285
|
function readPyproject(dir) {
|
|
1261
1286
|
try {
|
|
1262
|
-
const
|
|
1263
|
-
const section = /\[project\]([\s\S]*?)(\n\[|$)/.exec(
|
|
1287
|
+
const text2 = fs.readFileSync(path.join(dir, "pyproject.toml"), "utf-8");
|
|
1288
|
+
const section = /\[project\]([\s\S]*?)(\n\[|$)/.exec(text2)?.[1] ?? "";
|
|
1264
1289
|
const name = /\bname\s*=\s*"([^"]+)"/.exec(section)?.[1];
|
|
1265
1290
|
const version = /\bversion\s*=\s*"([^"]+)"/.exec(section)?.[1];
|
|
1266
1291
|
return { name, version };
|
|
@@ -1268,6 +1293,17 @@ function readPyproject(dir) {
|
|
|
1268
1293
|
return {};
|
|
1269
1294
|
}
|
|
1270
1295
|
}
|
|
1296
|
+
function readWorldContractVersion(dir) {
|
|
1297
|
+
for (const rel of ["schema/world.json", path.join("server", "world", "schema", "world.json")]) {
|
|
1298
|
+
try {
|
|
1299
|
+
const parsed = JSON.parse(fs.readFileSync(path.join(dir, rel), "utf-8"));
|
|
1300
|
+
const pkg = parsed["x-gateway"]?.package;
|
|
1301
|
+
if (pkg?.version) return { name: pkg.id, version: pkg.version };
|
|
1302
|
+
} catch {
|
|
1303
|
+
}
|
|
1304
|
+
}
|
|
1305
|
+
return {};
|
|
1306
|
+
}
|
|
1271
1307
|
function buildFileManifest(dir) {
|
|
1272
1308
|
const entries = [];
|
|
1273
1309
|
const walk = (rel) => {
|
|
@@ -1313,8 +1349,10 @@ async function push(dir, opts = {}) {
|
|
|
1313
1349
|
const baseVersionId = opts.baseVersionId ?? localMeta.versionId ?? null;
|
|
1314
1350
|
const contentHash = computeContentHash(dir);
|
|
1315
1351
|
const pyproject = readPyproject(dir);
|
|
1352
|
+
const contractVersion = pyproject.version ? void 0 : readWorldContractVersion(dir).version;
|
|
1353
|
+
if (contractVersion) pyproject.version = contractVersion;
|
|
1316
1354
|
const slug = opts.slug ?? pyproject.name ?? path.basename(path.resolve(dir));
|
|
1317
|
-
const
|
|
1355
|
+
const resolve6 = await apiRequest(
|
|
1318
1356
|
options,
|
|
1319
1357
|
"POST",
|
|
1320
1358
|
"/api/public/benchmark-containers/resolve",
|
|
@@ -1329,7 +1367,7 @@ async function push(dir, opts = {}) {
|
|
|
1329
1367
|
const tarball = buildSourceTarball(dir);
|
|
1330
1368
|
const bundleSha256 = sha256b64(tarball);
|
|
1331
1369
|
const version = await apiRequest(options, "POST", "/api/public/benchmark-containers/versions", {
|
|
1332
|
-
containerId:
|
|
1370
|
+
containerId: resolve6.containerId,
|
|
1333
1371
|
contentHash,
|
|
1334
1372
|
bundleSha256,
|
|
1335
1373
|
bundleSizeBytes: tarball.length,
|
|
@@ -1362,7 +1400,7 @@ async function push(dir, opts = {}) {
|
|
|
1362
1400
|
baseFiles: snapshotTreeHashes(dir)
|
|
1363
1401
|
});
|
|
1364
1402
|
return {
|
|
1365
|
-
containerId:
|
|
1403
|
+
containerId: resolve6.containerId,
|
|
1366
1404
|
slug,
|
|
1367
1405
|
versionId: version.versionId,
|
|
1368
1406
|
contentHash,
|
|
@@ -1689,6 +1727,1756 @@ var init_validate = __esm({
|
|
|
1689
1727
|
}
|
|
1690
1728
|
});
|
|
1691
1729
|
|
|
1730
|
+
// src/worlds/describe.ts
|
|
1731
|
+
async function describeWorld(slug, options = {}) {
|
|
1732
|
+
if (slug.includes("@"))
|
|
1733
|
+
throw new Error(
|
|
1734
|
+
`describeWorld reads a world's head version: pass the slug without @ref (got ${slug})`
|
|
1735
|
+
);
|
|
1736
|
+
return apiRequest(
|
|
1737
|
+
options,
|
|
1738
|
+
"GET",
|
|
1739
|
+
`/api/public/worlds/${encodeURIComponent(slug)}`
|
|
1740
|
+
);
|
|
1741
|
+
}
|
|
1742
|
+
var init_describe = __esm({
|
|
1743
|
+
"src/worlds/describe.ts"() {
|
|
1744
|
+
"use strict";
|
|
1745
|
+
init_worlds();
|
|
1746
|
+
}
|
|
1747
|
+
});
|
|
1748
|
+
|
|
1749
|
+
// src/cli/platform/worldData/json.ts
|
|
1750
|
+
function parseJson(text2) {
|
|
1751
|
+
const p = new Parser(text2);
|
|
1752
|
+
p.skipWs();
|
|
1753
|
+
const value = p.value();
|
|
1754
|
+
p.skipWs();
|
|
1755
|
+
if (p.i < text2.length) throw new JsonSyntaxError(`Extra data at ${p.i}`);
|
|
1756
|
+
return value;
|
|
1757
|
+
}
|
|
1758
|
+
function dumps(value) {
|
|
1759
|
+
if (value === null) return "null";
|
|
1760
|
+
if (value === true) return "true";
|
|
1761
|
+
if (value === false) return "false";
|
|
1762
|
+
if (typeof value === "string") return JSON.stringify(value);
|
|
1763
|
+
if (value instanceof JsonNumber) return numberText(value);
|
|
1764
|
+
if (Array.isArray(value)) return "[" + value.map(dumps).join(",") + "]";
|
|
1765
|
+
const parts = [];
|
|
1766
|
+
for (const [key, item] of value) parts.push(JSON.stringify(key) + ":" + dumps(item));
|
|
1767
|
+
return "{" + parts.join(",") + "}";
|
|
1768
|
+
}
|
|
1769
|
+
function numberText(n) {
|
|
1770
|
+
if (!n.isFloat) return /^-0+$/.test(n.text) ? "0" : n.text;
|
|
1771
|
+
const value = n.value;
|
|
1772
|
+
if (Number.isNaN(value)) return "NaN";
|
|
1773
|
+
if (value === Infinity) return "Infinity";
|
|
1774
|
+
if (value === -Infinity) return "-Infinity";
|
|
1775
|
+
return pyFloatRepr(value);
|
|
1776
|
+
}
|
|
1777
|
+
function pyFloatRepr(x) {
|
|
1778
|
+
if (x === 0) return Object.is(x, -0) ? "-0.0" : "0.0";
|
|
1779
|
+
const sign = x < 0 ? "-" : "";
|
|
1780
|
+
const js = String(Math.abs(x));
|
|
1781
|
+
const [mantissa, exponentPart] = js.split("e");
|
|
1782
|
+
let exponent = exponentPart ? Number(exponentPart) : 0;
|
|
1783
|
+
const [intPart, fracPart = ""] = mantissa.split(".");
|
|
1784
|
+
let digits = intPart + fracPart;
|
|
1785
|
+
let decpt = intPart.length + exponent;
|
|
1786
|
+
const leading = digits.match(/^0*/)[0].length;
|
|
1787
|
+
digits = digits.slice(leading);
|
|
1788
|
+
decpt -= leading;
|
|
1789
|
+
digits = digits.replace(/0+$/, "");
|
|
1790
|
+
if (digits === "") return sign + "0.0";
|
|
1791
|
+
const sci = decpt - 1;
|
|
1792
|
+
if (sci >= -4 && sci < 16) {
|
|
1793
|
+
if (decpt <= 0) return sign + "0." + "0".repeat(-decpt) + digits;
|
|
1794
|
+
if (decpt >= digits.length) return sign + digits + "0".repeat(decpt - digits.length) + ".0";
|
|
1795
|
+
return sign + digits.slice(0, decpt) + "." + digits.slice(decpt);
|
|
1796
|
+
}
|
|
1797
|
+
exponent = sci;
|
|
1798
|
+
const mag = String(Math.abs(exponent)).padStart(2, "0");
|
|
1799
|
+
return sign + digits[0] + (digits.length > 1 ? "." + digits.slice(1) : "") + "e" + (exponent < 0 ? "-" : "+") + mag;
|
|
1800
|
+
}
|
|
1801
|
+
function pyRound(n, ndigits) {
|
|
1802
|
+
if (!n.isFloat) return n;
|
|
1803
|
+
const x = n.value;
|
|
1804
|
+
if (!Number.isFinite(x)) return n;
|
|
1805
|
+
const sign = x < 0 ? -1 : 1;
|
|
1806
|
+
const magnitude = Math.abs(x);
|
|
1807
|
+
if (magnitude >= 9007199254740992) return new JsonNumber(pyFloatRepr(x));
|
|
1808
|
+
const { m, k } = exactFraction(magnitude);
|
|
1809
|
+
let rounded;
|
|
1810
|
+
if (k <= ndigits) rounded = magnitude;
|
|
1811
|
+
else if (k !== ndigits + 1) rounded = Number(magnitude.toFixed(ndigits));
|
|
1812
|
+
else {
|
|
1813
|
+
const scaled = m * 5n ** BigInt(k);
|
|
1814
|
+
let kept = scaled / 10n;
|
|
1815
|
+
if (kept % 2n === 1n) kept += 1n;
|
|
1816
|
+
const text2 = kept.toString().padStart(ndigits + 1, "0");
|
|
1817
|
+
rounded = ndigits === 0 ? Number(text2) : Number(text2.slice(0, -ndigits) + "." + text2.slice(-ndigits));
|
|
1818
|
+
}
|
|
1819
|
+
return new JsonNumber(pyFloatRepr(sign * rounded));
|
|
1820
|
+
}
|
|
1821
|
+
function exactFraction(x) {
|
|
1822
|
+
if (x === 0) return { m: 0n, k: 0 };
|
|
1823
|
+
const view = new DataView(new ArrayBuffer(8));
|
|
1824
|
+
view.setFloat64(0, x);
|
|
1825
|
+
const bits = view.getBigUint64(0);
|
|
1826
|
+
const exponent = Number(bits >> 52n & 0x7ffn);
|
|
1827
|
+
let mantissa = bits & (1n << 52n) - 1n;
|
|
1828
|
+
let e;
|
|
1829
|
+
if (exponent === 0) e = -1074;
|
|
1830
|
+
else {
|
|
1831
|
+
mantissa |= 1n << 52n;
|
|
1832
|
+
e = exponent - 1075;
|
|
1833
|
+
}
|
|
1834
|
+
while (mantissa !== 0n && (mantissa & 1n) === 0n) {
|
|
1835
|
+
mantissa >>= 1n;
|
|
1836
|
+
e += 1;
|
|
1837
|
+
}
|
|
1838
|
+
if (e >= 0) return { m: mantissa << BigInt(e), k: 0 };
|
|
1839
|
+
return { m: mantissa, k: -e };
|
|
1840
|
+
}
|
|
1841
|
+
var JsonNumber, JsonSyntaxError, Parser, isDigit;
|
|
1842
|
+
var init_json = __esm({
|
|
1843
|
+
"src/cli/platform/worldData/json.ts"() {
|
|
1844
|
+
"use strict";
|
|
1845
|
+
JsonNumber = class {
|
|
1846
|
+
/** The lexeme as it appeared, e.g. "1.0", "-0", "1e21". */
|
|
1847
|
+
constructor(text2) {
|
|
1848
|
+
this.text = text2;
|
|
1849
|
+
}
|
|
1850
|
+
/** A float in Python's eyes: a fraction, an exponent, or a non-finite literal. */
|
|
1851
|
+
get isFloat() {
|
|
1852
|
+
return /[.eE]/.test(this.text) || /[nN]/.test(this.text);
|
|
1853
|
+
}
|
|
1854
|
+
get value() {
|
|
1855
|
+
return Number(this.text);
|
|
1856
|
+
}
|
|
1857
|
+
};
|
|
1858
|
+
JsonSyntaxError = class extends Error {
|
|
1859
|
+
};
|
|
1860
|
+
Parser = class {
|
|
1861
|
+
constructor(s) {
|
|
1862
|
+
this.s = s;
|
|
1863
|
+
}
|
|
1864
|
+
i = 0;
|
|
1865
|
+
skipWs() {
|
|
1866
|
+
const s = this.s;
|
|
1867
|
+
while (this.i < s.length) {
|
|
1868
|
+
const c = s.charCodeAt(this.i);
|
|
1869
|
+
if (c === 32 || c === 10 || c === 13 || c === 9) this.i++;
|
|
1870
|
+
else break;
|
|
1871
|
+
}
|
|
1872
|
+
}
|
|
1873
|
+
fail(what) {
|
|
1874
|
+
throw new JsonSyntaxError(`${what} at ${this.i}`);
|
|
1875
|
+
}
|
|
1876
|
+
value() {
|
|
1877
|
+
const s = this.s;
|
|
1878
|
+
if (this.i >= s.length) this.fail("Expecting value");
|
|
1879
|
+
const c = s[this.i];
|
|
1880
|
+
if (c === "{") return this.object();
|
|
1881
|
+
if (c === "[") return this.array();
|
|
1882
|
+
if (c === '"') return this.string();
|
|
1883
|
+
if (c === "t") return this.literal("true", true);
|
|
1884
|
+
if (c === "f") return this.literal("false", false);
|
|
1885
|
+
if (c === "n") return this.literal("null", null);
|
|
1886
|
+
if (c === "N") return this.literal("NaN", new JsonNumber("NaN"));
|
|
1887
|
+
if (c === "I") return this.literal("Infinity", new JsonNumber("Infinity"));
|
|
1888
|
+
return this.number();
|
|
1889
|
+
}
|
|
1890
|
+
literal(word, value) {
|
|
1891
|
+
if (!this.s.startsWith(word, this.i)) this.fail("Expecting value");
|
|
1892
|
+
this.i += word.length;
|
|
1893
|
+
return value;
|
|
1894
|
+
}
|
|
1895
|
+
number() {
|
|
1896
|
+
const s = this.s;
|
|
1897
|
+
const start = this.i;
|
|
1898
|
+
if (s[this.i] === "-") {
|
|
1899
|
+
this.i++;
|
|
1900
|
+
if (s.startsWith("Infinity", this.i)) {
|
|
1901
|
+
this.i += 8;
|
|
1902
|
+
return new JsonNumber("-Infinity");
|
|
1903
|
+
}
|
|
1904
|
+
}
|
|
1905
|
+
const intStart = this.i;
|
|
1906
|
+
if (s[this.i] === "0") this.i++;
|
|
1907
|
+
else {
|
|
1908
|
+
while (this.i < s.length && isDigit(s.charCodeAt(this.i))) this.i++;
|
|
1909
|
+
if (this.i === intStart) this.fail("Expecting value");
|
|
1910
|
+
}
|
|
1911
|
+
if (s[this.i] === ".") {
|
|
1912
|
+
this.i++;
|
|
1913
|
+
const fracStart = this.i;
|
|
1914
|
+
while (this.i < s.length && isDigit(s.charCodeAt(this.i))) this.i++;
|
|
1915
|
+
if (this.i === fracStart) this.fail("Invalid number");
|
|
1916
|
+
}
|
|
1917
|
+
if (s[this.i] === "e" || s[this.i] === "E") {
|
|
1918
|
+
this.i++;
|
|
1919
|
+
if (s[this.i] === "+" || s[this.i] === "-") this.i++;
|
|
1920
|
+
const expStart = this.i;
|
|
1921
|
+
while (this.i < s.length && isDigit(s.charCodeAt(this.i))) this.i++;
|
|
1922
|
+
if (this.i === expStart) this.fail("Invalid number");
|
|
1923
|
+
}
|
|
1924
|
+
return new JsonNumber(s.slice(start, this.i));
|
|
1925
|
+
}
|
|
1926
|
+
string() {
|
|
1927
|
+
const s = this.s;
|
|
1928
|
+
this.i++;
|
|
1929
|
+
let out = "";
|
|
1930
|
+
let runStart = this.i;
|
|
1931
|
+
for (; ; ) {
|
|
1932
|
+
if (this.i >= s.length) this.fail("Unterminated string");
|
|
1933
|
+
const c = s.charCodeAt(this.i);
|
|
1934
|
+
if (c === 34) {
|
|
1935
|
+
out += s.slice(runStart, this.i);
|
|
1936
|
+
this.i++;
|
|
1937
|
+
return out;
|
|
1938
|
+
}
|
|
1939
|
+
if (c < 32) this.fail("Invalid control character");
|
|
1940
|
+
if (c !== 92) {
|
|
1941
|
+
this.i++;
|
|
1942
|
+
continue;
|
|
1943
|
+
}
|
|
1944
|
+
out += s.slice(runStart, this.i);
|
|
1945
|
+
this.i++;
|
|
1946
|
+
const e = s[this.i];
|
|
1947
|
+
switch (e) {
|
|
1948
|
+
case '"':
|
|
1949
|
+
case "\\":
|
|
1950
|
+
case "/":
|
|
1951
|
+
out += e;
|
|
1952
|
+
break;
|
|
1953
|
+
case "b":
|
|
1954
|
+
out += "\b";
|
|
1955
|
+
break;
|
|
1956
|
+
case "f":
|
|
1957
|
+
out += "\f";
|
|
1958
|
+
break;
|
|
1959
|
+
case "n":
|
|
1960
|
+
out += "\n";
|
|
1961
|
+
break;
|
|
1962
|
+
case "r":
|
|
1963
|
+
out += "\r";
|
|
1964
|
+
break;
|
|
1965
|
+
case "t":
|
|
1966
|
+
out += " ";
|
|
1967
|
+
break;
|
|
1968
|
+
case "u": {
|
|
1969
|
+
const hex2 = s.slice(this.i + 1, this.i + 5);
|
|
1970
|
+
if (!/^[0-9a-fA-F]{4}$/.test(hex2)) this.fail("Invalid \\u escape");
|
|
1971
|
+
out += String.fromCharCode(parseInt(hex2, 16));
|
|
1972
|
+
this.i += 4;
|
|
1973
|
+
break;
|
|
1974
|
+
}
|
|
1975
|
+
default:
|
|
1976
|
+
this.fail("Invalid escape");
|
|
1977
|
+
}
|
|
1978
|
+
this.i++;
|
|
1979
|
+
runStart = this.i;
|
|
1980
|
+
}
|
|
1981
|
+
}
|
|
1982
|
+
array() {
|
|
1983
|
+
this.i++;
|
|
1984
|
+
const out = [];
|
|
1985
|
+
this.skipWs();
|
|
1986
|
+
if (this.s[this.i] === "]") {
|
|
1987
|
+
this.i++;
|
|
1988
|
+
return out;
|
|
1989
|
+
}
|
|
1990
|
+
for (; ; ) {
|
|
1991
|
+
this.skipWs();
|
|
1992
|
+
out.push(this.value());
|
|
1993
|
+
this.skipWs();
|
|
1994
|
+
const c = this.s[this.i];
|
|
1995
|
+
if (c === ",") {
|
|
1996
|
+
this.i++;
|
|
1997
|
+
continue;
|
|
1998
|
+
}
|
|
1999
|
+
if (c === "]") {
|
|
2000
|
+
this.i++;
|
|
2001
|
+
return out;
|
|
2002
|
+
}
|
|
2003
|
+
this.fail("Expecting ',' delimiter");
|
|
2004
|
+
}
|
|
2005
|
+
}
|
|
2006
|
+
object() {
|
|
2007
|
+
this.i++;
|
|
2008
|
+
const out = /* @__PURE__ */ new Map();
|
|
2009
|
+
this.skipWs();
|
|
2010
|
+
if (this.s[this.i] === "}") {
|
|
2011
|
+
this.i++;
|
|
2012
|
+
return out;
|
|
2013
|
+
}
|
|
2014
|
+
for (; ; ) {
|
|
2015
|
+
this.skipWs();
|
|
2016
|
+
if (this.s[this.i] !== '"') this.fail("Expecting property name enclosed in double quotes");
|
|
2017
|
+
const key = this.string();
|
|
2018
|
+
this.skipWs();
|
|
2019
|
+
if (this.s[this.i] !== ":") this.fail("Expecting ':' delimiter");
|
|
2020
|
+
this.i++;
|
|
2021
|
+
this.skipWs();
|
|
2022
|
+
out.set(key, this.value());
|
|
2023
|
+
this.skipWs();
|
|
2024
|
+
const c = this.s[this.i];
|
|
2025
|
+
if (c === ",") {
|
|
2026
|
+
this.i++;
|
|
2027
|
+
continue;
|
|
2028
|
+
}
|
|
2029
|
+
if (c === "}") {
|
|
2030
|
+
this.i++;
|
|
2031
|
+
return out;
|
|
2032
|
+
}
|
|
2033
|
+
this.fail("Expecting ',' delimiter");
|
|
2034
|
+
}
|
|
2035
|
+
}
|
|
2036
|
+
};
|
|
2037
|
+
isDigit = (c) => c >= 48 && c <= 57;
|
|
2038
|
+
}
|
|
2039
|
+
});
|
|
2040
|
+
|
|
2041
|
+
// src/worlds/transforms.ts
|
|
2042
|
+
function parseTransform(name) {
|
|
2043
|
+
const simple = Object.prototype.hasOwnProperty.call(SIMPLE, name) ? SIMPLE[name] : void 0;
|
|
2044
|
+
if (simple) return simple;
|
|
2045
|
+
const colon = name.indexOf(":");
|
|
2046
|
+
if (colon !== -1) {
|
|
2047
|
+
const head = name.slice(0, colon);
|
|
2048
|
+
const prefix = name.slice(colon + 1);
|
|
2049
|
+
if (head === STRIP_PREFIX && prefix && !prefix.includes(",")) return stripPrefix(prefix);
|
|
2050
|
+
}
|
|
2051
|
+
throw new Error(`Unknown transform '${name}'; choose one of ${TRANSFORMS.join(", ")}`);
|
|
2052
|
+
}
|
|
2053
|
+
function applyTransforms(value, chain) {
|
|
2054
|
+
const steps = chain.map(parseTransform);
|
|
2055
|
+
let out = text(value);
|
|
2056
|
+
for (const step of steps) out = step(out);
|
|
2057
|
+
return out;
|
|
2058
|
+
}
|
|
2059
|
+
var import_node_crypto3, WHITESPACE, WHITESPACE_EDGES, WHITESPACE_RUN, NOT_DIGIT, STRIP_PREFIX, trim, emailLocalPart, emailDomain, stripPrefix, hex, SIMPLE, TRANSFORMS, text;
|
|
2060
|
+
var init_transforms = __esm({
|
|
2061
|
+
"src/worlds/transforms.ts"() {
|
|
2062
|
+
"use strict";
|
|
2063
|
+
import_node_crypto3 = require("crypto");
|
|
2064
|
+
init_json();
|
|
2065
|
+
WHITESPACE = " \n\r\f\v";
|
|
2066
|
+
WHITESPACE_EDGES = /^[ \t\n\r\f\v]+|[ \t\n\r\f\v]+$/g;
|
|
2067
|
+
WHITESPACE_RUN = /[ \t\n\r\f\v]+/g;
|
|
2068
|
+
NOT_DIGIT = /[^0-9]/g;
|
|
2069
|
+
STRIP_PREFIX = "strip_prefix";
|
|
2070
|
+
trim = (value) => value.replace(WHITESPACE_EDGES, "");
|
|
2071
|
+
emailLocalPart = (value) => {
|
|
2072
|
+
const at = value.lastIndexOf("@");
|
|
2073
|
+
return at === -1 ? value : value.slice(0, at);
|
|
2074
|
+
};
|
|
2075
|
+
emailDomain = (value) => {
|
|
2076
|
+
const at = value.lastIndexOf("@");
|
|
2077
|
+
return at === -1 ? "" : value.slice(at + 1).toLowerCase();
|
|
2078
|
+
};
|
|
2079
|
+
stripPrefix = (prefix) => (value) => value.startsWith(prefix) ? value.slice(prefix.length) : value;
|
|
2080
|
+
hex = (algorithm, value) => (0, import_node_crypto3.createHash)(algorithm).update(value, "utf8").digest("hex");
|
|
2081
|
+
SIMPLE = {
|
|
2082
|
+
lower: (value) => value.toLowerCase(),
|
|
2083
|
+
upper: (value) => value.toUpperCase(),
|
|
2084
|
+
trim,
|
|
2085
|
+
collapse_ws: (value) => trim(value).replace(WHITESPACE_RUN, " "),
|
|
2086
|
+
nfkc: (value) => value.normalize("NFKC"),
|
|
2087
|
+
digits: (value) => value.replace(NOT_DIGIT, ""),
|
|
2088
|
+
email_local_part: emailLocalPart,
|
|
2089
|
+
email_domain: emailDomain,
|
|
2090
|
+
// Vendor-style digests: lowercase hex of the utf-8 bytes, unsalted. This is
|
|
2091
|
+
// how SpyCloud accepts a hashed selector (`_digests` in its api_handlers).
|
|
2092
|
+
sha1: (value) => hex("sha1", value),
|
|
2093
|
+
sha256: (value) => hex("sha256", value)
|
|
2094
|
+
};
|
|
2095
|
+
TRANSFORMS = [...Object.keys(SIMPLE), `${STRIP_PREFIX}:<prefix>`];
|
|
2096
|
+
text = (value) => {
|
|
2097
|
+
if (typeof value === "string") return value;
|
|
2098
|
+
return Number.isInteger(value) ? String(value) : pyFloatRepr(value);
|
|
2099
|
+
};
|
|
2100
|
+
}
|
|
2101
|
+
});
|
|
2102
|
+
|
|
2103
|
+
// src/worlds/redaction.ts
|
|
2104
|
+
function pyText(value) {
|
|
2105
|
+
if (typeof value === "string") return value;
|
|
2106
|
+
if (Number.isInteger(value)) return String(value);
|
|
2107
|
+
if (Number.isNaN(value)) return "nan";
|
|
2108
|
+
if (!Number.isFinite(value)) return value > 0 ? "inf" : "-inf";
|
|
2109
|
+
return pyFloatRepr(value);
|
|
2110
|
+
}
|
|
2111
|
+
function hashForm(slug, plaintext) {
|
|
2112
|
+
return "sha256:" + (0, import_node_crypto4.createHash)("sha256").update(`${slug}:${pyText(plaintext)}`, "utf8").digest("hex");
|
|
2113
|
+
}
|
|
2114
|
+
function preserveForm(slug, plaintext) {
|
|
2115
|
+
const kind = typeof plaintext === "string" ? "str" : isInt(plaintext) ? "int" : "float";
|
|
2116
|
+
const shaped = shapeText(slug, pyText(plaintext), kind);
|
|
2117
|
+
return kind === "str" ? shaped : Number(shaped);
|
|
2118
|
+
}
|
|
2119
|
+
function shapeText(slug, text2, kind) {
|
|
2120
|
+
const seed = Buffer.from(`${slug}:${text2}`, "utf8");
|
|
2121
|
+
let digest = (0, import_node_crypto4.createHash)("sha256").update(seed).digest();
|
|
2122
|
+
let cursor = 0;
|
|
2123
|
+
const out = [];
|
|
2124
|
+
for (const char of text2) {
|
|
2125
|
+
if (cursor === digest.length) {
|
|
2126
|
+
digest = (0, import_node_crypto4.createHash)("sha256").update(Buffer.concat([digest, seed])).digest();
|
|
2127
|
+
cursor = 0;
|
|
2128
|
+
}
|
|
2129
|
+
const byte = digest[cursor];
|
|
2130
|
+
cursor += 1;
|
|
2131
|
+
if (char >= "0" && char <= "9") out.push(String(byte % 10));
|
|
2132
|
+
else if (kind === "str" && char >= "a" && char <= "z") out.push(String.fromCharCode(97 + byte % 26));
|
|
2133
|
+
else if (kind === "str" && char >= "A" && char <= "Z") out.push(String.fromCharCode(65 + byte % 26));
|
|
2134
|
+
else out.push(char);
|
|
2135
|
+
}
|
|
2136
|
+
if (kind === "int" && out.length > 1 && out[0] === "0") out[0] = String(1 + digest[0] % 9);
|
|
2137
|
+
return out.join("");
|
|
2138
|
+
}
|
|
2139
|
+
function roundForm(plaintext, decimals) {
|
|
2140
|
+
if (typeof plaintext === "string" || isInt(plaintext) || !Number.isFinite(plaintext)) return plaintext;
|
|
2141
|
+
return pyRound(new JsonNumber(pyFloatRepr(plaintext)), decimals).value;
|
|
2142
|
+
}
|
|
2143
|
+
function redactionOf(redact, field) {
|
|
2144
|
+
if (!redact) return null;
|
|
2145
|
+
const named = (names) => (names ?? []).some((name) => name === field || name.slice(name.lastIndexOf(".") + 1) === field);
|
|
2146
|
+
if (named(redact.drop)) return "drop";
|
|
2147
|
+
if (named(redact.hash)) return "hash";
|
|
2148
|
+
if (named(redact.preserve)) return "preserve";
|
|
2149
|
+
const decimals = redact.round?.[field];
|
|
2150
|
+
if (typeof decimals === "number") return `round:${decimals}`;
|
|
2151
|
+
return null;
|
|
2152
|
+
}
|
|
2153
|
+
function storedForms(world, field, plaintext, transform) {
|
|
2154
|
+
if (transform?.length) plaintext = applyTransforms(plaintext, transform);
|
|
2155
|
+
const policy = redactionOf(world.redact, field);
|
|
2156
|
+
const salt = world.redact?.slug ?? world.slug;
|
|
2157
|
+
if (policy === "drop") return [];
|
|
2158
|
+
if (policy === "hash") return [hashForm(salt, plaintext)];
|
|
2159
|
+
if (policy === "preserve") return [preserveForm(salt, plaintext)];
|
|
2160
|
+
if (policy !== null) return [roundForm(plaintext, world.redact.round[field])];
|
|
2161
|
+
return [plaintext];
|
|
2162
|
+
}
|
|
2163
|
+
var import_node_crypto4, isInt;
|
|
2164
|
+
var init_redaction = __esm({
|
|
2165
|
+
"src/worlds/redaction.ts"() {
|
|
2166
|
+
"use strict";
|
|
2167
|
+
import_node_crypto4 = require("crypto");
|
|
2168
|
+
init_json();
|
|
2169
|
+
init_transforms();
|
|
2170
|
+
isInt = (value) => typeof value === "number" && Number.isInteger(value);
|
|
2171
|
+
}
|
|
2172
|
+
});
|
|
2173
|
+
|
|
2174
|
+
// src/worlds/query.ts
|
|
2175
|
+
function queryRowsSearch(entity, opts = {}) {
|
|
2176
|
+
const search = new URLSearchParams();
|
|
2177
|
+
search.set("entity", entity);
|
|
2178
|
+
if (opts.where && Object.keys(opts.where).length) search.set("where", JSON.stringify(opts.where));
|
|
2179
|
+
if (opts.limit !== void 0) search.set("limit", String(opts.limit));
|
|
2180
|
+
if (opts.offset !== void 0) search.set("offset", String(opts.offset));
|
|
2181
|
+
if (opts.resolve) search.set("resolve", "true");
|
|
2182
|
+
if (opts.across) search.set("across", "true");
|
|
2183
|
+
if (opts.compare) search.set("compare", "true");
|
|
2184
|
+
return `?${search.toString()}`;
|
|
2185
|
+
}
|
|
2186
|
+
async function queryRows(slug, entity, opts = {}, options = {}) {
|
|
2187
|
+
if (slug.includes("@"))
|
|
2188
|
+
throw new Error(
|
|
2189
|
+
`queryRows reads a world's head version: pass the slug without @ref (got ${slug})`
|
|
2190
|
+
);
|
|
2191
|
+
if (!entity) throw new Error("queryRows needs an entity");
|
|
2192
|
+
if (opts.compare && !opts.across) throw new Error("queryRows: compare needs across");
|
|
2193
|
+
return apiRequest(
|
|
2194
|
+
options,
|
|
2195
|
+
"GET",
|
|
2196
|
+
`/api/public/worlds/${encodeURIComponent(slug)}/data${queryRowsSearch(entity, opts)}`
|
|
2197
|
+
);
|
|
2198
|
+
}
|
|
2199
|
+
var init_query = __esm({
|
|
2200
|
+
"src/worlds/query.ts"() {
|
|
2201
|
+
"use strict";
|
|
2202
|
+
init_worlds();
|
|
2203
|
+
}
|
|
2204
|
+
});
|
|
2205
|
+
|
|
2206
|
+
// src/worlds/migrate.ts
|
|
2207
|
+
async function migrateWorld(slug, input = {}, options = {}) {
|
|
2208
|
+
if (slug.includes("@"))
|
|
2209
|
+
throw new Error(
|
|
2210
|
+
`migrateWorld converts a world's head version: pass the slug without @ref (got ${slug})`
|
|
2211
|
+
);
|
|
2212
|
+
return apiRequest(
|
|
2213
|
+
options,
|
|
2214
|
+
"POST",
|
|
2215
|
+
`/api/public/worlds/${encodeURIComponent(slug)}/migrate`,
|
|
2216
|
+
{
|
|
2217
|
+
...input.apply === void 0 ? {} : { apply: input.apply },
|
|
2218
|
+
...input.force === void 0 ? {} : { force: input.force }
|
|
2219
|
+
}
|
|
2220
|
+
);
|
|
2221
|
+
}
|
|
2222
|
+
async function migrateProjectWorlds(input = {}, options = {}) {
|
|
2223
|
+
return apiRequest(
|
|
2224
|
+
options,
|
|
2225
|
+
"POST",
|
|
2226
|
+
"/api/public/worlds/migrate",
|
|
2227
|
+
input.apply === void 0 ? {} : { apply: input.apply }
|
|
2228
|
+
);
|
|
2229
|
+
}
|
|
2230
|
+
var init_migrate = __esm({
|
|
2231
|
+
"src/worlds/migrate.ts"() {
|
|
2232
|
+
"use strict";
|
|
2233
|
+
init_worlds();
|
|
2234
|
+
}
|
|
2235
|
+
});
|
|
2236
|
+
|
|
2237
|
+
// src/cli/router.ts
|
|
2238
|
+
var CliError;
|
|
2239
|
+
var init_router = __esm({
|
|
2240
|
+
"src/cli/router.ts"() {
|
|
2241
|
+
"use strict";
|
|
2242
|
+
CliError = class extends Error {
|
|
2243
|
+
constructor(message, exitCode = 2) {
|
|
2244
|
+
super(message);
|
|
2245
|
+
this.exitCode = exitCode;
|
|
2246
|
+
}
|
|
2247
|
+
};
|
|
2248
|
+
}
|
|
2249
|
+
});
|
|
2250
|
+
|
|
2251
|
+
// src/cli/config.ts
|
|
2252
|
+
async function api(creds, method, route, body, init = {}) {
|
|
2253
|
+
const controller = new AbortController();
|
|
2254
|
+
const timer = setTimeout(() => controller.abort(), init.timeoutMs ?? 12e4);
|
|
2255
|
+
try {
|
|
2256
|
+
const res = await fetch(`${creds.host}${route}`, {
|
|
2257
|
+
method,
|
|
2258
|
+
headers: {
|
|
2259
|
+
"content-type": "application/json",
|
|
2260
|
+
accept: "application/json",
|
|
2261
|
+
authorization: "Basic " + Buffer.from(`${creds.publicKey}:${creds.secretKey}`).toString("base64")
|
|
2262
|
+
},
|
|
2263
|
+
...body === void 0 ? {} : { body: JSON.stringify(body) },
|
|
2264
|
+
signal: controller.signal
|
|
2265
|
+
});
|
|
2266
|
+
const text2 = await res.text();
|
|
2267
|
+
if (!res.ok) throw new ApiError(res.status, method, route, text2);
|
|
2268
|
+
return text2 ? JSON.parse(text2) : {};
|
|
2269
|
+
} finally {
|
|
2270
|
+
clearTimeout(timer);
|
|
2271
|
+
}
|
|
2272
|
+
}
|
|
2273
|
+
var fs2, os, path2, ApiError;
|
|
2274
|
+
var init_config = __esm({
|
|
2275
|
+
"src/cli/config.ts"() {
|
|
2276
|
+
"use strict";
|
|
2277
|
+
fs2 = __toESM(require("fs"));
|
|
2278
|
+
os = __toESM(require("os"));
|
|
2279
|
+
path2 = __toESM(require("path"));
|
|
2280
|
+
init_router();
|
|
2281
|
+
ApiError = class extends CliError {
|
|
2282
|
+
constructor(status, method, route, text2) {
|
|
2283
|
+
super(`${method} ${route} -> ${status}: ${text2.slice(0, 600)}`, 1);
|
|
2284
|
+
this.status = status;
|
|
2285
|
+
this.method = method;
|
|
2286
|
+
this.route = route;
|
|
2287
|
+
this.text = text2;
|
|
2288
|
+
}
|
|
2289
|
+
};
|
|
2290
|
+
}
|
|
2291
|
+
});
|
|
2292
|
+
|
|
2293
|
+
// src/cli/runtime/local.ts
|
|
2294
|
+
function tailOf(output) {
|
|
2295
|
+
return output.length > DIAGNOSTIC_TAIL ? `\u2026${output.slice(-DIAGNOSTIC_TAIL)}` : output;
|
|
2296
|
+
}
|
|
2297
|
+
function runtimeMode() {
|
|
2298
|
+
const raw = (process.env.GATEWAY_RUNTIME ?? "auto").toLowerCase();
|
|
2299
|
+
if (raw === "local" || raw === "platform" || raw === "auto") return raw;
|
|
2300
|
+
throw new CliError(
|
|
2301
|
+
`GATEWAY_RUNTIME must be local, platform or auto (got ${raw})`
|
|
2302
|
+
);
|
|
2303
|
+
}
|
|
2304
|
+
function runtimeRoot() {
|
|
2305
|
+
const candidates = [];
|
|
2306
|
+
if (process.env.GATEWAY_RUNTIME_PATH)
|
|
2307
|
+
candidates.push(process.env.GATEWAY_RUNTIME_PATH);
|
|
2308
|
+
const entry = process.argv[1] && fs3.existsSync(process.argv[1]) ? path3.dirname(fs3.realpathSync(process.argv[1])) : null;
|
|
2309
|
+
if (entry) {
|
|
2310
|
+
candidates.push(path3.resolve(entry, "..", "runtime"));
|
|
2311
|
+
candidates.push(path3.resolve(entry, "..", "..", "runtime"));
|
|
2312
|
+
candidates.push(path3.resolve(entry, "..", "..", "sdk", "src"));
|
|
2313
|
+
}
|
|
2314
|
+
candidates.push(path3.resolve(process.cwd(), "runtime"));
|
|
2315
|
+
for (const root of candidates)
|
|
2316
|
+
if (fs3.existsSync(
|
|
2317
|
+
path3.join(root, "gatewaysdk", "environment", "schema", "platform.py")
|
|
2318
|
+
))
|
|
2319
|
+
return root;
|
|
2320
|
+
return null;
|
|
2321
|
+
}
|
|
2322
|
+
function probeVersion(name) {
|
|
2323
|
+
const probe = (0, import_node_child_process.spawnSync)(
|
|
2324
|
+
name,
|
|
2325
|
+
["-c", "import sys;print(sys.version_info[0],sys.version_info[1])"],
|
|
2326
|
+
{ encoding: "utf8", timeout: 1e4 }
|
|
2327
|
+
);
|
|
2328
|
+
if (probe.status !== 0) return null;
|
|
2329
|
+
const [major, minor] = probe.stdout.trim().split(/\s+/).map(Number);
|
|
2330
|
+
return Number.isInteger(major) && Number.isInteger(minor) ? `${major}.${minor}` : null;
|
|
2331
|
+
}
|
|
2332
|
+
function atLeastMinimum(version) {
|
|
2333
|
+
const [major, minor] = version.split(".").map(Number);
|
|
2334
|
+
return major > MIN_PYTHON[0] || major === MIN_PYTHON[0] && minor >= MIN_PYTHON[1];
|
|
2335
|
+
}
|
|
2336
|
+
function uvPython() {
|
|
2337
|
+
const found = (0, import_node_child_process.spawnSync)("uv", UV_FIND, { encoding: "utf8", timeout: 1e4 });
|
|
2338
|
+
if (found.status !== 0) return null;
|
|
2339
|
+
const line = found.stdout.trim().split(/\r?\n/)[0] ?? "";
|
|
2340
|
+
return line || null;
|
|
2341
|
+
}
|
|
2342
|
+
function findPython() {
|
|
2343
|
+
if (pythonCache !== void 0) return pythonCache;
|
|
2344
|
+
const named = process.env.GATEWAY_PYTHON;
|
|
2345
|
+
const candidates = named ? [named] : PYTHON_CANDIDATES;
|
|
2346
|
+
for (const name of candidates) {
|
|
2347
|
+
const version = probeVersion(name);
|
|
2348
|
+
pythonProbes.push({ name, version });
|
|
2349
|
+
if (version && atLeastMinimum(version)) {
|
|
2350
|
+
pythonCache = name;
|
|
2351
|
+
return name;
|
|
2352
|
+
}
|
|
2353
|
+
}
|
|
2354
|
+
if (!named) {
|
|
2355
|
+
const fromUv = uvPython();
|
|
2356
|
+
const version = fromUv ? probeVersion(fromUv) : null;
|
|
2357
|
+
pythonProbes.push({ name: fromUv ?? "uv python find", version });
|
|
2358
|
+
if (fromUv && version && atLeastMinimum(version)) {
|
|
2359
|
+
pythonCache = fromUv;
|
|
2360
|
+
return fromUv;
|
|
2361
|
+
}
|
|
2362
|
+
}
|
|
2363
|
+
pythonCache = null;
|
|
2364
|
+
return null;
|
|
2365
|
+
}
|
|
2366
|
+
function pythonAdvice() {
|
|
2367
|
+
findPython();
|
|
2368
|
+
const floor = MIN_PYTHON.join(".");
|
|
2369
|
+
const named = process.env.GATEWAY_PYTHON;
|
|
2370
|
+
const seen = pythonProbes.filter((probe) => probe.version).map((probe) => `${probe.name} is ${probe.version}`);
|
|
2371
|
+
const found = seen.length ? seen.join(", ") : named ? `${named} did not run` : "none on PATH";
|
|
2372
|
+
return `No python3 >= ${floor} usable (${found}); set GATEWAY_PYTHON to a newer interpreter, e.g. GATEWAY_PYTHON="$(brew --prefix python@3.12)/bin/python3.12" or GATEWAY_PYTHON="$(uv python find 3.12)".`;
|
|
2373
|
+
}
|
|
2374
|
+
function localRuntimeReason() {
|
|
2375
|
+
if (runtimeMode() === "platform")
|
|
2376
|
+
return "GATEWAY_RUNTIME=platform forces the hosted side.";
|
|
2377
|
+
if (!findPython()) return pythonAdvice();
|
|
2378
|
+
if (!runtimeRoot())
|
|
2379
|
+
return "The bundled runtime is missing (set GATEWAY_RUNTIME_PATH).";
|
|
2380
|
+
return "";
|
|
2381
|
+
}
|
|
2382
|
+
function localRuntime() {
|
|
2383
|
+
if (runtimeMode() === "platform") return null;
|
|
2384
|
+
const python = findPython();
|
|
2385
|
+
const root = runtimeRoot();
|
|
2386
|
+
if (!python || !root) {
|
|
2387
|
+
if (runtimeMode() === "local")
|
|
2388
|
+
throw new CliError(
|
|
2389
|
+
!python ? `GATEWAY_RUNTIME=local but ${pythonAdvice()}` : "GATEWAY_RUNTIME=local but the bundled runtime is missing (set GATEWAY_RUNTIME_PATH)"
|
|
2390
|
+
);
|
|
2391
|
+
return null;
|
|
2392
|
+
}
|
|
2393
|
+
return { python, root };
|
|
2394
|
+
}
|
|
2395
|
+
function localPythonHasYaml(python) {
|
|
2396
|
+
return (0, import_node_child_process.spawnSync)(python, ["-c", "import yaml"], { timeout: 1e4 }).status === 0;
|
|
2397
|
+
}
|
|
2398
|
+
async function localBridge(request, local, opts = {}) {
|
|
2399
|
+
const input = JSON.stringify(request);
|
|
2400
|
+
return await new Promise((resolve6, reject) => {
|
|
2401
|
+
const child = (0, import_node_child_process.spawn)(
|
|
2402
|
+
local.python,
|
|
2403
|
+
["-I", "-B", "-c", BRIDGE_BOOTSTRAP, local.root],
|
|
2404
|
+
{
|
|
2405
|
+
stdio: ["pipe", "pipe", "pipe"],
|
|
2406
|
+
// This is the author's machine running the author's world: the one
|
|
2407
|
+
// place the runtime may import and run a world's own Python (check's
|
|
2408
|
+
// handler execution, `worlds call`, `worlds test` tool cases).
|
|
2409
|
+
env: {
|
|
2410
|
+
PATH: process.env.PATH ?? "",
|
|
2411
|
+
HOME: process.env.HOME ?? "",
|
|
2412
|
+
TMPDIR: process.env.TMPDIR ?? "",
|
|
2413
|
+
GATEWAY_RUNTIME_EXECUTE: "1"
|
|
2414
|
+
}
|
|
2415
|
+
}
|
|
2416
|
+
);
|
|
2417
|
+
const out = [];
|
|
2418
|
+
const err = [];
|
|
2419
|
+
const timer = setTimeout(
|
|
2420
|
+
() => child.kill("SIGKILL"),
|
|
2421
|
+
opts.timeoutMs ?? 3e5
|
|
2422
|
+
);
|
|
2423
|
+
child.stdout.on("data", (chunk) => out.push(chunk));
|
|
2424
|
+
child.stderr.on("data", (chunk) => err.push(chunk));
|
|
2425
|
+
child.on("error", (error) => {
|
|
2426
|
+
clearTimeout(timer);
|
|
2427
|
+
reject(
|
|
2428
|
+
new CliError(
|
|
2429
|
+
`local runtime could not start (${local.python}): ${error.message}`,
|
|
2430
|
+
1
|
|
2431
|
+
)
|
|
2432
|
+
);
|
|
2433
|
+
});
|
|
2434
|
+
child.on("close", (code) => {
|
|
2435
|
+
clearTimeout(timer);
|
|
2436
|
+
const text2 = Buffer.concat(out).toString("utf8");
|
|
2437
|
+
const stderr = Buffer.concat(err).toString("utf8");
|
|
2438
|
+
let payload = null;
|
|
2439
|
+
try {
|
|
2440
|
+
payload = text2 ? JSON.parse(text2) : null;
|
|
2441
|
+
} catch {
|
|
2442
|
+
payload = null;
|
|
2443
|
+
}
|
|
2444
|
+
if (payload && typeof payload === "object") {
|
|
2445
|
+
resolve6(payload);
|
|
2446
|
+
return;
|
|
2447
|
+
}
|
|
2448
|
+
reject(
|
|
2449
|
+
new CliError(
|
|
2450
|
+
`local runtime (${request.command}) exited ${code}: ${tailOf((stderr || text2).trim()) || "no output"}`,
|
|
2451
|
+
1
|
|
2452
|
+
)
|
|
2453
|
+
);
|
|
2454
|
+
});
|
|
2455
|
+
child.stdin.end(input);
|
|
2456
|
+
});
|
|
2457
|
+
}
|
|
2458
|
+
var import_node_child_process, fs3, net, path3, MIN_PYTHON, DIAGNOSTIC_TAIL, BRIDGE_BOOTSTRAP, pythonCache, pythonProbes, PYTHON_CANDIDATES, UV_FIND;
|
|
2459
|
+
var init_local = __esm({
|
|
2460
|
+
"src/cli/runtime/local.ts"() {
|
|
2461
|
+
"use strict";
|
|
2462
|
+
import_node_child_process = require("child_process");
|
|
2463
|
+
fs3 = __toESM(require("fs"));
|
|
2464
|
+
net = __toESM(require("net"));
|
|
2465
|
+
path3 = __toESM(require("path"));
|
|
2466
|
+
init_router();
|
|
2467
|
+
init_config();
|
|
2468
|
+
MIN_PYTHON = [3, 11];
|
|
2469
|
+
DIAGNOSTIC_TAIL = 600;
|
|
2470
|
+
BRIDGE_BOOTSTRAP = `import sys,runpy,types,os
|
|
2471
|
+
root=sys.argv[1]
|
|
2472
|
+
package=types.ModuleType('gatewaysdk')
|
|
2473
|
+
package.__path__=[os.path.join(root,'gatewaysdk')]
|
|
2474
|
+
sys.modules['gatewaysdk']=package
|
|
2475
|
+
runpy.run_module('gatewaysdk.environment.schema.platform',run_name='__main__')`;
|
|
2476
|
+
pythonProbes = [];
|
|
2477
|
+
PYTHON_CANDIDATES = [
|
|
2478
|
+
"python3.13",
|
|
2479
|
+
"python3.12",
|
|
2480
|
+
"python3.11",
|
|
2481
|
+
"python3",
|
|
2482
|
+
"python"
|
|
2483
|
+
];
|
|
2484
|
+
UV_FIND = ["python", "find", `>=${MIN_PYTHON.join(".")}`];
|
|
2485
|
+
}
|
|
2486
|
+
});
|
|
2487
|
+
|
|
2488
|
+
// src/cli/runtime/client.ts
|
|
2489
|
+
function isBuildOutput(relPath) {
|
|
2490
|
+
return BUILD_OUTPUT.test(relPath);
|
|
2491
|
+
}
|
|
2492
|
+
function readWorldFiles(dir, opts = {}) {
|
|
2493
|
+
if (!fs4.existsSync(dir) || !fs4.statSync(dir).isDirectory())
|
|
2494
|
+
throw new CliError(`Not a directory: ${dir}`);
|
|
2495
|
+
const out = [];
|
|
2496
|
+
const walk = (rel) => {
|
|
2497
|
+
const abs = rel ? path4.join(dir, rel) : dir;
|
|
2498
|
+
const entries = fs4.readdirSync(abs, { withFileTypes: true });
|
|
2499
|
+
entries.sort((a, b) => a.name.localeCompare(b.name));
|
|
2500
|
+
for (const entry of entries) {
|
|
2501
|
+
const childRel = rel ? `${rel}/${entry.name}` : entry.name;
|
|
2502
|
+
if (entry.isDirectory()) {
|
|
2503
|
+
if (!SKIP_DIRS2.has(entry.name)) walk(childRel);
|
|
2504
|
+
} else if (entry.isFile()) {
|
|
2505
|
+
if (!opts.buildOutputs && isBuildOutput(childRel)) continue;
|
|
2506
|
+
out.push({
|
|
2507
|
+
path: childRel,
|
|
2508
|
+
content: fs4.readFileSync(path4.join(dir, childRel)).toString("base64")
|
|
2509
|
+
});
|
|
2510
|
+
}
|
|
2511
|
+
}
|
|
2512
|
+
};
|
|
2513
|
+
walk("");
|
|
2514
|
+
return out.sort((a, b) => a.path < b.path ? -1 : a.path > b.path ? 1 : 0);
|
|
2515
|
+
}
|
|
2516
|
+
function assertSafeRelPath(rel) {
|
|
2517
|
+
const parts = rel.split("/");
|
|
2518
|
+
if (!rel || rel.startsWith("/") || rel.includes("\\") || /^[A-Za-z]:/.test(rel) || parts.some((p) => p === "" || p === "." || p === ".."))
|
|
2519
|
+
throw new CliError(`The runtime returned an unsafe file path: ${rel}`, 1);
|
|
2520
|
+
}
|
|
2521
|
+
function writeWorldFiles(dir, files, opts = {}) {
|
|
2522
|
+
for (const file of files) assertSafeRelPath(file.path);
|
|
2523
|
+
if (opts.clean && fs4.existsSync(dir)) {
|
|
2524
|
+
const keep = new Set(files.map((f) => f.path));
|
|
2525
|
+
for (const existing of readWorldFiles(dir)) {
|
|
2526
|
+
if (!keep.has(existing.path)) fs4.rmSync(path4.join(dir, existing.path));
|
|
2527
|
+
}
|
|
2528
|
+
pruneEmptyDirs(dir);
|
|
2529
|
+
}
|
|
2530
|
+
fs4.mkdirSync(dir, { recursive: true });
|
|
2531
|
+
const written = [];
|
|
2532
|
+
for (const file of files) {
|
|
2533
|
+
const target = path4.join(dir, file.path);
|
|
2534
|
+
fs4.mkdirSync(path4.dirname(target), { recursive: true });
|
|
2535
|
+
fs4.writeFileSync(target, Buffer.from(file.content, "base64"));
|
|
2536
|
+
written.push(file.path);
|
|
2537
|
+
}
|
|
2538
|
+
return written;
|
|
2539
|
+
}
|
|
2540
|
+
function pruneEmptyDirs(root) {
|
|
2541
|
+
const walk = (abs) => {
|
|
2542
|
+
let empty = true;
|
|
2543
|
+
for (const entry of fs4.readdirSync(abs, { withFileTypes: true })) {
|
|
2544
|
+
const child = path4.join(abs, entry.name);
|
|
2545
|
+
if (entry.isDirectory()) {
|
|
2546
|
+
if (SKIP_DIRS2.has(entry.name)) {
|
|
2547
|
+
empty = false;
|
|
2548
|
+
continue;
|
|
2549
|
+
}
|
|
2550
|
+
if (walk(child)) fs4.rmdirSync(child);
|
|
2551
|
+
else empty = false;
|
|
2552
|
+
} else empty = false;
|
|
2553
|
+
}
|
|
2554
|
+
return empty;
|
|
2555
|
+
};
|
|
2556
|
+
walk(root);
|
|
2557
|
+
}
|
|
2558
|
+
function formatBridgeError(detail) {
|
|
2559
|
+
const where = detail.schema_path || detail.path || "/";
|
|
2560
|
+
return `${detail.code} at ${where}: ${detail.message}`;
|
|
2561
|
+
}
|
|
2562
|
+
function detailFrom(payload) {
|
|
2563
|
+
if (!payload || typeof payload !== "object") return null;
|
|
2564
|
+
const error = payload.error;
|
|
2565
|
+
if (!error || typeof error !== "object") return null;
|
|
2566
|
+
const detail = error;
|
|
2567
|
+
if (typeof detail.code !== "string" || typeof detail.message !== "string") return null;
|
|
2568
|
+
return detail;
|
|
2569
|
+
}
|
|
2570
|
+
async function runtime(creds, request, opts = {}) {
|
|
2571
|
+
const local = localRuntime();
|
|
2572
|
+
const yamlSpec = request.command === "conform" && Array.isArray(request.openapi) && request.openapi.some((doc) => /\.ya?ml$/i.test(doc.path ?? ""));
|
|
2573
|
+
if (local && !(yamlSpec && !localPythonHasYaml(local.python))) {
|
|
2574
|
+
const payload = await localBridge(request, local, opts);
|
|
2575
|
+
const detail = detailFrom(payload);
|
|
2576
|
+
if (detail) throw new BridgeRejected(detail);
|
|
2577
|
+
return payload;
|
|
2578
|
+
}
|
|
2579
|
+
if (!creds)
|
|
2580
|
+
throw new CliError(
|
|
2581
|
+
"This needs the schema runtime (the CLI bundles it) or platform credentials (`gateway auth login`). " + localRuntimeReason()
|
|
2582
|
+
);
|
|
2583
|
+
const controller = new AbortController();
|
|
2584
|
+
const timer = setTimeout(() => controller.abort(), opts.timeoutMs ?? 18e4);
|
|
2585
|
+
const route = "/api/public/worlds/runtime";
|
|
2586
|
+
try {
|
|
2587
|
+
const res = await fetch(`${creds.host}${route}`, {
|
|
2588
|
+
method: "POST",
|
|
2589
|
+
headers: {
|
|
2590
|
+
"content-type": "application/json",
|
|
2591
|
+
accept: "application/json",
|
|
2592
|
+
authorization: "Basic " + Buffer.from(`${creds.publicKey}:${creds.secretKey}`).toString("base64")
|
|
2593
|
+
},
|
|
2594
|
+
body: JSON.stringify(request),
|
|
2595
|
+
signal: controller.signal
|
|
2596
|
+
});
|
|
2597
|
+
const text2 = await res.text();
|
|
2598
|
+
let payload = null;
|
|
2599
|
+
try {
|
|
2600
|
+
payload = text2 ? JSON.parse(text2) : {};
|
|
2601
|
+
} catch {
|
|
2602
|
+
payload = null;
|
|
2603
|
+
}
|
|
2604
|
+
const detail = detailFrom(payload);
|
|
2605
|
+
if (detail) throw new BridgeRejected(detail);
|
|
2606
|
+
if (!res.ok)
|
|
2607
|
+
throw new CliError(`POST ${route} (${request.command}) -> ${res.status}: ${text2.slice(0, 600)}`, 1);
|
|
2608
|
+
if (payload === null) throw new CliError(`POST ${route} (${request.command}) returned non-JSON`, 1);
|
|
2609
|
+
return payload;
|
|
2610
|
+
} finally {
|
|
2611
|
+
clearTimeout(timer);
|
|
2612
|
+
}
|
|
2613
|
+
}
|
|
2614
|
+
var fs4, path4, SKIP_DIRS2, BUILD_OUTPUT, BridgeRejected;
|
|
2615
|
+
var init_client = __esm({
|
|
2616
|
+
"src/cli/runtime/client.ts"() {
|
|
2617
|
+
"use strict";
|
|
2618
|
+
fs4 = __toESM(require("fs"));
|
|
2619
|
+
path4 = __toESM(require("path"));
|
|
2620
|
+
init_router();
|
|
2621
|
+
init_local();
|
|
2622
|
+
SKIP_DIRS2 = /* @__PURE__ */ new Set(["__pycache__", ".git", "node_modules", ".gateway"]);
|
|
2623
|
+
BUILD_OUTPUT = /(^|\/)state\.(sqlite|json)$/;
|
|
2624
|
+
BridgeRejected = class extends CliError {
|
|
2625
|
+
constructor(detail) {
|
|
2626
|
+
super(formatBridgeError(detail), 1);
|
|
2627
|
+
this.detail = detail;
|
|
2628
|
+
}
|
|
2629
|
+
};
|
|
2630
|
+
}
|
|
2631
|
+
});
|
|
2632
|
+
|
|
2633
|
+
// src/cli/runtime/data.ts
|
|
2634
|
+
var data_exports = {};
|
|
2635
|
+
__export(data_exports, {
|
|
2636
|
+
checkLocalWorldData: () => checkLocalWorldData,
|
|
2637
|
+
dropBuildOutputs: () => dropBuildOutputs,
|
|
2638
|
+
importLocalWorldData: () => importLocalWorldData,
|
|
2639
|
+
ingestLocalToolCalls: () => ingestLocalToolCalls,
|
|
2640
|
+
queryLocalWorldData: () => queryLocalWorldData,
|
|
2641
|
+
queryLocalWorldDataAcross: () => queryLocalWorldDataAcross,
|
|
2642
|
+
showLocalWorldData: () => showLocalWorldData
|
|
2643
|
+
});
|
|
2644
|
+
async function importLocalWorldData(dir, rows, opts, creds) {
|
|
2645
|
+
const res = await runtime(creds, {
|
|
2646
|
+
command: "import-data",
|
|
2647
|
+
files: readWorldFiles(dir),
|
|
2648
|
+
rows,
|
|
2649
|
+
mode: opts.mode ?? "append",
|
|
2650
|
+
...opts.redact && opts.redact !== "off" ? { redact: opts.redact } : {}
|
|
2651
|
+
});
|
|
2652
|
+
if (res.files?.length) writeWorldFiles(dir, res.files);
|
|
2653
|
+
if (res.changed) dropBuildOutputs(dir);
|
|
2654
|
+
return {
|
|
2655
|
+
kind: res.kind ?? "unknown",
|
|
2656
|
+
entity_counts: res.entity_counts ?? {},
|
|
2657
|
+
changed: Boolean(res.changed)
|
|
2658
|
+
};
|
|
2659
|
+
}
|
|
2660
|
+
function dropBuildOutputs(dir) {
|
|
2661
|
+
const dropped = [];
|
|
2662
|
+
for (const file of readWorldFiles(dir, { buildOutputs: true })) {
|
|
2663
|
+
if (!BUILD_OUTPUT2.test(file.path)) continue;
|
|
2664
|
+
fs5.rmSync(path5.join(dir, file.path), { force: true });
|
|
2665
|
+
dropped.push(file.path);
|
|
2666
|
+
}
|
|
2667
|
+
return dropped;
|
|
2668
|
+
}
|
|
2669
|
+
async function checkLocalWorldData(dir, rows, creds, opts = {}) {
|
|
2670
|
+
const res = await runtime(creds, {
|
|
2671
|
+
command: "import-data",
|
|
2672
|
+
files: readWorldFiles(dir),
|
|
2673
|
+
rows,
|
|
2674
|
+
mode: "append",
|
|
2675
|
+
...opts.redact && opts.redact !== "off" ? { redact: opts.redact } : {}
|
|
2676
|
+
});
|
|
2677
|
+
return {
|
|
2678
|
+
kind: res.kind ?? "unknown",
|
|
2679
|
+
entity_counts: res.entity_counts ?? {},
|
|
2680
|
+
changed: Boolean(res.changed)
|
|
2681
|
+
};
|
|
2682
|
+
}
|
|
2683
|
+
async function showLocalWorldData(dir, entity, creds) {
|
|
2684
|
+
const res = await runtime(creds, {
|
|
2685
|
+
command: "counts",
|
|
2686
|
+
files: readWorldFiles(dir),
|
|
2687
|
+
...entity ? { entity } : {}
|
|
2688
|
+
});
|
|
2689
|
+
const out = { kind: res.kind ?? "unknown" };
|
|
2690
|
+
if (entity) {
|
|
2691
|
+
out.entity = entity;
|
|
2692
|
+
out.rows = res.rows ?? [];
|
|
2693
|
+
} else out.entity_counts = res.entity_counts ?? {};
|
|
2694
|
+
return out;
|
|
2695
|
+
}
|
|
2696
|
+
async function queryLocalWorldData(dir, entity, where, opts, creds) {
|
|
2697
|
+
const res = await runtime(creds, {
|
|
2698
|
+
command: "query",
|
|
2699
|
+
files: readWorldFiles(dir),
|
|
2700
|
+
entity,
|
|
2701
|
+
...Object.keys(where).length ? { where } : {},
|
|
2702
|
+
...opts.limit !== void 0 ? { limit: opts.limit } : {},
|
|
2703
|
+
...opts.offset !== void 0 ? { offset: opts.offset } : {},
|
|
2704
|
+
...opts.resolve ? { resolve: true } : {},
|
|
2705
|
+
...opts.scenario ? { scenario: opts.scenario } : {}
|
|
2706
|
+
});
|
|
2707
|
+
const rows = res.rows ?? [];
|
|
2708
|
+
return {
|
|
2709
|
+
...res.kind ? { kind: res.kind } : {},
|
|
2710
|
+
entity: res.entity ?? entity,
|
|
2711
|
+
...res.scenario ? { scenario: res.scenario } : {},
|
|
2712
|
+
rows,
|
|
2713
|
+
count: res.count ?? rows.length,
|
|
2714
|
+
total: res.total ?? null,
|
|
2715
|
+
limit: res.limit ?? opts.limit ?? rows.length,
|
|
2716
|
+
offset: res.offset ?? opts.offset ?? 0,
|
|
2717
|
+
...res.resolved ? { resolved: res.resolved } : {}
|
|
2718
|
+
};
|
|
2719
|
+
}
|
|
2720
|
+
async function queryLocalWorldDataAcross(dir, entity, where, opts) {
|
|
2721
|
+
const local = localRuntime();
|
|
2722
|
+
if (!local)
|
|
2723
|
+
throw new CliError(
|
|
2724
|
+
"`--across` on a directory reads the linked worlds at their paths, so it needs the bundled runtime on this machine. " + localRuntimeReason(),
|
|
2725
|
+
1
|
|
2726
|
+
);
|
|
2727
|
+
const payload = await localBridge(
|
|
2728
|
+
{
|
|
2729
|
+
command: "query",
|
|
2730
|
+
world: path5.resolve(dir),
|
|
2731
|
+
entity,
|
|
2732
|
+
across: true,
|
|
2733
|
+
...opts.compare ? { compare: true } : {},
|
|
2734
|
+
...Object.keys(where).length ? { where } : {},
|
|
2735
|
+
...opts.limit !== void 0 ? { limit: opts.limit } : {},
|
|
2736
|
+
...opts.offset !== void 0 ? { offset: opts.offset } : {},
|
|
2737
|
+
...opts.resolve ? { resolve: true } : {},
|
|
2738
|
+
...opts.scenario ? { scenario: opts.scenario } : {}
|
|
2739
|
+
},
|
|
2740
|
+
local
|
|
2741
|
+
);
|
|
2742
|
+
const detail = detailFrom(payload);
|
|
2743
|
+
if (detail) throw new BridgeRejected(detail);
|
|
2744
|
+
return payload;
|
|
2745
|
+
}
|
|
2746
|
+
async function ingestLocalToolCalls(dir, records, opts, creds) {
|
|
2747
|
+
const res = await runtime(creds, {
|
|
2748
|
+
command: "ingest-calls",
|
|
2749
|
+
files: readWorldFiles(dir),
|
|
2750
|
+
records,
|
|
2751
|
+
mode: opts.mode ?? "append",
|
|
2752
|
+
...opts.dryRun ? { dry_run: true } : {},
|
|
2753
|
+
...opts.redact && opts.redact !== "off" ? { redact: opts.redact } : {},
|
|
2754
|
+
...opts.map !== void 0 ? { map: opts.map } : {}
|
|
2755
|
+
});
|
|
2756
|
+
if (!opts.dryRun && res.files?.length) writeWorldFiles(dir, res.files);
|
|
2757
|
+
if (res.changed) dropBuildOutputs(dir);
|
|
2758
|
+
return {
|
|
2759
|
+
...res.via ? { via: res.via } : {},
|
|
2760
|
+
...res.sources ? { sources: res.sources } : {},
|
|
2761
|
+
...res.unmatched ? { unmatched: res.unmatched } : {},
|
|
2762
|
+
...res.note ? { note: res.note } : {},
|
|
2763
|
+
records: res.records ?? records.length,
|
|
2764
|
+
ingested: res.ingested ?? 0,
|
|
2765
|
+
skipped: res.skipped ?? {},
|
|
2766
|
+
refusals: res.refusals ?? [],
|
|
2767
|
+
rows: res.rows ?? {},
|
|
2768
|
+
...res.projected ? { projected: res.projected } : {},
|
|
2769
|
+
dry_run: Boolean(res.dry_run ?? opts.dryRun),
|
|
2770
|
+
redact: res.redact ?? opts.redact ?? "off",
|
|
2771
|
+
changed: Boolean(res.changed),
|
|
2772
|
+
...res.kind ? { kind: res.kind } : {},
|
|
2773
|
+
...res.entity_counts ? { entity_counts: res.entity_counts } : {},
|
|
2774
|
+
...res.batch !== void 0 ? { batch: res.batch } : {}
|
|
2775
|
+
};
|
|
2776
|
+
}
|
|
2777
|
+
var fs5, path5, BUILD_OUTPUT2;
|
|
2778
|
+
var init_data = __esm({
|
|
2779
|
+
"src/cli/runtime/data.ts"() {
|
|
2780
|
+
"use strict";
|
|
2781
|
+
fs5 = __toESM(require("fs"));
|
|
2782
|
+
path5 = __toESM(require("path"));
|
|
2783
|
+
init_router();
|
|
2784
|
+
init_client();
|
|
2785
|
+
init_local();
|
|
2786
|
+
BUILD_OUTPUT2 = /(^|\/)state\.(sqlite|json)$/;
|
|
2787
|
+
}
|
|
2788
|
+
});
|
|
2789
|
+
|
|
2790
|
+
// src/cli/platform/worldData/transform.ts
|
|
2791
|
+
var transform_exports = {};
|
|
2792
|
+
__export(transform_exports, {
|
|
2793
|
+
DEFAULT_TRANSFORM_TIMEOUT_MS: () => DEFAULT_TRANSFORM_TIMEOUT_MS,
|
|
2794
|
+
NODE_SUFFIXES: () => NODE_SUFFIXES,
|
|
2795
|
+
NODE_WRAPPER: () => NODE_WRAPPER,
|
|
2796
|
+
PYTHON_SUFFIXES: () => PYTHON_SUFFIXES,
|
|
2797
|
+
PY_WRAPPER: () => PY_WRAPPER,
|
|
2798
|
+
checkRows: () => checkRows,
|
|
2799
|
+
runTransform: () => runTransform,
|
|
2800
|
+
transformRecords: () => transformRecords
|
|
2801
|
+
});
|
|
2802
|
+
function checkRows(value, where) {
|
|
2803
|
+
if (!isObject(value)) throw new CliError(`${where} must return {entity: [rows]}; got ${value === null ? "null" : Array.isArray(value) ? "an array" : typeof value}`, 1);
|
|
2804
|
+
for (const [entity, listed] of Object.entries(value)) {
|
|
2805
|
+
if (!Array.isArray(listed)) throw new CliError(`${where}: ${entity} must be a list of rows; got ${listed === null ? "null" : typeof listed}`, 1);
|
|
2806
|
+
listed.forEach((row, index) => {
|
|
2807
|
+
if (!isObject(row)) throw new CliError(`${where}: ${entity}[${index}] is not an object`, 1);
|
|
2808
|
+
});
|
|
2809
|
+
}
|
|
2810
|
+
return value;
|
|
2811
|
+
}
|
|
2812
|
+
function typescriptPrefix() {
|
|
2813
|
+
const [major, minor] = process.versions.node.split(".").map(Number);
|
|
2814
|
+
if (!process.env.GATEWAY_NODE && (major > 22 || major === 22 && minor >= 6)) return ["--experimental-strip-types", "--no-warnings"];
|
|
2815
|
+
try {
|
|
2816
|
+
return [(0, import_node_module.createRequire)(import_meta.url).resolve("tsx/cli")];
|
|
2817
|
+
} catch {
|
|
2818
|
+
throw new CliError(
|
|
2819
|
+
`a .ts transform needs Node 22.6 or newer (built-in type stripping; this is ${process.versions.node}) or the tsx package installed beside the CLI; write the transform as .mjs or .py, or set GATEWAY_NODE to a newer node`,
|
|
2820
|
+
1
|
|
2821
|
+
);
|
|
2822
|
+
}
|
|
2823
|
+
}
|
|
2824
|
+
function command(script, wrapperDir) {
|
|
2825
|
+
const suffix = path6.extname(script).toLowerCase();
|
|
2826
|
+
if (PYTHON_SUFFIXES.includes(suffix)) return { file: process.env.GATEWAY_PYTHON || "python3", args: ["-c", PY_WRAPPER, script] };
|
|
2827
|
+
if (NODE_SUFFIXES.includes(suffix)) {
|
|
2828
|
+
const wrapper = path6.join(wrapperDir, "transform-wrapper.mjs");
|
|
2829
|
+
fs6.writeFileSync(wrapper, NODE_WRAPPER);
|
|
2830
|
+
const flags = suffix === ".ts" || suffix === ".mts" ? typescriptPrefix() : [];
|
|
2831
|
+
return { file: process.env.GATEWAY_NODE || process.execPath, args: [...flags, wrapper, script] };
|
|
2832
|
+
}
|
|
2833
|
+
throw new CliError(`${path6.basename(script)}: a transform script is .py, .ts, .mjs, .js or .cjs`, 1);
|
|
2834
|
+
}
|
|
2835
|
+
async function runTransform(script, records, opts = {}) {
|
|
2836
|
+
if (!fs6.existsSync(script) || !fs6.statSync(script).isFile()) throw new CliError(`no transform script at ${script}`, 1);
|
|
2837
|
+
const resolved = path6.resolve(script);
|
|
2838
|
+
const name = path6.basename(script);
|
|
2839
|
+
const timeoutMs = opts.timeoutMs ?? DEFAULT_TRANSFORM_TIMEOUT_MS;
|
|
2840
|
+
const scratch = fs6.mkdtempSync(path6.join(os2.tmpdir(), "gateway-transform-"));
|
|
2841
|
+
try {
|
|
2842
|
+
const { file, args } = command(resolved, scratch);
|
|
2843
|
+
const env = Object.fromEntries(Object.entries(process.env).filter(([key]) => !SCRUBBED.test(key)));
|
|
2844
|
+
const done = await new Promise((resolve6, reject) => {
|
|
2845
|
+
const child = (0, import_node_child_process2.spawn)(file, args, { cwd: path6.dirname(resolved), env, stdio: ["pipe", "pipe", "pipe"] });
|
|
2846
|
+
let stdout = "";
|
|
2847
|
+
let stderr = "";
|
|
2848
|
+
let timedOut = false;
|
|
2849
|
+
const timer = setTimeout(() => {
|
|
2850
|
+
timedOut = true;
|
|
2851
|
+
child.kill("SIGKILL");
|
|
2852
|
+
}, timeoutMs);
|
|
2853
|
+
child.stdout.setEncoding("utf8").on("data", (chunk) => stdout += chunk);
|
|
2854
|
+
child.stderr.setEncoding("utf8").on("data", (chunk) => stderr += chunk);
|
|
2855
|
+
child.on("error", (error) => {
|
|
2856
|
+
clearTimeout(timer);
|
|
2857
|
+
reject(new CliError(`${name}: cannot run ${file}: ${error.message}`, 1));
|
|
2858
|
+
});
|
|
2859
|
+
child.on("close", (code) => {
|
|
2860
|
+
clearTimeout(timer);
|
|
2861
|
+
resolve6({ code, stdout, stderr, timedOut });
|
|
2862
|
+
});
|
|
2863
|
+
child.stdin.on("error", () => void 0);
|
|
2864
|
+
child.stdin.end(records.map((record) => JSON.stringify(record) + "\n").join(""));
|
|
2865
|
+
});
|
|
2866
|
+
if (done.timedOut) throw new CliError(`${name} timed out after ${timeoutMs / 1e3}s${tail(done.stderr)}`, 1);
|
|
2867
|
+
if (done.code !== 0) throw new CliError(`${name} exited ${done.code ?? "?"}${tail(done.stderr)}`, 1);
|
|
2868
|
+
let value;
|
|
2869
|
+
try {
|
|
2870
|
+
value = done.stdout.trim() ? JSON.parse(done.stdout) : null;
|
|
2871
|
+
} catch {
|
|
2872
|
+
throw new CliError(`${name} printed something other than the rows document${tail(done.stderr)}`, 1);
|
|
2873
|
+
}
|
|
2874
|
+
return { rows: checkRows(value, name), stderr: done.stderr };
|
|
2875
|
+
} finally {
|
|
2876
|
+
fs6.rmSync(scratch, { recursive: true, force: true });
|
|
2877
|
+
}
|
|
2878
|
+
}
|
|
2879
|
+
async function transformRecords(transform, records, opts = {}) {
|
|
2880
|
+
if (typeof transform === "function") return { rows: checkRows(await transform(records), "transform(records)"), stderr: "" };
|
|
2881
|
+
return runTransform(transform, records, opts);
|
|
2882
|
+
}
|
|
2883
|
+
var import_node_child_process2, fs6, os2, path6, import_node_module, import_meta, DEFAULT_TRANSFORM_TIMEOUT_MS, NODE_SUFFIXES, PYTHON_SUFFIXES, SCRUBBED, PY_WRAPPER, NODE_WRAPPER, isObject, tail;
|
|
2884
|
+
var init_transform = __esm({
|
|
2885
|
+
"src/cli/platform/worldData/transform.ts"() {
|
|
2886
|
+
"use strict";
|
|
2887
|
+
import_node_child_process2 = require("child_process");
|
|
2888
|
+
fs6 = __toESM(require("fs"));
|
|
2889
|
+
os2 = __toESM(require("os"));
|
|
2890
|
+
path6 = __toESM(require("path"));
|
|
2891
|
+
import_node_module = require("module");
|
|
2892
|
+
init_router();
|
|
2893
|
+
import_meta = {};
|
|
2894
|
+
DEFAULT_TRANSFORM_TIMEOUT_MS = 12e4;
|
|
2895
|
+
NODE_SUFFIXES = [".ts", ".mts", ".mjs", ".js", ".cjs"];
|
|
2896
|
+
PYTHON_SUFFIXES = [".py"];
|
|
2897
|
+
SCRUBBED = /^(GATEWAY_|HTTPS?_PROXY$|ALL_PROXY$|https?_proxy$|all_proxy$)/;
|
|
2898
|
+
PY_WRAPPER = `
|
|
2899
|
+
import io, json, runpy, socket, sys
|
|
2900
|
+
|
|
2901
|
+
def _deny(*args, **kwargs):
|
|
2902
|
+
raise RuntimeError("network is disabled in a transform")
|
|
2903
|
+
|
|
2904
|
+
class _Denied(socket.socket):
|
|
2905
|
+
def __init__(self, *args, **kwargs):
|
|
2906
|
+
_deny()
|
|
2907
|
+
|
|
2908
|
+
socket.socket = _Denied
|
|
2909
|
+
socket.SocketType = _Denied
|
|
2910
|
+
socket.create_connection = _deny
|
|
2911
|
+
socket.getaddrinfo = _deny
|
|
2912
|
+
|
|
2913
|
+
text = sys.stdin.read()
|
|
2914
|
+
records = [json.loads(line) for line in text.splitlines() if line.strip()]
|
|
2915
|
+
sys.stdin = io.StringIO(text)
|
|
2916
|
+
captured = io.StringIO()
|
|
2917
|
+
real = sys.stdout
|
|
2918
|
+
sys.stdout = captured
|
|
2919
|
+
try:
|
|
2920
|
+
namespace = runpy.run_path(sys.argv[1], run_name="__main__")
|
|
2921
|
+
finally:
|
|
2922
|
+
sys.stdout = real
|
|
2923
|
+
fn = namespace.get("transform")
|
|
2924
|
+
if callable(fn):
|
|
2925
|
+
out = fn(records)
|
|
2926
|
+
else:
|
|
2927
|
+
printed = captured.getvalue().strip()
|
|
2928
|
+
if not printed:
|
|
2929
|
+
sys.stderr.write("the transform defines no transform(records) and printed nothing\\n")
|
|
2930
|
+
sys.exit(3)
|
|
2931
|
+
out = json.loads(printed)
|
|
2932
|
+
real.write(json.dumps(out))
|
|
2933
|
+
`;
|
|
2934
|
+
NODE_WRAPPER = `
|
|
2935
|
+
import { pathToFileURL } from "node:url";
|
|
2936
|
+
import net from "node:net";
|
|
2937
|
+
import tls from "node:tls";
|
|
2938
|
+
import http from "node:http";
|
|
2939
|
+
import https from "node:https";
|
|
2940
|
+
import dgram from "node:dgram";
|
|
2941
|
+
|
|
2942
|
+
const deny = () => { throw new Error("network is disabled in a transform"); };
|
|
2943
|
+
net.Socket.prototype.connect = deny;
|
|
2944
|
+
net.connect = deny;
|
|
2945
|
+
net.createConnection = deny;
|
|
2946
|
+
tls.connect = deny;
|
|
2947
|
+
http.request = deny;
|
|
2948
|
+
http.get = deny;
|
|
2949
|
+
https.request = deny;
|
|
2950
|
+
https.get = deny;
|
|
2951
|
+
dgram.createSocket = deny;
|
|
2952
|
+
globalThis.fetch = deny;
|
|
2953
|
+
|
|
2954
|
+
const module = await import(pathToFileURL(process.argv[2]).href);
|
|
2955
|
+
const fn = typeof module.transform === "function" ? module.transform : typeof module.default === "function" ? module.default : null;
|
|
2956
|
+
if (fn) {
|
|
2957
|
+
const chunks = [];
|
|
2958
|
+
for await (const chunk of process.stdin) chunks.push(chunk);
|
|
2959
|
+
const text = Buffer.concat(chunks).toString("utf8");
|
|
2960
|
+
const records = text.split("\\n").filter((line) => line.trim()).map((line) => JSON.parse(line));
|
|
2961
|
+
const out = await fn(records);
|
|
2962
|
+
process.stdout.write(JSON.stringify(out));
|
|
2963
|
+
}
|
|
2964
|
+
`;
|
|
2965
|
+
isObject = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
|
|
2966
|
+
tail = (stderr, lines = 12) => {
|
|
2967
|
+
const kept = stderr.split("\n").filter((line) => line.trim()).slice(-lines);
|
|
2968
|
+
return kept.length ? "\n" + kept.join("\n") : "";
|
|
2969
|
+
};
|
|
2970
|
+
}
|
|
2971
|
+
});
|
|
2972
|
+
|
|
2973
|
+
// src/cli/platform/worldData/batches.ts
|
|
2974
|
+
function uploadHeadersFor(gz) {
|
|
2975
|
+
return {
|
|
2976
|
+
"content-type": "application/gzip",
|
|
2977
|
+
"content-length": String(gz.length),
|
|
2978
|
+
"x-amz-checksum-sha256": (0, import_node_crypto5.createHash)("sha256").update(gz).digest("base64")
|
|
2979
|
+
};
|
|
2980
|
+
}
|
|
2981
|
+
async function forEachLimited(items, limit, fn) {
|
|
2982
|
+
const inFlight = /* @__PURE__ */ new Set();
|
|
2983
|
+
let failure = null;
|
|
2984
|
+
const track = (p) => {
|
|
2985
|
+
const wrapped = p.then(
|
|
2986
|
+
() => {
|
|
2987
|
+
inFlight.delete(wrapped);
|
|
2988
|
+
},
|
|
2989
|
+
(error) => {
|
|
2990
|
+
failure ??= error;
|
|
2991
|
+
inFlight.delete(wrapped);
|
|
2992
|
+
}
|
|
2993
|
+
);
|
|
2994
|
+
inFlight.add(wrapped);
|
|
2995
|
+
};
|
|
2996
|
+
for await (const item of items) {
|
|
2997
|
+
if (failure) break;
|
|
2998
|
+
track(fn(item));
|
|
2999
|
+
if (inFlight.size >= limit) await Promise.race(inFlight);
|
|
3000
|
+
}
|
|
3001
|
+
await Promise.all(inFlight);
|
|
3002
|
+
if (failure) throw failure;
|
|
3003
|
+
}
|
|
3004
|
+
async function waitForBatch(client, batchId, opts = {}) {
|
|
3005
|
+
const sleep2 = opts.sleep ?? client.sleep;
|
|
3006
|
+
let delay = opts.initialDelayMs ?? 1e3;
|
|
3007
|
+
let last = "";
|
|
3008
|
+
for (; ; ) {
|
|
3009
|
+
const status = await client.get(batchId);
|
|
3010
|
+
const phase = phaseLine(status);
|
|
3011
|
+
if (phase !== last) {
|
|
3012
|
+
opts.onPhase?.(phase);
|
|
3013
|
+
last = phase;
|
|
3014
|
+
}
|
|
3015
|
+
if (TERMINAL_STATES.has(status.state)) return status;
|
|
3016
|
+
await sleep2(delay);
|
|
3017
|
+
delay = Math.min(1e4, Math.round(delay * 1.5));
|
|
3018
|
+
}
|
|
3019
|
+
}
|
|
3020
|
+
function phaseLine(status) {
|
|
3021
|
+
const phase = status.progress?.phase;
|
|
3022
|
+
return phase ? `${status.state} (${phase})` : status.state;
|
|
3023
|
+
}
|
|
3024
|
+
var import_node_crypto5, fs7, TERMINAL_STATES, sleepMs, WorldDataApi;
|
|
3025
|
+
var init_batches = __esm({
|
|
3026
|
+
"src/cli/platform/worldData/batches.ts"() {
|
|
3027
|
+
"use strict";
|
|
3028
|
+
import_node_crypto5 = require("crypto");
|
|
3029
|
+
fs7 = __toESM(require("fs"));
|
|
3030
|
+
init_config();
|
|
3031
|
+
init_router();
|
|
3032
|
+
TERMINAL_STATES = /* @__PURE__ */ new Set(["applied", "refused", "published", "failed"]);
|
|
3033
|
+
sleepMs = (ms) => new Promise((resolve6) => setTimeout(resolve6, ms));
|
|
3034
|
+
WorldDataApi = class {
|
|
3035
|
+
constructor(creds, slug, sleep2 = sleepMs) {
|
|
3036
|
+
this.creds = creds;
|
|
3037
|
+
this.slug = slug;
|
|
3038
|
+
this.sleep = sleep2;
|
|
3039
|
+
this.base = `/api/public/worlds/${encodeURIComponent(slug)}/data`;
|
|
3040
|
+
}
|
|
3041
|
+
base;
|
|
3042
|
+
open(body) {
|
|
3043
|
+
return api(this.creds, "POST", `${this.base}/batches`, body);
|
|
3044
|
+
}
|
|
3045
|
+
register(batchId, chunk) {
|
|
3046
|
+
return api(this.creds, "POST", `${this.base}/batches/${batchId}/chunks`, {
|
|
3047
|
+
ordinal: chunk.ordinal,
|
|
3048
|
+
digest: chunk.digest,
|
|
3049
|
+
bytes: chunk.bytes,
|
|
3050
|
+
rows: chunk.rows,
|
|
3051
|
+
...chunk.entity ? { entity: chunk.entity } : {}
|
|
3052
|
+
});
|
|
3053
|
+
}
|
|
3054
|
+
markUploaded(batchId, chunkId) {
|
|
3055
|
+
return api(this.creds, "POST", `${this.base}/batches/${batchId}/chunks/${chunkId}/uploaded`);
|
|
3056
|
+
}
|
|
3057
|
+
complete(batchId) {
|
|
3058
|
+
return api(this.creds, "POST", `${this.base}/batches/${batchId}/complete`);
|
|
3059
|
+
}
|
|
3060
|
+
get(batchId) {
|
|
3061
|
+
return api(this.creds, "GET", `${this.base}/batches/${batchId}`);
|
|
3062
|
+
}
|
|
3063
|
+
list(limit, cursor) {
|
|
3064
|
+
const params = new URLSearchParams();
|
|
3065
|
+
if (limit !== void 0) params.set("limit", String(limit));
|
|
3066
|
+
if (cursor) params.set("cursor", cursor);
|
|
3067
|
+
const q = params.toString();
|
|
3068
|
+
return api(this.creds, "GET", `${this.base}/batches${q ? `?${q}` : ""}`);
|
|
3069
|
+
}
|
|
3070
|
+
publish(message) {
|
|
3071
|
+
return api(this.creds, "POST", `${this.base}/publish`, message ? { message } : {});
|
|
3072
|
+
}
|
|
3073
|
+
/**
|
|
3074
|
+
* PUT the gzipped chunk to its presigned URL with exactly the headers the
|
|
3075
|
+
* URL was signed for (the platform's `uploadHeaders`; the same three when it
|
|
3076
|
+
* sends none), with backoff on a dropped connection or a 5xx.
|
|
3077
|
+
*/
|
|
3078
|
+
async put(uploadUrl, gz, signed) {
|
|
3079
|
+
const headers = signed ?? uploadHeadersFor(gz);
|
|
3080
|
+
const delays = [500, 1500, 4e3];
|
|
3081
|
+
for (let attempt = 0; ; attempt++) {
|
|
3082
|
+
try {
|
|
3083
|
+
const res = await fetch(uploadUrl, { method: "PUT", body: new Uint8Array(gz), headers });
|
|
3084
|
+
if (res.ok) return;
|
|
3085
|
+
if (res.status < 500 || attempt >= delays.length) throw new CliError(`chunk upload -> ${res.status}: ${(await res.text()).slice(0, 300)}`, 1);
|
|
3086
|
+
} catch (error) {
|
|
3087
|
+
if (error instanceof CliError || attempt >= delays.length) throw error instanceof CliError ? error : new CliError(`chunk upload failed: ${error.message}`, 1);
|
|
3088
|
+
}
|
|
3089
|
+
await this.sleep(delays[attempt]);
|
|
3090
|
+
}
|
|
3091
|
+
}
|
|
3092
|
+
/** Register, upload unless the server already holds the content, confirm. */
|
|
3093
|
+
async upload(batchId, chunk) {
|
|
3094
|
+
const registered = await this.register(batchId, chunk);
|
|
3095
|
+
if (!registered.uploaded) {
|
|
3096
|
+
if (!registered.uploadUrl) throw new CliError(`the server registered chunk ${chunk.ordinal} without an upload URL`, 1);
|
|
3097
|
+
await this.put(registered.uploadUrl, chunk.gz, registered.uploadHeaders);
|
|
3098
|
+
await this.markUploaded(batchId, registered.chunkId);
|
|
3099
|
+
}
|
|
3100
|
+
return { ordinal: chunk.ordinal, digest: chunk.digest, bytes: chunk.bytes, rows: chunk.rows, entity: chunk.entity, chunkId: registered.chunkId, uploaded: true };
|
|
3101
|
+
}
|
|
3102
|
+
};
|
|
3103
|
+
}
|
|
3104
|
+
});
|
|
3105
|
+
|
|
3106
|
+
// src/cli/platform/worldData/chunker.ts
|
|
3107
|
+
function chunkLine(row, declared) {
|
|
3108
|
+
if (declared !== null) return dumps(row.row) + "\n";
|
|
3109
|
+
const tagged = /* @__PURE__ */ new Map();
|
|
3110
|
+
tagged.set("entity", row.entity);
|
|
3111
|
+
tagged.set("row", row.row);
|
|
3112
|
+
return dumps(tagged) + "\n";
|
|
3113
|
+
}
|
|
3114
|
+
async function* buildChunks(rows, plan) {
|
|
3115
|
+
let lines = [];
|
|
3116
|
+
let rawBytes = 0;
|
|
3117
|
+
let ordinal = 0;
|
|
3118
|
+
let seen = 0;
|
|
3119
|
+
const flush = () => {
|
|
3120
|
+
const raw = Buffer.concat(lines);
|
|
3121
|
+
const built = finishChunk(ordinal++, raw, lines.length, plan.entity, seen - lines.length);
|
|
3122
|
+
lines = [];
|
|
3123
|
+
rawBytes = 0;
|
|
3124
|
+
return built;
|
|
3125
|
+
};
|
|
3126
|
+
for await (const row of rows) {
|
|
3127
|
+
const line = Buffer.from(chunkLine(row, plan.entity), "utf8");
|
|
3128
|
+
const full = lines.length > 0 && (plan.chunkRows !== null && lines.length >= plan.chunkRows || rawBytes + line.length > plan.chunkBytes);
|
|
3129
|
+
if (full) yield flush();
|
|
3130
|
+
lines.push(line);
|
|
3131
|
+
rawBytes += line.length;
|
|
3132
|
+
seen++;
|
|
3133
|
+
}
|
|
3134
|
+
if (lines.length) yield flush();
|
|
3135
|
+
}
|
|
3136
|
+
function finishChunk(ordinal, raw, rows, entity, firstRow = 0) {
|
|
3137
|
+
const gz = gzipDeterministic(raw, { name: chunkName(ordinal) });
|
|
3138
|
+
return {
|
|
3139
|
+
ordinal,
|
|
3140
|
+
digest: (0, import_node_crypto6.createHash)("sha256").update(gz).digest("hex"),
|
|
3141
|
+
bytes: gz.length,
|
|
3142
|
+
rows,
|
|
3143
|
+
entity,
|
|
3144
|
+
rawBytes: raw.length,
|
|
3145
|
+
contentSha256: (0, import_node_crypto6.createHash)("sha256").update(raw).digest("hex"),
|
|
3146
|
+
firstRow,
|
|
3147
|
+
gz
|
|
3148
|
+
};
|
|
3149
|
+
}
|
|
3150
|
+
function gzipDeterministic(raw, opts = {}) {
|
|
3151
|
+
const level = opts.level ?? GZIP_LEVEL;
|
|
3152
|
+
const name = opts.name ? Buffer.concat([Buffer.from(opts.name, "latin1"), Buffer.from([0])]) : Buffer.alloc(0);
|
|
3153
|
+
const header = Buffer.from([31, 139, 8, opts.name ? 8 : 0, 0, 0, 0, 0, level === 9 ? 2 : level === 1 ? 4 : 0, 255]);
|
|
3154
|
+
const body = (0, import_node_zlib2.deflateRawSync)(raw, { level });
|
|
3155
|
+
const trailer = Buffer.alloc(8);
|
|
3156
|
+
trailer.writeUInt32LE(crc32(raw), 0);
|
|
3157
|
+
trailer.writeUInt32LE(raw.length >>> 0, 4);
|
|
3158
|
+
return Buffer.concat([header, name, body, trailer]);
|
|
3159
|
+
}
|
|
3160
|
+
function crc32(data) {
|
|
3161
|
+
if (!table) {
|
|
3162
|
+
table = new Uint32Array(256);
|
|
3163
|
+
for (let n = 0; n < 256; n++) {
|
|
3164
|
+
let c = n;
|
|
3165
|
+
for (let k = 0; k < 8; k++) c = c & 1 ? 3988292384 ^ c >>> 1 : c >>> 1;
|
|
3166
|
+
table[n] = c >>> 0;
|
|
3167
|
+
}
|
|
3168
|
+
}
|
|
3169
|
+
let crc = 4294967295;
|
|
3170
|
+
for (let i = 0; i < data.length; i++) crc = table[(crc ^ data[i]) & 255] ^ crc >>> 8;
|
|
3171
|
+
return (crc ^ 4294967295) >>> 0;
|
|
3172
|
+
}
|
|
3173
|
+
var import_node_crypto6, import_node_zlib2, DEFAULT_CHUNK_BYTES, GZIP_LEVEL, chunkName, table;
|
|
3174
|
+
var init_chunker = __esm({
|
|
3175
|
+
"src/cli/platform/worldData/chunker.ts"() {
|
|
3176
|
+
"use strict";
|
|
3177
|
+
import_node_crypto6 = require("crypto");
|
|
3178
|
+
import_node_zlib2 = require("zlib");
|
|
3179
|
+
init_json();
|
|
3180
|
+
DEFAULT_CHUNK_BYTES = 64 * 1024 * 1024;
|
|
3181
|
+
GZIP_LEVEL = 9;
|
|
3182
|
+
chunkName = (ordinal) => `chunk-${String(ordinal).padStart(5, "0")}.jsonl`;
|
|
3183
|
+
table = null;
|
|
3184
|
+
}
|
|
3185
|
+
});
|
|
3186
|
+
|
|
3187
|
+
// src/cli/platform/worldData/push.ts
|
|
3188
|
+
var push_exports = {};
|
|
3189
|
+
__export(push_exports, {
|
|
3190
|
+
pushRows: () => pushRows
|
|
3191
|
+
});
|
|
3192
|
+
async function pushRows(creds, slug, rows, opts = {}) {
|
|
3193
|
+
const client = opts.sleep ? new WorldDataApi(creds, slug, opts.sleep) : new WorldDataApi(creds, slug);
|
|
3194
|
+
const opened = await client.open({
|
|
3195
|
+
mode: opts.mode ?? "append",
|
|
3196
|
+
merge: "upsert",
|
|
3197
|
+
...opts.redact && opts.redact !== "off" ? { redact: opts.redact } : {},
|
|
3198
|
+
atomic: true,
|
|
3199
|
+
dryRun: Boolean(opts.dryRun),
|
|
3200
|
+
publish: opts.publish ?? "now",
|
|
3201
|
+
...opts.message ? { message: opts.message } : {}
|
|
3202
|
+
});
|
|
3203
|
+
if (!opened.batchId) throw new Error("the platform opened no batch (no batchId in the answer)");
|
|
3204
|
+
const tagged = (async function* () {
|
|
3205
|
+
for (const [entity, listed] of Object.entries(rows))
|
|
3206
|
+
for (let index = 0; index < listed.length; index++)
|
|
3207
|
+
yield { entity, row: parseJson(JSON.stringify(listed[index])), where: `${entity}[${index}]` };
|
|
3208
|
+
})();
|
|
3209
|
+
const chunks = buildChunks(tagged, { chunkBytes: opts.chunkBytes ?? DEFAULT_CHUNK_BYTES, chunkRows: null, entity: null });
|
|
3210
|
+
await forEachLimited(chunks, Math.max(1, opts.parallel ?? 4), async (chunk) => {
|
|
3211
|
+
await client.upload(opened.batchId, chunk);
|
|
3212
|
+
});
|
|
3213
|
+
await client.complete(opened.batchId);
|
|
3214
|
+
return waitForBatch(client, opened.batchId, { initialDelayMs: pollMs() });
|
|
3215
|
+
}
|
|
3216
|
+
function pollMs() {
|
|
3217
|
+
const raw = Number(process.env.GATEWAY_WORLD_DATA_POLL_MS ?? 1e3);
|
|
3218
|
+
return Number.isFinite(raw) && raw >= 0 ? raw : 1e3;
|
|
3219
|
+
}
|
|
3220
|
+
var init_push = __esm({
|
|
3221
|
+
"src/cli/platform/worldData/push.ts"() {
|
|
3222
|
+
"use strict";
|
|
3223
|
+
init_batches();
|
|
3224
|
+
init_chunker();
|
|
3225
|
+
init_json();
|
|
3226
|
+
}
|
|
3227
|
+
});
|
|
3228
|
+
|
|
3229
|
+
// src/worlds/ingest.ts
|
|
3230
|
+
function parseToolCallRecord(raw) {
|
|
3231
|
+
const none = { record: null, skip: null };
|
|
3232
|
+
if (!isObject2(raw)) return { ...none, refusal: "record is not an object" };
|
|
3233
|
+
const kind = raw.kind;
|
|
3234
|
+
if (kind !== void 0 && kind !== null && kind !== "call") return { record: null, skip: `kind ${String(kind)}`, refusal: null };
|
|
3235
|
+
const tool = raw.tool;
|
|
3236
|
+
if (typeof tool !== "string" || !tool) return { ...none, refusal: "record has no tool name" };
|
|
3237
|
+
if (raw.error !== void 0 && raw.error !== null && raw.error !== "") return { record: null, skip: "call failed", refusal: null };
|
|
3238
|
+
const args = raw.args ?? {};
|
|
3239
|
+
if (!isObject2(args)) return { ...none, refusal: `args of ${tool} is not an object` };
|
|
3240
|
+
if (!("result" in raw)) return { ...none, refusal: `record of ${tool} has no result` };
|
|
3241
|
+
const at = raw.at ?? raw.completedAt;
|
|
3242
|
+
const record = { tool, args, result: raw.result };
|
|
3243
|
+
if (typeof at === "string") record.at = at;
|
|
3244
|
+
if (typeof raw.session === "string") record.session = raw.session;
|
|
3245
|
+
if (typeof raw.source === "string") record.source = raw.source;
|
|
3246
|
+
return { record, skip: null, refusal: null };
|
|
3247
|
+
}
|
|
3248
|
+
function readToolCallRecords(paths) {
|
|
3249
|
+
const records = [];
|
|
3250
|
+
for (const file of paths) records.push(...toolCallRecordsIn(fs8.readFileSync(file, "utf8"), file));
|
|
3251
|
+
return records;
|
|
3252
|
+
}
|
|
3253
|
+
function toolCallRecordsIn(text2, where) {
|
|
3254
|
+
const stripped = text2.trim();
|
|
3255
|
+
if (!stripped) return [];
|
|
3256
|
+
if (stripped.startsWith("[")) {
|
|
3257
|
+
const listed = JSON.parse(stripped);
|
|
3258
|
+
if (!Array.isArray(listed)) throw new Error(`${where} is neither a JSON array nor JSON Lines`);
|
|
3259
|
+
listed.forEach((item, index) => {
|
|
3260
|
+
if (!isObject2(item)) throw new Error(`${where}[${index}] is not an object`);
|
|
3261
|
+
});
|
|
3262
|
+
return listed;
|
|
3263
|
+
}
|
|
3264
|
+
const records = [];
|
|
3265
|
+
const lines = text2.split(/\r?\n/);
|
|
3266
|
+
for (let index = 0; index < lines.length; index++) {
|
|
3267
|
+
const line = lines[index];
|
|
3268
|
+
if (!line.trim()) continue;
|
|
3269
|
+
let item;
|
|
3270
|
+
try {
|
|
3271
|
+
item = JSON.parse(line);
|
|
3272
|
+
} catch {
|
|
3273
|
+
throw new Error(`${where}:${index + 1} is not JSON`);
|
|
3274
|
+
}
|
|
3275
|
+
if (!isObject2(item)) throw new Error(`${where}:${index + 1} is not an object`);
|
|
3276
|
+
records.push(item);
|
|
3277
|
+
}
|
|
3278
|
+
return records;
|
|
3279
|
+
}
|
|
3280
|
+
async function emit(sink, record) {
|
|
3281
|
+
if (Array.isArray(sink)) {
|
|
3282
|
+
sink.push(record);
|
|
3283
|
+
return;
|
|
3284
|
+
}
|
|
3285
|
+
if (typeof sink === "string") {
|
|
3286
|
+
fs8.appendFileSync(sink, JSON.stringify(record) + "\n");
|
|
3287
|
+
return;
|
|
3288
|
+
}
|
|
3289
|
+
if (typeof sink === "function") {
|
|
3290
|
+
await sink(record);
|
|
3291
|
+
return;
|
|
3292
|
+
}
|
|
3293
|
+
throw new TypeError("sink must be an array, a file path, or a function");
|
|
3294
|
+
}
|
|
3295
|
+
function captureToolCalls(tools, sink, opts = {}) {
|
|
3296
|
+
const wrapped = /* @__PURE__ */ Object.create(null);
|
|
3297
|
+
for (const [name, fn] of Object.entries(tools)) {
|
|
3298
|
+
wrapped[name] = async (args = {}) => {
|
|
3299
|
+
const record = { tool: name, args, at: (/* @__PURE__ */ new Date()).toISOString() };
|
|
3300
|
+
if (opts.session) record.session = opts.session;
|
|
3301
|
+
if (opts.source) record.source = opts.source;
|
|
3302
|
+
let result;
|
|
3303
|
+
try {
|
|
3304
|
+
result = await fn(args);
|
|
3305
|
+
} catch (error) {
|
|
3306
|
+
record.error = error instanceof Error ? error.message || error.name : String(error);
|
|
3307
|
+
await emit(sink, record);
|
|
3308
|
+
throw error;
|
|
3309
|
+
}
|
|
3310
|
+
record.result = result;
|
|
3311
|
+
await emit(sink, record);
|
|
3312
|
+
return result;
|
|
3313
|
+
};
|
|
3314
|
+
}
|
|
3315
|
+
return wrapped;
|
|
3316
|
+
}
|
|
3317
|
+
function jsonish(value) {
|
|
3318
|
+
if (typeof value !== "string") return value;
|
|
3319
|
+
try {
|
|
3320
|
+
return JSON.parse(value);
|
|
3321
|
+
} catch {
|
|
3322
|
+
return value;
|
|
3323
|
+
}
|
|
3324
|
+
}
|
|
3325
|
+
function toolCallsFromObservations(observations, opts = {}) {
|
|
3326
|
+
const known = opts.tools ? new Set(opts.tools) : null;
|
|
3327
|
+
const sinceMs = opts.since ? Date.parse(opts.since) : NaN;
|
|
3328
|
+
const out = { records: [], unknownTools: {}, skipped: {} };
|
|
3329
|
+
const skip = (reason) => {
|
|
3330
|
+
out.skipped[reason] = (out.skipped[reason] ?? 0) + 1;
|
|
3331
|
+
};
|
|
3332
|
+
for (const observation of observations) {
|
|
3333
|
+
if (observation.type !== "TOOL") {
|
|
3334
|
+
skip(`type ${observation.type ?? "unknown"}`);
|
|
3335
|
+
continue;
|
|
3336
|
+
}
|
|
3337
|
+
const tool = observation.name;
|
|
3338
|
+
if (typeof tool !== "string" || !tool) {
|
|
3339
|
+
skip("no name");
|
|
3340
|
+
continue;
|
|
3341
|
+
}
|
|
3342
|
+
const at = isoOf(observation.startTime);
|
|
3343
|
+
if (!Number.isNaN(sinceMs) && at !== void 0 && Date.parse(at) < sinceMs) {
|
|
3344
|
+
skip("before since");
|
|
3345
|
+
continue;
|
|
3346
|
+
}
|
|
3347
|
+
if (known && !known.has(tool)) {
|
|
3348
|
+
out.unknownTools[tool] = (out.unknownTools[tool] ?? 0) + 1;
|
|
3349
|
+
continue;
|
|
3350
|
+
}
|
|
3351
|
+
const input = jsonish(observation.input);
|
|
3352
|
+
const record = { tool, args: isObject2(input) ? input : {} };
|
|
3353
|
+
if (observation.level === "ERROR") record.error = observation.statusMessage || "ERROR";
|
|
3354
|
+
else record.result = jsonish(observation.output);
|
|
3355
|
+
if (at !== void 0) record.at = at;
|
|
3356
|
+
if (opts.session) record.session = opts.session;
|
|
3357
|
+
record.source = `trace:${observation.traceId ?? "?"}/${observation.id ?? "?"}`;
|
|
3358
|
+
out.records.push(record);
|
|
3359
|
+
}
|
|
3360
|
+
return out;
|
|
3361
|
+
}
|
|
3362
|
+
function credentialsOf(options) {
|
|
3363
|
+
const host = (options.host ?? process.env.GATEWAY_HOST ?? "https://withgateway.ai").replace(/\/+$/, "");
|
|
3364
|
+
const publicKey = options.publicKey ?? process.env.GATEWAY_PUBLIC_KEY;
|
|
3365
|
+
const secretKey = options.secretKey ?? process.env.GATEWAY_SECRET_KEY;
|
|
3366
|
+
return publicKey && secretKey ? { host, publicKey, secretKey } : null;
|
|
3367
|
+
}
|
|
3368
|
+
async function ingest(world, records, options = {}) {
|
|
3369
|
+
const { ingestLocalToolCalls: ingestLocalToolCalls2, importLocalWorldData: importLocalWorldData2, checkLocalWorldData: checkLocalWorldData2 } = await Promise.resolve().then(() => (init_data(), data_exports));
|
|
3370
|
+
if (options.transform !== void 0 && options.map !== void 0) throw new Error("records go through one of transform, map");
|
|
3371
|
+
const redact = options.redact ?? "off";
|
|
3372
|
+
const mode = options.mode ?? "append";
|
|
3373
|
+
const dryRun = Boolean(options.dryRun);
|
|
3374
|
+
const creds = credentialsOf(options);
|
|
3375
|
+
const local = fs8.existsSync(world) && fs8.statSync(world).isDirectory();
|
|
3376
|
+
const map = options.map === void 0 ? void 0 : options.map;
|
|
3377
|
+
let rows = null;
|
|
3378
|
+
let stderr = "";
|
|
3379
|
+
if (options.transform !== void 0) {
|
|
3380
|
+
const { transformRecords: transformRecords2 } = await Promise.resolve().then(() => (init_transform(), transform_exports));
|
|
3381
|
+
({ rows, stderr } = await transformRecords2(options.transform, records, { timeoutMs: options.timeoutMs }));
|
|
3382
|
+
}
|
|
3383
|
+
if (local) {
|
|
3384
|
+
if (rows === null) return reportOf(world, await ingestLocalToolCalls2(world, records, { redact, dryRun, mode, map }, creds), redact);
|
|
3385
|
+
const landed = dryRun ? await checkLocalWorldData2(world, rows, creds, { redact }) : await importLocalWorldData2(world, rows, { mode, redact }, creds);
|
|
3386
|
+
return transformReport(world, records.length, rows, stderr, { dryRun, redact, changed: !dryRun && landed.changed, kind: landed.kind, entityCounts: landed.entity_counts });
|
|
3387
|
+
}
|
|
3388
|
+
if (!creds) throw new Error("Gateway keys missing: set GATEWAY_PUBLIC_KEY / GATEWAY_SECRET_KEY (or pass publicKey/secretKey).");
|
|
3389
|
+
const { pull: pull2 } = await Promise.resolve().then(() => (init_hub(), hub_exports));
|
|
3390
|
+
const slug = world.split("@", 1)[0];
|
|
3391
|
+
const scratch = fs8.mkdtempSync(path7.join(os3.tmpdir(), "gateway-ingest-"));
|
|
3392
|
+
try {
|
|
3393
|
+
const pulled = await pull2(world, path7.join(scratch, slug), options);
|
|
3394
|
+
let report;
|
|
3395
|
+
let projected;
|
|
3396
|
+
if (rows === null) {
|
|
3397
|
+
const proven = await ingestLocalToolCalls2(pulled.dir, records, { redact: "off", dryRun: true, mode, map }, creds);
|
|
3398
|
+
report = reportOf(world, proven, redact);
|
|
3399
|
+
projected = proven.projected ?? {};
|
|
3400
|
+
} else {
|
|
3401
|
+
const proven = await checkLocalWorldData2(pulled.dir, rows, creds);
|
|
3402
|
+
report = transformReport(world, records.length, rows, stderr, { dryRun, redact, changed: false, kind: proven.kind, entityCounts: proven.entity_counts });
|
|
3403
|
+
projected = rows;
|
|
3404
|
+
}
|
|
3405
|
+
report.dryRun = dryRun;
|
|
3406
|
+
if (dryRun || report.refusals.length || !Object.keys(projected).length) return report;
|
|
3407
|
+
const { pushRows: pushRows2 } = await Promise.resolve().then(() => (init_push(), push_exports));
|
|
3408
|
+
const status = await pushRows2(creds, slug, projected, { mode, redact, message: options.message });
|
|
3409
|
+
report.batch = status;
|
|
3410
|
+
report.changed = status.state === "applied" || status.state === "published";
|
|
3411
|
+
if (status.entityCounts) report.entityCounts = status.entityCounts;
|
|
3412
|
+
return report;
|
|
3413
|
+
} finally {
|
|
3414
|
+
fs8.rmSync(scratch, { recursive: true, force: true });
|
|
3415
|
+
}
|
|
3416
|
+
}
|
|
3417
|
+
async function ingestToolCalls(world, records, options = {}) {
|
|
3418
|
+
return ingest(world, records, options);
|
|
3419
|
+
}
|
|
3420
|
+
function transformReport(world, records, rows, stderr, outcome) {
|
|
3421
|
+
return {
|
|
3422
|
+
world,
|
|
3423
|
+
via: "transform",
|
|
3424
|
+
...stderr ? { stderr } : {},
|
|
3425
|
+
records,
|
|
3426
|
+
ingested: records,
|
|
3427
|
+
skipped: {},
|
|
3428
|
+
refusals: [],
|
|
3429
|
+
rows: Object.fromEntries(Object.entries(rows).map(([entity, listed]) => [entity, listed.length])),
|
|
3430
|
+
dryRun: outcome.dryRun,
|
|
3431
|
+
redact: outcome.redact,
|
|
3432
|
+
changed: outcome.changed,
|
|
3433
|
+
...outcome.kind ? { kind: outcome.kind } : {},
|
|
3434
|
+
...outcome.entityCounts ? { entityCounts: outcome.entityCounts } : {}
|
|
3435
|
+
};
|
|
3436
|
+
}
|
|
3437
|
+
function reportOf(world, local, redact) {
|
|
3438
|
+
return {
|
|
3439
|
+
world,
|
|
3440
|
+
...local.via ? { via: local.via } : {},
|
|
3441
|
+
...local.sources ? { sources: local.sources.map(({ unmapped_fields, unset_fields, ...rest }) => ({ ...rest, unmappedFields: unmapped_fields, unsetFields: unset_fields })) } : {},
|
|
3442
|
+
...local.unmatched ? { unmatched: local.unmatched } : {},
|
|
3443
|
+
...local.note ? { note: local.note } : {},
|
|
3444
|
+
records: local.records,
|
|
3445
|
+
ingested: local.ingested,
|
|
3446
|
+
skipped: local.skipped,
|
|
3447
|
+
refusals: local.refusals,
|
|
3448
|
+
rows: local.rows,
|
|
3449
|
+
dryRun: local.dry_run,
|
|
3450
|
+
redact,
|
|
3451
|
+
changed: local.changed,
|
|
3452
|
+
...local.kind ? { kind: local.kind } : {},
|
|
3453
|
+
...local.entity_counts ? { entityCounts: local.entity_counts } : {}
|
|
3454
|
+
};
|
|
3455
|
+
}
|
|
3456
|
+
async function sessionToolObservations(sessionId, options = {}) {
|
|
3457
|
+
const session = await apiRequest(
|
|
3458
|
+
options,
|
|
3459
|
+
"GET",
|
|
3460
|
+
`/api/public/sessions/${encodeURIComponent(sessionId)}?includeIO=true`
|
|
3461
|
+
);
|
|
3462
|
+
const out = [];
|
|
3463
|
+
for (const trace of session.traces ?? [])
|
|
3464
|
+
for (const observation of trace.observations ?? []) out.push({ traceId: trace.id ?? null, ...observation });
|
|
3465
|
+
return out;
|
|
3466
|
+
}
|
|
3467
|
+
var fs8, os3, path7, isObject2, isoOf;
|
|
3468
|
+
var init_ingest = __esm({
|
|
3469
|
+
"src/worlds/ingest.ts"() {
|
|
3470
|
+
"use strict";
|
|
3471
|
+
fs8 = __toESM(require("fs"));
|
|
3472
|
+
os3 = __toESM(require("os"));
|
|
3473
|
+
path7 = __toESM(require("path"));
|
|
3474
|
+
init_worlds();
|
|
3475
|
+
isObject2 = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
|
|
3476
|
+
isoOf = (value) => value instanceof Date ? value.toISOString() : typeof value === "string" ? value : void 0;
|
|
3477
|
+
}
|
|
3478
|
+
});
|
|
3479
|
+
|
|
1692
3480
|
// src/worlds/index.ts
|
|
1693
3481
|
var worlds_exports = {};
|
|
1694
3482
|
__export(worlds_exports, {
|
|
@@ -1699,7 +3487,10 @@ __export(worlds_exports, {
|
|
|
1699
3487
|
EVENT_BATCH_SIZE: () => EVENT_BATCH_SIZE,
|
|
1700
3488
|
EVENT_FLUSH_INTERVAL_MS: () => EVENT_FLUSH_INTERVAL_MS,
|
|
1701
3489
|
EVENT_MAX_RETRIES: () => EVENT_MAX_RETRIES,
|
|
3490
|
+
STRIP_PREFIX: () => STRIP_PREFIX,
|
|
1702
3491
|
SURFACE_KINDS: () => SURFACE_KINDS,
|
|
3492
|
+
TRANSFORMS: () => TRANSFORMS,
|
|
3493
|
+
WHITESPACE: () => WHITESPACE,
|
|
1703
3494
|
WorldBrowser: () => WorldBrowser,
|
|
1704
3495
|
WorldSession: () => WorldSession,
|
|
1705
3496
|
WorldSessionCallError: () => WorldSessionCallError,
|
|
@@ -1708,8 +3499,10 @@ __export(worlds_exports, {
|
|
|
1708
3499
|
WorldSurfaceUnavailable: () => WorldSurfaceUnavailable,
|
|
1709
3500
|
WorldTask: () => WorldTask,
|
|
1710
3501
|
apiRequest: () => apiRequest,
|
|
3502
|
+
applyTransforms: () => applyTransforms,
|
|
1711
3503
|
attachSession: () => attachSession,
|
|
1712
3504
|
buildSourceTarball: () => buildSourceTarball,
|
|
3505
|
+
captureToolCalls: () => captureToolCalls,
|
|
1713
3506
|
collectArchiveRelPaths: () => collectArchiveRelPaths,
|
|
1714
3507
|
computeContentHash: () => computeContentHash,
|
|
1715
3508
|
computerUseToolkit: () => computerUseToolkit,
|
|
@@ -1717,9 +3510,13 @@ __export(worlds_exports, {
|
|
|
1717
3510
|
createTask: () => createTask,
|
|
1718
3511
|
deleteEnvSecret: () => deleteEnvSecret,
|
|
1719
3512
|
deleteTask: () => deleteTask,
|
|
3513
|
+
describeWorld: () => describeWorld,
|
|
1720
3514
|
detectProvenance: () => detectProvenance,
|
|
1721
3515
|
getRun: () => getRun,
|
|
1722
3516
|
getTask: () => getTask,
|
|
3517
|
+
hashForm: () => hashForm,
|
|
3518
|
+
ingest: () => ingest,
|
|
3519
|
+
ingestToolCalls: () => ingestToolCalls,
|
|
1723
3520
|
isIncludedInContentHash: () => isIncludedInContentHash,
|
|
1724
3521
|
isTaskIdRef: () => isTaskIdRef,
|
|
1725
3522
|
isTaskSpec: () => isTaskSpec,
|
|
@@ -1727,22 +3524,38 @@ __export(worlds_exports, {
|
|
|
1727
3524
|
listRunConfigs: () => listRunConfigs,
|
|
1728
3525
|
listTasks: () => listTasks,
|
|
1729
3526
|
localTreeState: () => localTreeState,
|
|
3527
|
+
migrateProjectWorlds: () => migrateProjectWorlds,
|
|
3528
|
+
migrateWorld: () => migrateWorld,
|
|
1730
3529
|
openBrowser: () => openBrowser,
|
|
1731
3530
|
openSession: () => openSession,
|
|
1732
3531
|
openWorld: () => openWorld,
|
|
3532
|
+
parseToolCallRecord: () => parseToolCallRecord,
|
|
3533
|
+
parseTransform: () => parseTransform,
|
|
1733
3534
|
parseWorldTaskRefs: () => parseWorldTaskRefs,
|
|
3535
|
+
preserveForm: () => preserveForm,
|
|
1734
3536
|
propose: () => propose,
|
|
1735
3537
|
pull: () => pull,
|
|
1736
3538
|
push: () => push,
|
|
3539
|
+
pyText: () => pyText,
|
|
3540
|
+
queryRows: () => queryRows,
|
|
3541
|
+
queryRowsSearch: () => queryRowsSearch,
|
|
1737
3542
|
readLocalMeta: () => readLocalMeta,
|
|
3543
|
+
readToolCallRecords: () => readToolCallRecords,
|
|
1738
3544
|
redactActionArgs: () => redactActionArgs,
|
|
3545
|
+
redactionOf: () => redactionOf,
|
|
1739
3546
|
resolveBrowserMode: () => resolveBrowserMode,
|
|
3547
|
+
roundForm: () => roundForm,
|
|
1740
3548
|
runSessions: () => runSessions,
|
|
1741
3549
|
schemaFromSignature: () => schemaFromSignature,
|
|
3550
|
+
sessionToolObservations: () => sessionToolObservations,
|
|
1742
3551
|
setEnvSecret: () => setEnvSecret,
|
|
3552
|
+
shapeText: () => shapeText,
|
|
1743
3553
|
snapshotTreeHashes: () => snapshotTreeHashes,
|
|
3554
|
+
storedForms: () => storedForms,
|
|
1744
3555
|
surfaceKinds: () => surfaceKinds,
|
|
1745
3556
|
taskLabel: () => taskLabel,
|
|
3557
|
+
toolCallRecordsIn: () => toolCallRecordsIn,
|
|
3558
|
+
toolCallsFromObservations: () => toolCallsFromObservations,
|
|
1746
3559
|
uiEntryUrl: () => uiEntryUrl,
|
|
1747
3560
|
uiUrl: () => uiUrl,
|
|
1748
3561
|
updateTask: () => updateTask,
|
|
@@ -1765,9 +3578,9 @@ function resolveEnv(options) {
|
|
|
1765
3578
|
}
|
|
1766
3579
|
return { host: host.replace(/\/+$/, ""), publicKey, secretKey };
|
|
1767
3580
|
}
|
|
1768
|
-
async function apiRequest(options, method,
|
|
3581
|
+
async function apiRequest(options, method, path8, body) {
|
|
1769
3582
|
const { host, publicKey, secretKey } = resolveEnv(options);
|
|
1770
|
-
const res = await fetch(`${host}${
|
|
3583
|
+
const res = await fetch(`${host}${path8}`, {
|
|
1771
3584
|
method,
|
|
1772
3585
|
headers: {
|
|
1773
3586
|
"content-type": "application/json",
|
|
@@ -1775,13 +3588,13 @@ async function apiRequest(options, method, path2, body) {
|
|
|
1775
3588
|
},
|
|
1776
3589
|
...body === void 0 ? {} : { body: JSON.stringify(body) }
|
|
1777
3590
|
});
|
|
1778
|
-
const
|
|
3591
|
+
const text2 = await res.text();
|
|
1779
3592
|
if (!res.ok) {
|
|
1780
3593
|
throw new Error(
|
|
1781
|
-
`${method} ${
|
|
3594
|
+
`${method} ${path8} -> ${res.status}: ${text2.slice(0, 400)}`
|
|
1782
3595
|
);
|
|
1783
3596
|
}
|
|
1784
|
-
return JSON.parse(
|
|
3597
|
+
return JSON.parse(text2);
|
|
1785
3598
|
}
|
|
1786
3599
|
async function setEnvSecret(slug, key, value, options = {}) {
|
|
1787
3600
|
return apiRequest(
|
|
@@ -1862,7 +3675,7 @@ async function waitForRun(runId, opts = {}) {
|
|
|
1862
3675
|
);
|
|
1863
3676
|
opts.onTick?.(run);
|
|
1864
3677
|
await new Promise(
|
|
1865
|
-
(
|
|
3678
|
+
(resolve6) => setTimeout(resolve6, (opts.intervalSeconds ?? 20) * 1e3)
|
|
1866
3679
|
);
|
|
1867
3680
|
}
|
|
1868
3681
|
}
|
|
@@ -1940,6 +3753,12 @@ var init_worlds = __esm({
|
|
|
1940
3753
|
init_browser();
|
|
1941
3754
|
init_hub();
|
|
1942
3755
|
init_validate();
|
|
3756
|
+
init_describe();
|
|
3757
|
+
init_redaction();
|
|
3758
|
+
init_transforms();
|
|
3759
|
+
init_query();
|
|
3760
|
+
init_migrate();
|
|
3761
|
+
init_ingest();
|
|
1943
3762
|
WorldTask = class {
|
|
1944
3763
|
constructor(world, name, variant) {
|
|
1945
3764
|
this.world = world;
|
|
@@ -2014,7 +3833,10 @@ init_worlds();
|
|
|
2014
3833
|
EVENT_BATCH_SIZE,
|
|
2015
3834
|
EVENT_FLUSH_INTERVAL_MS,
|
|
2016
3835
|
EVENT_MAX_RETRIES,
|
|
3836
|
+
STRIP_PREFIX,
|
|
2017
3837
|
SURFACE_KINDS,
|
|
3838
|
+
TRANSFORMS,
|
|
3839
|
+
WHITESPACE,
|
|
2018
3840
|
WorldBrowser,
|
|
2019
3841
|
WorldSession,
|
|
2020
3842
|
WorldSessionCallError,
|
|
@@ -2023,8 +3845,10 @@ init_worlds();
|
|
|
2023
3845
|
WorldSurfaceUnavailable,
|
|
2024
3846
|
WorldTask,
|
|
2025
3847
|
apiRequest,
|
|
3848
|
+
applyTransforms,
|
|
2026
3849
|
attachSession,
|
|
2027
3850
|
buildSourceTarball,
|
|
3851
|
+
captureToolCalls,
|
|
2028
3852
|
collectArchiveRelPaths,
|
|
2029
3853
|
computeContentHash,
|
|
2030
3854
|
computerUseToolkit,
|
|
@@ -2032,9 +3856,13 @@ init_worlds();
|
|
|
2032
3856
|
createTask,
|
|
2033
3857
|
deleteEnvSecret,
|
|
2034
3858
|
deleteTask,
|
|
3859
|
+
describeWorld,
|
|
2035
3860
|
detectProvenance,
|
|
2036
3861
|
getRun,
|
|
2037
3862
|
getTask,
|
|
3863
|
+
hashForm,
|
|
3864
|
+
ingest,
|
|
3865
|
+
ingestToolCalls,
|
|
2038
3866
|
isIncludedInContentHash,
|
|
2039
3867
|
isTaskIdRef,
|
|
2040
3868
|
isTaskSpec,
|
|
@@ -2042,22 +3870,38 @@ init_worlds();
|
|
|
2042
3870
|
listRunConfigs,
|
|
2043
3871
|
listTasks,
|
|
2044
3872
|
localTreeState,
|
|
3873
|
+
migrateProjectWorlds,
|
|
3874
|
+
migrateWorld,
|
|
2045
3875
|
openBrowser,
|
|
2046
3876
|
openSession,
|
|
2047
3877
|
openWorld,
|
|
3878
|
+
parseToolCallRecord,
|
|
3879
|
+
parseTransform,
|
|
2048
3880
|
parseWorldTaskRefs,
|
|
3881
|
+
preserveForm,
|
|
2049
3882
|
propose,
|
|
2050
3883
|
pull,
|
|
2051
3884
|
push,
|
|
3885
|
+
pyText,
|
|
3886
|
+
queryRows,
|
|
3887
|
+
queryRowsSearch,
|
|
2052
3888
|
readLocalMeta,
|
|
3889
|
+
readToolCallRecords,
|
|
2053
3890
|
redactActionArgs,
|
|
3891
|
+
redactionOf,
|
|
2054
3892
|
resolveBrowserMode,
|
|
3893
|
+
roundForm,
|
|
2055
3894
|
runSessions,
|
|
2056
3895
|
schemaFromSignature,
|
|
3896
|
+
sessionToolObservations,
|
|
2057
3897
|
setEnvSecret,
|
|
3898
|
+
shapeText,
|
|
2058
3899
|
snapshotTreeHashes,
|
|
3900
|
+
storedForms,
|
|
2059
3901
|
surfaceKinds,
|
|
2060
3902
|
taskLabel,
|
|
3903
|
+
toolCallRecordsIn,
|
|
3904
|
+
toolCallsFromObservations,
|
|
2061
3905
|
uiEntryUrl,
|
|
2062
3906
|
uiUrl,
|
|
2063
3907
|
updateTask,
|