Description Usage Arguments Details Value Examples
This function creates a new card in the specified column in a project in GitHub. The card can either contain an existing issue or pull request or you can create a note.
1 2 3 4 5 6 7 8 9 10 11 | create_card(
content_id,
content_type,
note,
column,
project,
repo,
user,
org,
...
)
|
content_id |
(integer, optional) The issue or pull request id associated
with this card. Note: |
content_type |
(string, optional) Whether the |
note |
(string, optional) The card's note content. Not used if
|
column |
(integer or string) Either the ID or name of the column. |
project |
(integer or string) Either the project number or name. |
repo |
(string, optional) The repository specified in the format:
|
user |
(string, optional) The login of the user. |
org |
(string, optional) The name of the organization. |
... |
Parameters passed to |
You can create a card in a project associated with either a repository, user or organization, by supplying them as an input, as long as you have appropriate permissions.
For more details see the GitHub API documentation:
create_card()
returns a list of the card properties.
Card Properties:
id: The ID of the card.
content_id: The ID of the issue or pull request.
note: The content of a note.
archived: Whether the card has been archived.
creator: The creator of the note.
created_at: When it was created.
updated_at: When it was last updated.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | ## Not run:
# Create an issue card in a repository project
create_card(
content_id = 1,
content_type = "Issue",
column = "Test column",
project = "Test project",
repo = "ChadGoymer/githapi"
)
# Create a pull request card in a user's project
create_card(
content_id = 2,
content_type = "PullRequest",
column = "Test column",
project = "Test project",
user = "ChadGoymer"
)
# Create a note card in an organization's project
create_card(
note = "This is a note",
column = "Test column",
project = "Test project",
org = "HairyCoos"
)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.