Project

Project

Project encapsulates the functionality to create, query, and modify cards and columns.

Constructor

new Project(id, authopt, apiBaseopt)

Create a Project.

Parameters:
Name Type Attributes Default Description
id string

the id of the project

auth Requestable.auth <optional>

information required to authenticate to Github

apiBase string <optional>
https://api.github.com

the base Github API URL

Source:

Methods

createProjectCard(colId, options, cb) → {Promise}

Create a new card

Parameters:
Name Type Description
colId string

the column id

options Object

the description of the card

cb Requestable.callback

will receive the newly created card

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

createProjectColumn(options, cb) → {Promise}

Create a new column

Parameters:
Name Type Description
options Object

the description of the column

cb Requestable.callback

will receive the newly created column

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

deleteProject(cb) → {Promise}

Delete a project

Parameters:
Name Type Description
cb Requestable.callback

will receive true if the operation is successful

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

deleteProjectCard(cardId, cb) → {Promise}

Delete a card

Parameters:
Name Type Description
cardId string

the card to be deleted

cb Requestable.callback

will receive true if the operation is successful

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

deleteProjectColumn(colId, cb) → {Promise}

Delete a column

Parameters:
Name Type Description
colId string

the column to be deleted

cb Requestable.callback

will receive true if the operation is successful

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

getProject(cb) → {Promise}

Get information about a project

Parameters:
Name Type Description
cb Requestable.callback

will receive the project information

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

getProjectCard(cardId, cb) → {Promise}

Get information about a card

Parameters:
Name Type Description
cardId string

the id of the card

cb Requestable.callback

will receive the card information

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

getProjectColumn(colId, cb) → {Promise}

Get information about a column

Parameters:
Name Type Description
colId string

the id of the column

cb Requestable.callback

will receive the column information

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

listColumnCards(colId, cbopt) → {Promise}

Get information about all cards of a column

Parameters:
Name Type Attributes Description
colId string

the id of the column

cb Requestable.callback <optional>

will receive the list of cards

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

listProjectCards(cbopt) → {Promise}

Get information about all cards of a project

Parameters:
Name Type Attributes Description
cb Requestable.callback <optional>

will receive the list of cards

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

listProjectColumns(cbopt) → {Promise}

Get information about all columns of a project

Parameters:
Name Type Attributes Description
cb Requestable.callback <optional>

will receive the list of columns

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

moveProjectCard(cardId, position, colId, cb) → {Promise}

Move a card

Parameters:
Name Type Description
cardId string

the card to be moved

position string

can be one of top, bottom, or after:, where is the id value of a card in the same project.

colId string

the id value of a column in the same project.

cb Requestable.callback

will receive true if the operation is successful

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

moveProjectColumn(colId, position, cb) → {Promise}

Move a column

Parameters:
Name Type Description
colId string

the column to be moved

position string

can be one of first, last, or after:, where is the id value of a column in the same project.

cb Requestable.callback

will receive true if the operation is successful

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

updateProject(options, cb) → {Promise}

Edit a project

Parameters:
Name Type Description
options Object

the description of the project

cb Requestable.callback

will receive the modified project

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

updateProjectCard(cardId, options, cb) → {Promise}

Edit a card

Parameters:
Name Type Description
cardId string

the card id

options Object

the description of the card

cb Requestable.callback

will receive the modified card

Source:
See:
Returns:
  • the promise for the http request
Type
Promise

updateProjectColumn(colId, options, cb) → {Promise}

Edit a column

Parameters:
Name Type Description
colId string

the column id

options Object

the description of the column

cb Requestable.callback

will receive the modified column

Source:
See:
Returns:
  • the promise for the http request
Type
Promise