-
Notifications
You must be signed in to change notification settings - Fork 5.5k
[FEATURE] New Trello action #17813
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
[FEATURE] New Trello action #17813
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,173 @@ | ||
import common from "../common/common.mjs"; | ||
import fields from "../../common/fields.mjs"; | ||
|
||
export default { | ||
...common, | ||
key: "trello-get-board", | ||
name: "Get Board", | ||
description: "Request a single board. [See the documentation](https://developer.atlassian.com/cloud/trello/rest/api-group-boards/#api-boards-id-get).", | ||
version: "0.0.1", | ||
type: "action", | ||
props: { | ||
...common.props, | ||
boardId: { | ||
propDefinition: [ | ||
common.props.app, | ||
"board", | ||
], | ||
label: "Board ID", | ||
description: "The ID of the board to retrieve", | ||
}, | ||
actions: { | ||
propDefinition: [ | ||
common.props.app, | ||
"actions", | ||
], | ||
}, | ||
boardStars: { | ||
type: "string", | ||
label: "Board Stars", | ||
description: "Valid values are one of: `mine` or `none`. Default is `none`.", | ||
options: [ | ||
"mine", | ||
"none", | ||
], | ||
optional: true, | ||
}, | ||
cardPluginData: { | ||
type: "boolean", | ||
label: "Card Plugin Data", | ||
description: "Use with the cards param to include card pluginData with the response. Default is `none`.", | ||
optional: true, | ||
}, | ||
customFields: { | ||
type: "boolean", | ||
label: "Custom Fields", | ||
description: "This is a nested resource. Include custom fields in the response.", | ||
default: false, | ||
optional: true, | ||
}, | ||
fields: { | ||
type: "string[]", | ||
label: "Fields", | ||
description: "The fields of the board to be included in the response. Valid values: all or a comma-separated list of specific fields.", | ||
options: fields.board, | ||
optional: true, | ||
}, | ||
labels: { | ||
type: "string", | ||
label: "Labels", | ||
description: "This is a nested resource. Specify what labels to include in the response. One of: `all` or `none`", | ||
optional: true, | ||
options: [ | ||
"all", | ||
"none", | ||
], | ||
}, | ||
lists: { | ||
type: "string", | ||
label: "Lists", | ||
description: "This is a nested resource. Specify what lists to include in the response.", | ||
optional: true, | ||
options: [ | ||
"all", | ||
"closed", | ||
"none", | ||
"open", | ||
], | ||
}, | ||
members: { | ||
type: "string", | ||
label: "Members", | ||
description: "This is a nested resource. Specify what members to include in the response.", | ||
optional: true, | ||
options: [ | ||
"none", | ||
"normal", | ||
"admins", | ||
"owners", | ||
"all", | ||
], | ||
}, | ||
pluginData: { | ||
type: "boolean", | ||
label: "Plugin Data", | ||
description: "Determines whether the pluginData for this board should be returned.", | ||
optional: true, | ||
}, | ||
organization: { | ||
type: "boolean", | ||
label: "Organization", | ||
description: "This is a nested resource. Include organization information in the response.", | ||
optional: true, | ||
}, | ||
organizationPluginData: { | ||
type: "boolean", | ||
label: "Organization Plugin Data", | ||
description: "Use with the organization param to include organization pluginData with the response", | ||
optional: true, | ||
}, | ||
myPrefs: { | ||
type: "boolean", | ||
label: "My Preferences", | ||
description: "Include the user's preferences for this board in the response.", | ||
optional: true, | ||
}, | ||
tags: { | ||
type: "boolean", | ||
label: "Tags", | ||
description: "Also known as collections, tags, refer to the collection(s) that a Board belongs to.", | ||
optional: true, | ||
}, | ||
}, | ||
methods: { | ||
getCommaSeparatedString(array) { | ||
return Array.isArray(array) | ||
? array.join(",") | ||
: array; | ||
}, | ||
}, | ||
async run({ $ }) { | ||
const { | ||
app, | ||
getCommaSeparatedString, | ||
boardId, | ||
actions, | ||
boardStars, | ||
cardPluginData, | ||
customFields, | ||
fields, | ||
labels, | ||
lists, | ||
members, | ||
pluginData, | ||
organization, | ||
organizationPluginData, | ||
myPrefs, | ||
tags, | ||
} = this; | ||
|
||
const response = await app.getBoard({ | ||
$, | ||
boardId, | ||
params: { | ||
actions: getCommaSeparatedString(actions), | ||
boardStars, | ||
card_pluginData: cardPluginData, | ||
customFields, | ||
fields: getCommaSeparatedString(fields), | ||
labels: getCommaSeparatedString(labels), | ||
lists, | ||
members, | ||
pluginData, | ||
organization, | ||
organizationPluginData, | ||
myPrefs, | ||
tags, | ||
}, | ||
}); | ||
|
||
$.export("$summary", `Successfully retrieved board with ID \`${response.id}\``); | ||
return response; | ||
}, | ||
}; |
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.