gravity-cli 0.4.0__tar.gz → 0.4.2__tar.gz
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.
- gravity_cli-0.4.0/README.md → gravity_cli-0.4.2/PKG-INFO +44 -1
- gravity_cli-0.4.0/PKG-INFO → gravity_cli-0.4.2/README.md +27 -18
- gravity_cli-0.4.2/dist-schema/.gitignore +1 -0
- gravity_cli-0.4.2/dist-schema/gravity_schema-0.4.2-py3-none-any.whl +0 -0
- gravity_cli-0.4.2/dist-schema/gravity_schema-0.4.2.tar.gz +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/catalog.yaml +8 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/manifest.py +14 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/pyproject.toml +1 -1
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/schema/manifest.schema.json +1 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/pyproject.toml +2 -2
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/BUILDER_GUIDE.md +12 -1
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/uv.lock +2 -2
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/.env.example +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/.github/workflows/ci.yml +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/.github/workflows/release.yml +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/.gitignore +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/AGENT_STANDARD.md +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/LICENSE +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/NOTICE +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/TEMPLATES.md +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/LICENSE +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/NOTICE +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/README.md +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/__init__.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/__main__.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/catalog.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/catalog_imported.yaml +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/contract.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/cron.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/errors.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/export.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/gen_catalog.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/validation.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/tests/conftest.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/tests/test_catalog_parity.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/tests/test_cron.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/tests/test_errors.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/tests/test_json_schema.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/tests/test_kind_outputs.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/tests/test_manifest.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/tests/test_slots.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/tests/test_validation.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/__init__.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/__main__.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/_runner_script.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/api.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/cli.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/commands/__init__.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/commands/adapt.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/commands/build.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/commands/guide.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/commands/init.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/commands/login.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/commands/push.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/commands/run.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/commands/runs.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/commands/schedule.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/commands/tools.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/commands/validate.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/config.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/manifest.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/project.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/chat/.gitignore +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/chat/manifest.yaml +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/chat/requirements.txt +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/chat/src/agent.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/deepagent/.gitignore +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/deepagent/manifest.yaml +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/deepagent/requirements.txt +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/deepagent/src/agent.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/minimal/.gitignore +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/minimal/manifest.yaml +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/minimal/requirements.txt +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/minimal/src/agent.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/structured/.gitignore +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/structured/manifest.yaml +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/structured/requirements.txt +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/structured/src/agent.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/structured/src/gateway.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/structured/src/nodes/agent.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/structured/src/prompts.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/structured/src/state.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/timeline.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/ui.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/starter/manifest.yaml +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/starter/requirements.txt +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/starter/src/agent.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/starter/src/summary.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/starter/tests/test_summary.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/tests/conftest.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/tests/test_adapt.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/tests/test_api.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/tests/test_build_push.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/tests/test_gateway_token.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/tests/test_manifest_integration.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/tests/test_run.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/tests/test_templates.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/tests/test_timeline.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/tests/test_ui.py +0 -0
- {gravity_cli-0.4.0 → gravity_cli-0.4.2}/tests/test_welcome.py +0 -0
|
@@ -1,3 +1,20 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: gravity-cli
|
|
3
|
+
Version: 0.4.2
|
|
4
|
+
Summary: gravity cli — init, run, and push python agents to the Gravity marketplace
|
|
5
|
+
License-Expression: Apache-2.0
|
|
6
|
+
License-File: LICENSE
|
|
7
|
+
License-File: NOTICE
|
|
8
|
+
Requires-Python: >=3.12
|
|
9
|
+
Requires-Dist: gravity-schema==0.4.2
|
|
10
|
+
Requires-Dist: httpx>=0.27.0
|
|
11
|
+
Requires-Dist: keyring>=25.0.0
|
|
12
|
+
Requires-Dist: python-dotenv>=1.0.0
|
|
13
|
+
Requires-Dist: rich>=13.9.0
|
|
14
|
+
Requires-Dist: typer>=0.15.0
|
|
15
|
+
Requires-Dist: uv>=0.8.0
|
|
16
|
+
Description-Content-Type: text/markdown
|
|
17
|
+
|
|
1
18
|
<h1 align="center">Gravity CLI</h1>
|
|
2
19
|
|
|
3
20
|
<p align="center">
|
|
@@ -625,7 +642,7 @@ outputs: # extra formats the platform renders and deliv
|
|
|
625
642
|
| `runtime.timeout_seconds` | no | `300` | 10 to 28800. |
|
|
626
643
|
| `dependencies.lockfile` | no | `requirements.lock` | Compiled by `gravity validate`; ships with the agent. |
|
|
627
644
|
| `inputs[]` | no | none | Up to 50. Each has `name` (a lowercase identifier, the key in `state["inputs"]`), `type`, `label`, and optionally `required`, `default`, `options`, `accept`. |
|
|
628
|
-
| `inputs[].type` | **yes** | | `text`, `textarea`, `number`, `boolean`, `static-dropdown` (needs `options`), `email`, `url`, `date` or `file` (no `default`; `accept` lists extensions such as `[pdf, csv]`). |
|
|
645
|
+
| `inputs[].type` | **yes** | | `text`, `textarea`, `number`, `boolean`, `static-dropdown` (needs `options`), `email`, `url`, `date`, `secret` (an API key or password: masked, sealed with KMS, never shown back; no `default`) or `file` (no `default`; `accept` lists extensions such as `[pdf, csv]`). |
|
|
629
646
|
| `permissions.tools` | no | none | Up to 50 catalog names, such as `gmail.read`. Run `gravity tools` for the list. |
|
|
630
647
|
| `permissions.models.tier` | no | `standard` | `standard` or `premium`. |
|
|
631
648
|
| `approvals.required_for` | no | none | Tools that pause until a person approves. Each must also be declared under `permissions.tools` or a slot adapter. |
|
|
@@ -639,6 +656,27 @@ outputs: # extra formats the platform renders and deliv
|
|
|
639
656
|
|
|
640
657
|
Unknown fields are rejected rather than ignored, so a typo is reported instead of silently dropped.
|
|
641
658
|
|
|
659
|
+
### Secret inputs
|
|
660
|
+
|
|
661
|
+
**API keys and passwords: use `type: secret`**, never `text`. The user types it into a masked box;
|
|
662
|
+
the platform seals it with AWS KMS the moment it is submitted, keeps it out of every API response,
|
|
663
|
+
log and stored checkpoint, and decrypts it only to hand it to your running agent as
|
|
664
|
+
`state["inputs"]["<name>"]`, exactly like any other input. A secret input cannot have a `default`,
|
|
665
|
+
holds at most 4096 bytes, and is meant for the user's own credential for a service your agent
|
|
666
|
+
calls (their Supadata or Notion key), not for a key of yours: yours never goes in the agent or its
|
|
667
|
+
manifest. Two rules for your code: don't put the key in `result` or `corpus` (they are shown
|
|
668
|
+
to the user and stored in clear), and don't copy it into your own objects or logs: the platform
|
|
669
|
+
can hide it in the state it checkpoints, not wherever your code sends it. When the user schedules
|
|
670
|
+
the agent, they re-enter the key to change it; it is never shown back.
|
|
671
|
+
|
|
672
|
+
```yaml
|
|
673
|
+
inputs:
|
|
674
|
+
- name: supadata_api_key
|
|
675
|
+
type: secret
|
|
676
|
+
label: "Your Supadata API key"
|
|
677
|
+
required: true
|
|
678
|
+
```
|
|
679
|
+
|
|
642
680
|
## An agent project
|
|
643
681
|
|
|
644
682
|
```
|
|
@@ -712,6 +750,11 @@ Real tools act on a connected account. Connect one with `gravity-gateway connect
|
|
|
712
750
|
| `✗ requirements.lock` in `gravity validate` | A dependency has no prebuilt package for the platform image (ARM64 Linux). Pick a version that publishes one, or a different package. |
|
|
713
751
|
| A tool row shows `refused — not in permissions.tools` | The agent called a tool its manifest does not declare. Add it under `permissions.tools`, then run again. |
|
|
714
752
|
|
|
753
|
+
## What's new
|
|
754
|
+
|
|
755
|
+
- **0.4.2** Documents `type: secret` (below) and the `supadata.get_transcript` tool.
|
|
756
|
+
- **0.4.1** `type: secret` inputs: API keys and passwords the user enters are sealed with AWS KMS on the platform, never shown back, and handed only to the running agent. New built-in tool `supadata.get_transcript` (`gravity tools supadata`).
|
|
757
|
+
|
|
715
758
|
## Limitations
|
|
716
759
|
|
|
717
760
|
- **No offline mode.** `gravity run` always talks to a real gateway. There is no mock-tool mode.
|
|
@@ -1,20 +1,3 @@
|
|
|
1
|
-
Metadata-Version: 2.5
|
|
2
|
-
Name: gravity-cli
|
|
3
|
-
Version: 0.4.0
|
|
4
|
-
Summary: gravity cli — init, run, and push python agents to the Gravity marketplace
|
|
5
|
-
License-Expression: Apache-2.0
|
|
6
|
-
License-File: LICENSE
|
|
7
|
-
License-File: NOTICE
|
|
8
|
-
Requires-Python: >=3.12
|
|
9
|
-
Requires-Dist: gravity-schema==0.4.0
|
|
10
|
-
Requires-Dist: httpx>=0.27.0
|
|
11
|
-
Requires-Dist: keyring>=25.0.0
|
|
12
|
-
Requires-Dist: python-dotenv>=1.0.0
|
|
13
|
-
Requires-Dist: rich>=13.9.0
|
|
14
|
-
Requires-Dist: typer>=0.15.0
|
|
15
|
-
Requires-Dist: uv>=0.8.0
|
|
16
|
-
Description-Content-Type: text/markdown
|
|
17
|
-
|
|
18
1
|
<h1 align="center">Gravity CLI</h1>
|
|
19
2
|
|
|
20
3
|
<p align="center">
|
|
@@ -642,7 +625,7 @@ outputs: # extra formats the platform renders and deliv
|
|
|
642
625
|
| `runtime.timeout_seconds` | no | `300` | 10 to 28800. |
|
|
643
626
|
| `dependencies.lockfile` | no | `requirements.lock` | Compiled by `gravity validate`; ships with the agent. |
|
|
644
627
|
| `inputs[]` | no | none | Up to 50. Each has `name` (a lowercase identifier, the key in `state["inputs"]`), `type`, `label`, and optionally `required`, `default`, `options`, `accept`. |
|
|
645
|
-
| `inputs[].type` | **yes** | | `text`, `textarea`, `number`, `boolean`, `static-dropdown` (needs `options`), `email`, `url`, `date` or `file` (no `default`; `accept` lists extensions such as `[pdf, csv]`). |
|
|
628
|
+
| `inputs[].type` | **yes** | | `text`, `textarea`, `number`, `boolean`, `static-dropdown` (needs `options`), `email`, `url`, `date`, `secret` (an API key or password: masked, sealed with KMS, never shown back; no `default`) or `file` (no `default`; `accept` lists extensions such as `[pdf, csv]`). |
|
|
646
629
|
| `permissions.tools` | no | none | Up to 50 catalog names, such as `gmail.read`. Run `gravity tools` for the list. |
|
|
647
630
|
| `permissions.models.tier` | no | `standard` | `standard` or `premium`. |
|
|
648
631
|
| `approvals.required_for` | no | none | Tools that pause until a person approves. Each must also be declared under `permissions.tools` or a slot adapter. |
|
|
@@ -656,6 +639,27 @@ outputs: # extra formats the platform renders and deliv
|
|
|
656
639
|
|
|
657
640
|
Unknown fields are rejected rather than ignored, so a typo is reported instead of silently dropped.
|
|
658
641
|
|
|
642
|
+
### Secret inputs
|
|
643
|
+
|
|
644
|
+
**API keys and passwords: use `type: secret`**, never `text`. The user types it into a masked box;
|
|
645
|
+
the platform seals it with AWS KMS the moment it is submitted, keeps it out of every API response,
|
|
646
|
+
log and stored checkpoint, and decrypts it only to hand it to your running agent as
|
|
647
|
+
`state["inputs"]["<name>"]`, exactly like any other input. A secret input cannot have a `default`,
|
|
648
|
+
holds at most 4096 bytes, and is meant for the user's own credential for a service your agent
|
|
649
|
+
calls (their Supadata or Notion key), not for a key of yours: yours never goes in the agent or its
|
|
650
|
+
manifest. Two rules for your code: don't put the key in `result` or `corpus` (they are shown
|
|
651
|
+
to the user and stored in clear), and don't copy it into your own objects or logs: the platform
|
|
652
|
+
can hide it in the state it checkpoints, not wherever your code sends it. When the user schedules
|
|
653
|
+
the agent, they re-enter the key to change it; it is never shown back.
|
|
654
|
+
|
|
655
|
+
```yaml
|
|
656
|
+
inputs:
|
|
657
|
+
- name: supadata_api_key
|
|
658
|
+
type: secret
|
|
659
|
+
label: "Your Supadata API key"
|
|
660
|
+
required: true
|
|
661
|
+
```
|
|
662
|
+
|
|
659
663
|
## An agent project
|
|
660
664
|
|
|
661
665
|
```
|
|
@@ -729,6 +733,11 @@ Real tools act on a connected account. Connect one with `gravity-gateway connect
|
|
|
729
733
|
| `✗ requirements.lock` in `gravity validate` | A dependency has no prebuilt package for the platform image (ARM64 Linux). Pick a version that publishes one, or a different package. |
|
|
730
734
|
| A tool row shows `refused — not in permissions.tools` | The agent called a tool its manifest does not declare. Add it under `permissions.tools`, then run again. |
|
|
731
735
|
|
|
736
|
+
## What's new
|
|
737
|
+
|
|
738
|
+
- **0.4.2** Documents `type: secret` (below) and the `supadata.get_transcript` tool.
|
|
739
|
+
- **0.4.1** `type: secret` inputs: API keys and passwords the user enters are sealed with AWS KMS on the platform, never shown back, and handed only to the running agent. New built-in tool `supadata.get_transcript` (`gravity tools supadata`).
|
|
740
|
+
|
|
732
741
|
## Limitations
|
|
733
742
|
|
|
734
743
|
- **No offline mode.** `gravity run` always talks to a real gateway. There is no mock-tool mode.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
*
|
|
Binary file
|
|
Binary file
|
|
@@ -27,6 +27,14 @@
|
|
|
27
27
|
guarantee: certified
|
|
28
28
|
side_effect: read
|
|
29
29
|
|
|
30
|
+
- name: supadata.get_transcript
|
|
31
|
+
slug: null
|
|
32
|
+
description: fetch the transcript of a YouTube video with the caller's own Supadata API key (api_key argument)
|
|
33
|
+
scopes: []
|
|
34
|
+
breadth: niche
|
|
35
|
+
guarantee: certified
|
|
36
|
+
side_effect: read
|
|
37
|
+
|
|
30
38
|
- name: gmail.read
|
|
31
39
|
slug: GMAIL_FETCH_EMAILS
|
|
32
40
|
description: read the connected Gmail inbox
|
|
@@ -26,6 +26,9 @@ class InputType(str, Enum):
|
|
|
26
26
|
EMAIL = "email"
|
|
27
27
|
URL = "url"
|
|
28
28
|
DATE = "date"
|
|
29
|
+
# An API key or password. The platform seals it with KMS when it is submitted, keeps it
|
|
30
|
+
# out of every API response and log, and opens it only to hand it to the running agent.
|
|
31
|
+
SECRET = "secret"
|
|
29
32
|
# The agent gets a short-lived URL it fetches through the gateway.
|
|
30
33
|
FILE = "file"
|
|
31
34
|
|
|
@@ -40,6 +43,7 @@ _PYTHON_TYPES: dict[InputType, tuple[type, ...]] = {
|
|
|
40
43
|
InputType.EMAIL: (str,),
|
|
41
44
|
InputType.URL: (str,),
|
|
42
45
|
InputType.DATE: (str,),
|
|
46
|
+
InputType.SECRET: (str,),
|
|
43
47
|
InputType.FILE: (), # never has a default
|
|
44
48
|
}
|
|
45
49
|
|
|
@@ -254,6 +258,16 @@ class InputSpec(BaseModel):
|
|
|
254
258
|
},
|
|
255
259
|
)
|
|
256
260
|
|
|
261
|
+
if self.type is InputType.SECRET:
|
|
262
|
+
raise PydanticCustomError(
|
|
263
|
+
ErrorCode.INVALID_INPUT.value,
|
|
264
|
+
"Secret input '{value}' cannot have a default.",
|
|
265
|
+
{
|
|
266
|
+
"value": self.name,
|
|
267
|
+
"remediation": "Remove the default; the consumer enters the secret for each run or schedule.",
|
|
268
|
+
},
|
|
269
|
+
)
|
|
270
|
+
|
|
257
271
|
expected = _PYTHON_TYPES[self.type]
|
|
258
272
|
# bool is an int subclass, so NUMBER needs this guard.
|
|
259
273
|
is_bool = isinstance(self.default, bool)
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "gravity-cli"
|
|
3
|
-
version = "0.4.
|
|
3
|
+
version = "0.4.2"
|
|
4
4
|
description = "gravity cli — init, run, and push python agents to the Gravity marketplace"
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
license = "Apache-2.0"
|
|
7
7
|
license-files = ["LICENSE", "NOTICE"]
|
|
8
8
|
requires-python = ">=3.12"
|
|
9
9
|
dependencies = [
|
|
10
|
-
"gravity-schema==0.4.
|
|
10
|
+
"gravity-schema==0.4.2", # released in lockstep: always the same version as this package
|
|
11
11
|
"typer>=0.15.0",
|
|
12
12
|
"httpx>=0.27.0",
|
|
13
13
|
"rich>=13.9.0",
|
|
@@ -81,7 +81,7 @@ dependencies:
|
|
|
81
81
|
|
|
82
82
|
inputs: # becomes the user's form; arrives as state["inputs"]
|
|
83
83
|
- name: send_to
|
|
84
|
-
type: email # text | textarea | number | boolean | static-dropdown | email | url | date | file
|
|
84
|
+
type: email # text | textarea | number | boolean | static-dropdown | email | url | date | secret | file
|
|
85
85
|
label: "Where to send the digest"
|
|
86
86
|
required: true
|
|
87
87
|
|
|
@@ -127,6 +127,17 @@ keeps the digest as a draft for the user to send. That's why the fallback in §3
|
|
|
127
127
|
Other input fields you can use: `default:` (a value if the user leaves it blank; not for `file`),
|
|
128
128
|
`options: [a, b]` (for `static-dropdown`), `accept: [pdf, csv]` (for `file`).
|
|
129
129
|
|
|
130
|
+
**API keys and passwords: use `type: secret`**, never `text`. The user types it into a masked box;
|
|
131
|
+
the platform seals it with AWS KMS the moment it is submitted, keeps it out of every API response,
|
|
132
|
+
log and stored checkpoint, and decrypts it only to hand it to your running agent as
|
|
133
|
+
`state["inputs"]["<name>"]`, exactly like any other input. A secret input cannot have a `default`,
|
|
134
|
+
holds at most 4096 bytes, and is meant for the user's own credential for a service your agent
|
|
135
|
+
calls (their Supadata or Notion key), not for a key of yours: yours never goes in the agent or its
|
|
136
|
+
manifest. Two rules for your code: don't put the key in `result` or `corpus` (they are shown
|
|
137
|
+
to the user and stored in clear), and don't copy it into your own objects or logs: the platform
|
|
138
|
+
can hide it in the state it checkpoints, not wherever your code sends it. When the user schedules
|
|
139
|
+
the agent, they re-enter the key to change it; it is never shown back.
|
|
140
|
+
|
|
130
141
|
### 3.2 `requirements.txt`
|
|
131
142
|
|
|
132
143
|
```
|
|
@@ -164,7 +164,7 @@ wheels = [
|
|
|
164
164
|
|
|
165
165
|
[[package]]
|
|
166
166
|
name = "gravity-cli"
|
|
167
|
-
version = "0.4.
|
|
167
|
+
version = "0.4.2"
|
|
168
168
|
source = { editable = "." }
|
|
169
169
|
dependencies = [
|
|
170
170
|
{ name = "gravity-schema" },
|
|
@@ -201,7 +201,7 @@ dev = [
|
|
|
201
201
|
|
|
202
202
|
[[package]]
|
|
203
203
|
name = "gravity-schema"
|
|
204
|
-
version = "0.4.
|
|
204
|
+
version = "0.4.2"
|
|
205
205
|
source = { editable = "packages/gravity-schema" }
|
|
206
206
|
dependencies = [
|
|
207
207
|
{ name = "pydantic" },
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/catalog_imported.yaml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/gen_catalog.py
RENAMED
|
File without changes
|
{gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/gravity_schema/validation.py
RENAMED
|
File without changes
|
|
File without changes
|
{gravity_cli-0.4.0 → gravity_cli-0.4.2}/packages/gravity-schema/tests/test_catalog_parity.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/deepagent/requirements.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/structured/requirements.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{gravity_cli-0.4.0 → gravity_cli-0.4.2}/src/gravity_cli/templates/structured/src/nodes/agent.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|