Create a Tugboat Webhook

Arguments

  • repo - Required
    The Tugboat Repository ID for which the webhook should be created.

Example

socket.emit('tugboat', 'webhooks', 'create', args, callback);

Output

A successful creation will return an object representing the created webhook. It will contain among other data the url and ID of the webhook as returned by the git provider.

{
    "repoIds": ["5adf69fc0d85dd0001eb05e5"],
    "active": false,
    "configured": false,
    "token": "tbpbh2jhucug28nognnqtzq9rgstice5",
    "_id": "5ae1dec437c59c000153e3c1",
    "repoName": "TugboatQA/tugboat-test",
    "provider": "github",
    "createdAt": "2018-04-26T14:14:28.773Z",
    "updatedAt": "2018-04-26T14:17:34.918Z",
    "providerId": "27489295",
    "url": "https://webhooks.tugboat.qa/github/tbpbh2jhucug28nognnqtzq9rgstice5",
    "id": "5ae1dec437c59c000153e3c1"
}

Errors

  • 1000: Permission denied
    Returned if the requestor does not have permission to delete webhooks for the supplied repository.

  • 1005: No Repos Found
    Returned if the requested repository do not exist.

  • 1006: No Repo ID Provided
    The required repo argument was not included in the request.

results matching ""

    No results matching ""