Created
June 13, 2024 07:32
-
-
Save sdiepend/d6d3c23cf850391b94dd52b039855ad4 to your computer and use it in GitHub Desktop.
Create a draftissue in Github Projects
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
query_draftissue = f''' | |
mutation {{ | |
addProjectV2DraftIssue(input: {{ projectId: "{gh_project_id}" title: "{title}" body: "{body}" }}) {{ | |
projectItem {{ | |
id | |
}} | |
}} | |
}} | |
''' | |
json_draftissue = { 'query' : query_draftissue } | |
response_draftissue = requests.post(url=url, json=json_draftissue, headers=headers) | |
print(response_draftissue.text) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment