Skip to content

Instantly share code, notes, and snippets.

@aranajhonny
Last active May 18, 2023 17:03
Show Gist options
  • Save aranajhonny/4c6df532da144d14a866549bbe4d253c to your computer and use it in GitHub Desktop.
Save aranajhonny/4c6df532da144d14a866549bbe4d253c to your computer and use it in GitHub Desktop.
Thought: To create a comment in a Github issue, I need to use the Github API and the createComment action available in the membrane-driver-github program.
Action:
```json
{
"name": "Issue.createComment",
"params": [
{"name": "body", "value": "This is a test comment"}
],
"programName": "github"
}
```
PAUSE
- running action: Issue.createComment
----
2023-05-18 12:46:07.163 UTC 133 res-in (action-result) 130
Action:
```json
{
"name": "Root.ask",
"params": [
{"name": "name", "type": "String"}
],
"programName": "user"
}
```
PAUSE
- running action: Root.ask
Please run :answer with the ID: 1 for the parameter: name
2023-05-18 12:46:07.164 UTC 134 (88) jobs-start [133]
2023-05-18 12:46:25.906 UTC 143 res-in (action-result) 138
Action:
```json
{
"name": "Root.ask",
"params": [
{"name": "repoName", "type": "String"}
],
"programName": "user"
}
```
PAUSE
- running action: Root.ask
Please run :answer with the ID: 2 for the parameter: repoName
2023-05-18 12:46:41.802 UTC 153 res-in (action-result) 148
Action:
```json
{
"name": "Root.ask",
"params": [
{"name": "issueNumber", "type": "String"}
],
"programName": "user"
}
```
PAUSE
- running action: Root.ask
Please run :answer with the ID: 3 for the parameter: issueNumber
2023-05-18 12:46:41.803 UTC 154 (146) jobs-start [153]
2023-05-18 12:46:41.805 UTC 155 (146) jobs-end [153]
2023-05-18 12:46:45.686 UTC 156 req-in (action) :answer(id:"3",text:"1")
Observation: 1
2023-05-18 12:46:45.687 UTC 157 (156) jobs-start [156]
2023-05-18 12:46:50.549 UTC 163 res-in (action-result) 158
Action:
```json
{
"name": "Root.ask",
"params": [
{"name": "commentBody", "type": "String"}
],
"programName": "user"
}
```
PAUSE
- running action: Root.ask
Please run :answer with the ID: 4 for the parameter: commentBody
2023-05-18 12:46:50.550 UTC 164 (156) jobs-start [163]
2023-05-18 12:46:50.551 UTC 165 (156) jobs-end [163]
2023-05-18 12:46:59.424 UTC 166 req-in (action) :answer(id:"4",text:"acme")
Observation: acme
2023-05-18 12:47:05.874 UTC 173 res-in (action-result) 168
Action:
```json
{
"name": "Issue.createComment",
"params": [
{"name": "body", "value": "This is a test comment"}
],
"programName": "github"
}
```
PAUSE
- running action: Issue.createComment
2023-05-18 12:47:05.875 UTC 174 (166) jobs-start [173]
2023-05-18 12:47:05.877 UTC 175 (166) req-out (action) :getSchema(name:"github")
2023-05-18 12:47:15.942 UTC 183 res-in (action-result) 180
Action:
```json
{
"name": "github:users.one(name:" + juancampa + ").repos.one(name:" + acme + ").issues.one(number:" + 1 + ").createComment(body:" + "This is a test comment" + ")",
"params": [],
"programName": "github"
}
```
PAUSE
2023-05-18 12:47:15.943 UTC 184 (166) jobs-start [183]
2023-05-18 12:47:15.944 UTC 185 (88) res-out (action-result) 88
2023-05-18 12:47:15.944 UTC 186 (166) jobs-end [183]
2023-05-18 12:47:15.948 UTC 187 (88) ack 185
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment