Correct project item CLI payload

61fccd016ed6 · AtlantisPleb · · parent 9555dad8f442

Correct project item CLI payload

Deploy story

What this commit did to the running system — joined from the forge receipt chain, the part a commit page elsewhere cannot show.

built
1 modules in 22.3 s
deployed
failed · 1 module on 3 nodes · push→live —

Changed files

  • modified docs/openagents-cli/api.md
  • modified priv/docs/cli-api.md
  • modified test/openagents_web/docs_catalog_test.exs

Diff

3 files changed, +8 -7

docs/openagents-cli/api.md modified +3 -3

@@ -151,11 +151,11 @@ openagents api -X POST -f title="Release readiness" \

151 151
  repos/OWNER/REPOSITORY/projectsV2
152 152
```
153 153
154
Add an issue to a project. `issue_id` is the issue's numeric database ID from
155
the issue response, not its repository-local issue number:
154
Add an issue to a project. `issue_number` is the repository-local issue number,
155
such as `11` in `repos/OWNER/REPOSITORY/issues/11`:
156 156
157 157
```sh
158
printf '%s' '{"issue_id":42,"values":{"Status":"To Do"}}' | \
158
printf '%s' '{"issue_number":11,"values":{"Status":"To Do"}}' | \
159 159
  openagents api -X POST --input - \
160 160
  repos/OWNER/REPOSITORY/projectsV2/PROJECT_NUMBER/items
161 161
```
priv/docs/cli-api.md modified +3 -3

@@ -104,14 +104,14 @@ openagents api repos/OWNER/REPOSITORY/projectsV2/PROJECT_NUMBER/items

104 104
openagents api repos/OWNER/REPOSITORY/projectsV2/PROJECT_NUMBER/fields
105 105
```
106 106
107
Create a project and add an issue. `issue_id` is the numeric database ID in the
108
issue response, not its repository-local issue number:
107
Create a project and add an issue. `issue_number` is the repository-local issue
108
number, such as `11` in `repos/OWNER/REPOSITORY/issues/11`:
109 109
110 110
```sh
111 111
openagents api -X POST -f title="Release readiness" \
112 112
  repos/OWNER/REPOSITORY/projectsV2
113 113
114
printf '%s' '{"issue_id":42,"values":{"Status":"To Do"}}' | \
114
printf '%s' '{"issue_number":11,"values":{"Status":"To Do"}}' | \
115 115
  openagents api -X POST --input - \
116 116
  repos/OWNER/REPOSITORY/projectsV2/PROJECT_NUMBER/items
117 117
```
test/openagents_web/docs_catalog_test.exs modified +2 -1

@@ -88,7 +88,8 @@ defmodule OpenAgentsWeb.DocsCatalogTest do

88 88
    assert api.markdown =~ "openagents api"
89 89
    assert api.markdown =~ ".issues[]"
90 90
    assert api.markdown =~ "projectsV2/PROJECT_NUMBER/items"
91
    assert api.markdown =~ "numeric database ID"
91
    assert api.markdown =~ ~s({"issue_number":11)
92
    refute api.markdown =~ ~s({"issue_id":42)
92 93
    assert api.markdown =~ "does not provide `openagents issue`"
93 94
    assert api.markdown =~ "`openagents project` commands"
94 95
  end

This page updates live while a promote is in flight · changelog